示例#1
0
        def __init__(self, oldDevice, newDevice, source):
            super(raritan.rpc.portsmodel.Port.DeviceChangedEvent, self).__init__(source)
            typecheck.is_remote_obj(oldDevice, AssertionError)
            typecheck.is_remote_obj(newDevice, AssertionError)

            self.oldDevice = oldDevice
            self.newDevice = newDevice
示例#2
0
 def getModem(self):
     agent = self.agent
     args = {}
     rsp = agent.json_rpc(self.target, "getModem", args)
     _ret_ = Interface.decode(rsp["_ret_"], agent)
     typecheck.is_remote_obj(_ret_, DecodeException)
     return _ret_
 def getDevice(self):
     agent = self.agent
     args = {}
     rsp = agent.json_rpc(self.target, 'getDevice', args)
     _ret_ = Interface.decode(rsp['_ret_'], agent)
     typecheck.is_remote_obj(_ret_, DecodeException)
     return _ret_
示例#4
0
 def getDevice(self):
     agent = self.agent
     args = {}
     rsp = agent.json_rpc(self.target, 'getDevice', args)
     _ret_ = Interface.decode(rsp['_ret_'], agent)
     typecheck.is_remote_obj(_ret_, DecodeException)
     return _ret_
示例#5
0
        def __init__(self, oldDevice, newDevice, source):
            super(raritan.rpc.portsmodel.Port.DeviceChangedEvent,
                  self).__init__(source)
            typecheck.is_remote_obj(oldDevice, AssertionError)
            typecheck.is_remote_obj(newDevice, AssertionError)

            self.oldDevice = oldDevice
            self.newDevice = newDevice
示例#6
0
 def cancelEvent(self, type, src):
     agent = self.agent
     typecheck.is_typeinfo(type, AssertionError)
     typecheck.is_remote_obj(src, AssertionError)
     args = {}
     args['type'] = raritan.rpc.TypeInfo.encode(type)
     args['src'] = Interface.encode(src)
     rsp = agent.json_rpc(self.target, 'cancelEvent', args)
示例#7
0
 def demandEvent(self, type, src):
     agent = self.agent
     typecheck.is_typeinfo(type, AssertionError)
     typecheck.is_remote_obj(src, AssertionError)
     args = {}
     args["type"] = raritan.rpc.TypeInfo.encode(type)
     args["src"] = Interface.encode(src)
     rsp = agent.json_rpc(self.target, "demandEvent", args)
示例#8
0
 def getDeviceConfig(self, deviceType):
     agent = self.agent
     typecheck.is_string(deviceType, AssertionError)
     args = {}
     args['deviceType'] = deviceType
     rsp = agent.json_rpc(self.target, 'getDeviceConfig', args)
     _ret_ = Interface.decode(rsp['_ret_'], agent)
     typecheck.is_remote_obj(_ret_, DecodeException)
     return _ret_
 def lookup(self, name):
     agent = self.agent
     typecheck.is_string(name, AssertionError)
     args = {}
     args['name'] = name
     rsp = agent.json_rpc(self.target, 'lookup', args)
     _ret_ = Interface.decode(rsp['_ret_'], agent)
     typecheck.is_remote_obj(_ret_, DecodeException)
     return _ret_
 def lookup(self, name):
     agent = self.agent
     typecheck.is_string(name, AssertionError)
     args = {}
     args['name'] = name
     rsp = agent.json_rpc(self.target, 'lookup', args)
     _ret_ = Interface.decode(rsp['_ret_'], agent)
     typecheck.is_remote_obj(_ret_, DecodeException)
     return _ret_
示例#11
0
 def getDeviceConfig(self, deviceType):
     agent = self.agent
     typecheck.is_string(deviceType, AssertionError)
     args = {}
     args['deviceType'] = deviceType
     rsp = agent.json_rpc(self.target, 'getDeviceConfig', args)
     _ret_ = Interface.decode(rsp['_ret_'], agent)
     typecheck.is_remote_obj(_ret_, DecodeException)
     return _ret_
示例#12
0
 def decode(rsp, agent):
     _ret_ = Interface.decode(rsp['_ret_'], agent)
     typecheck.is_remote_obj(_ret_, DecodeException)
     return _ret_
示例#13
0
    def __init__(self, source):
        typecheck.is_remote_obj(source, AssertionError)

        self.source = source
示例#14
0
        def __init__(self, modem, source):
            super(raritan.rpc.serial.SerialPort.ModemEvent,
                  self).__init__(source)
            typecheck.is_remote_obj(modem, AssertionError)

            self.modem = modem
示例#15
0
    def __init__(self, source):
        typecheck.is_remote_obj(source, AssertionError)

        self.source = source
示例#16
0
 def decode(rsp, agent):
     _ret_ = Interface.decode(rsp['_ret_'], agent)
     typecheck.is_remote_obj(_ret_, DecodeException)
     return _ret_
示例#17
0
        def __init__(self, type, src):
            typecheck.is_typeinfo(type, AssertionError)
            typecheck.is_remote_obj(src, AssertionError)

            self.type = type
            self.src = src
示例#18
0
        def __init__(self, modem, source):
            super(raritan.rpc.serial.SerialPort.ModemEvent, self).__init__(source)
            typecheck.is_remote_obj(modem, AssertionError)

            self.modem = modem