class PlaceOS::Driver::Proxy::Driver

Defined in:

placeos-driver/proxy/driver.cr

Constructors

Macro Summary

Instance Method Summary

Constructor Detail

def self.new(reply_id : String, module_name : String, index : Int32, module_id : String, system : PlaceOS::Driver::Proxy::System, metadata : PlaceOS::Driver::DriverModel::Metadata) #

[View source]

Macro Detail

macro method_missing(call) #

Don't raise errors directly. Ensure they are logged and raise if the response is requested


[View source]

Instance Method Detail

def [](status) #

[View source]
def []=(status, value) #

This deliberately prevents compilation if called from driver code


[View source]
def []?(status) #

[View source]

[View source]
def __send__(function_name : String | Symbol, arguments : Array | Tuple = Tuple.new, named_args : NamedTuple | Hash = NamedTuple.new) #

provide a programatic way of calling a remote function similar to Ruby array and hash types required for dynamic invocation across drivers


[View source]
def __status__ #

[View source]
def __status_keys__ #

[View source]
def implements?(interface) : Bool #

[View source]
def index : Int32 #

[View source]
def module_id : String #

[View source]
def module_name : String #

[View source]
def status(klass, key) #

[View source]
def status?(klass, key) #

[View source]
def subscribe(status, &callback : PlaceOS::Driver::Subscriptions::IndirectSubscription, String -> Nil) : PlaceOS::Driver::Subscriptions::IndirectSubscription #

All subscriptions to external drivers should be indirect as the driver might be swapped into a completely different system - whilst we've looked up the id of this instance of a driver, it's expected that this object is short lived


[View source]