Legrand / Raritan / Server Technology Xerus™ JSON-RPC API

Loading...
Searching...
No Matches
Keypad.idl
1/* SPDX-License-Identifier: BSD-3-Clause */
2/*
3 * Copyright 2020 Raritan Inc. All rights reserved.
4 */
5
6#ifndef __SMARTLOCK_KEYPAD_IDL__
7#define __SMARTLOCK_KEYPAD_IDL__
8
9#include <Event.idl>
10
11/** Keypad */
12module smartlock {
13
14 /** Keypad Interface */
15 interface Keypad {
16
17 /** Error codes */
18 constant int NO_ERROR = 0; ///< operation successful, no error
19 constant int ERR_SLOT_EMPTY = 1; ///< no PIN present in keypad
20
21 /**
22 * Keypad Metadata
23 */
24 structure MetaData {
25 string id; ///< Keypad ID used in events and traps
26 string manufacturer; ///< manufacturer
27 string product; ///< product
28 string serialNumber; ///< serial number (S/N)
29 int channel; ///< one device (S/N) can provide multiple keypads
30 string position; ///< Position of the keypad.
31 ///< A string, representing the position in the 1-wire topology
32 ///< and the channel of the keypad (e.g. D1:H1:C1-1)
33 };
34
35 /**
36 * PIN entered event
37 *
38 * A PIN was entered on this Keypad, retrieve it by using getPIN().
39 */
40 valueobject PINEnteredEvent extends idl.Event {
41 MetaData metaData; ///< MetaData of this keypad
42 };
43
44 /**
45 * Retrieve keypad metadata.
46 *
47 * @return metadata
48 */
49 MetaData getMetaData();
50
51 /**
52 * Retrieve last entered PIN from keypad. PINs are cleared after 10
53 * seconds or subsituted whenever a new PIN was entered.
54 *
55 * @param pin PIN
56 *
57 * @return NO_ERROR if OK
58 * @return ERR_SLOT_EMPTY if keypad sees no PIN
59 */
60 int getPIN(out string pin);
61
62 };
63
64}
65
66#endif /* __SMARTLOCK_KEYPAD_IDL__ */
smartlock::Keypad
Keypad Interface.
Definition Keypad.idl:15
smartlock::Keypad::getPIN
int getPIN(out string pin)
Retrieve last entered PIN from keypad.
smartlock::Keypad::NO_ERROR
constant int NO_ERROR
Error codes.
Definition Keypad.idl:18
smartlock::Keypad::getMetaData
MetaData getMetaData()
Retrieve keypad metadata.
smartlock::Keypad::ERR_SLOT_EMPTY
constant int ERR_SLOT_EMPTY
no PIN present in keypad
Definition Keypad.idl:19
idl
Basic IDL definitions.
Definition Event.idl:10
smartlock
Keypad.
Definition DoorAccessControl.idl:13
idl::Event
Common base for all events.
Definition Event.idl:13
smartlock::Keypad::MetaData
Keypad Metadata.
Definition Keypad.idl:24
smartlock::Keypad::MetaData::manufacturer
string manufacturer
manufacturer
Definition Keypad.idl:26
smartlock::Keypad::MetaData::position
string position
Position of the keypad.
Definition Keypad.idl:30
smartlock::Keypad::MetaData::id
string id
Keypad ID used in events and traps.
Definition Keypad.idl:25
smartlock::Keypad::MetaData::channel
int channel
one device (S/N) can provide multiple keypads
Definition Keypad.idl:29
smartlock::Keypad::MetaData::serialNumber
string serialNumber
serial number (S/N)
Definition Keypad.idl:28
smartlock::Keypad::MetaData::product
string product
product
Definition Keypad.idl:27
smartlock::Keypad::PINEnteredEvent
PIN entered event.
Definition Keypad.idl:40
smartlock::Keypad::PINEnteredEvent::metaData
MetaData metaData
MetaData of this keypad.
Definition Keypad.idl:41