NeedsExamples
Table of Contents | ||||||||
---|---|---|---|---|---|---|---|---|
|
gadgets.rpc
Provides operations for making remote procedure calls for gadget-to-container, container-to-gadget, and gadget-to-gadget communication.
Methods
gadgets.rpc.call
;<static> gadgets.rpc.call(targetId, serviceName, callback, var_args)
Parameters
NameTypeDescription |
Panel | |||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
Description
Calls an RPC service.
gadgets.rpc.register
;<static> gadgets.rpc.register(serviceName, handler)
Parameters
NameTypeDescription |
Panel | ||||||
---|---|---|---|---|---|---|
|
Description
Registers an RPC service.
gadgets.rpc.registerDefault
;<static> gadgets.rpc.registerDefault(handler)
Parameters
NameTypeDescription |
Panel | |||
---|---|---|---|
|
Description
Registers a default service handler to process all unknown remote procedure calls, which fail silently by default.
gadgets.rpc.unregister
;<static> gadgets.rpc.unregister(serviceName)
Parameters
NameTypeDescription |
Panel | |||
---|---|---|---|
|
Description
Unregisters an RPC service.
gadgets.rpc.unregisterDefault
;<static> gadgets.rpc.unregisterDefault()
Description
Unregisters the default service handler. Future unknown remote procedure calls will fail silently.
{{ JsApiAlphaList_(v0.9) }}