def __init__(self,
              rpc_address: str = '',
              restful_address: str = '',
              ws_address: str = '',
              sig_svr_address='',
              default_signature_scheme: SignatureScheme = SignatureScheme.
              SHA256withECDSA):
     if not isinstance(default_signature_scheme, SignatureScheme):
         raise SDKException(
             ErrorCode.param_err('SignatureScheme object is required.'))
     self.__rpc = RpcClient(rpc_address)
     self.__restful = RestfulClient(restful_address)
     self.__websocket = WebsocketClient(ws_address)
     self.__native_vm = NativeVm(self)
     self.__neo_vm = NeoVm(self)
     self.__service = Service(self)
     self.__wallet_manager = WalletManager()
     self.__default_signature_scheme = default_signature_scheme
Beispiel #2
0
 def neo_vm(self):
     if self.__neo_vm is None:
         self.__neo_vm = NeoVm(OntologySdk._instance)
     return self.__neo_vm