![]() |
Leosac
0.8.0
Open Source Access Control
|
Search hardware devices by name. More...
#include <HardwareSearch.hpp>
Inheritance diagram for Leosac::Module::WebSockAPI::HardwareSearch:
Collaboration diagram for Leosac::Module::WebSockAPI::HardwareSearch:Public Member Functions | |
| HardwareSearch (RequestContext ctx) | |
Public Member Functions inherited from Leosac::Module::WebSockAPI::MethodHandler | |
| MethodHandler (RequestContext ctx) | |
| virtual | ~MethodHandler ()=default |
| json | process (const ClientMessage &msg) |
The public process() method. More... | |
| UserSecurityContext & | security_context () |
| ExecutionContext | exec_context () |
| Returns a representation of the execution context of this request. More... | |
Static Public Member Functions | |
| static MethodHandlerUPtr | create (RequestContext) |
Static Public Member Functions inherited from Leosac::Module::WebSockAPI::MethodHandler | |
| static MethodHandlerUPtr | create (RequestContext) |
| An example method that should be implemented in all subclasses. More... | |
Protected Member Functions | |
| std::vector< ActionActionParam > | required_permission (const json &req) const override |
| Return a list of "Action" / "ActionParam" that must pass before the request is processed. More... | |
Private Member Functions | |
| virtual json | process_impl (const json &req) override |
| The API method implementation. More... | |
Additional Inherited Members | |
Public Types inherited from Leosac::Module::WebSockAPI::MethodHandler | |
| using | Factory = MethodHandlerUPtr(*)(RequestContext) |
Protected Attributes inherited from Leosac::Module::WebSockAPI::MethodHandler | |
| RequestContext | ctx_ |
Search hardware devices by name.
Request:
Response: A list of {id, name, device_class, type} for device that match the partial name. [ {id: $HARDWARE_DEVICE_ID, name: $HARDWARE_DEVICE_NAME, device-class: $HARDWARE_DEVICE_CLASS type: $HARDWARE_DEVICE_TYPE {...} ]
$HARDWARE_DEVICE_TYPE is the type of the model (eg pfdigital.gpio) while $HARDWARE_DEVICE_CLASS is the Leosac::Hardware::DeviceClass of a device. Definition at line 55 of file HardwareSearch.hpp.
|
explicit |
Definition at line 33 of file HardwareSearch.cpp.
|
static |
Definition at line 38 of file HardwareSearch.cpp.
The API method implementation.
content key in the JSON message sent to the client. Implements Leosac::Module::WebSockAPI::MethodHandler.
Definition at line 55 of file HardwareSearch.cpp.
|
overrideprotectedvirtual |
Return a list of "Action" / "ActionParam" that must pass before the request is processed.
Implements Leosac::Module::WebSockAPI::MethodHandler.
Definition at line 109 of file HardwareSearch.cpp.