All Classes Files Functions Variables Pages
Ports.idl
Go to the documentation of this file.
1 /**
2  * @file Ports.idl
3  * @brief Ports API for HW Box
4  * @version 2
5  */
6 
7 #import <kerio/web/idl/SharedStructures.idl>
8 #import <common.idl>
9 
10 module webadmin {
11 
12 enum PortType {
13  PortEthernet,
14  PortWifi
15 };
16 
17 enum SpeedDuplexType {
18  SpeedDuplexAuto,
19  SpeedDuplexHalf10,
20  SpeedDuplexFull10,
21  SpeedDuplexHalf100,
22  SpeedDuplexFull100,
23  SpeedDuplexFull1000
24 };
25 
26 typedef sequence<SpeedDuplexType> SpeedDuplexMayNotWorkList;
27 
28 struct PortConfig {
29  kerio::web::KId id; /**< read-only */
30  PortType type; /**< read-only */
31  string name; /**< read-only */
32  PortAssignmentType assignment;
34  SpeedDuplexType speedDuplex;
35  SpeedDuplexMayNotWorkList speedDuplexMayNotWork;
36 };
37 
38 typedef sequence<PortConfig> PortConfigList;
39 
40 interface Ports {
41 
42  /**
43  * Returns list of system ports together with assignments
44  * @param list - list of ports sorted by port's order of precedence (WiFi last)
45  * @throws kerio::web::ApiException \n
46  * -32001 Session expired. - "The user is not logged in." \n
47  * 1004 Access denied. - "Insufficient rights to perform the requested operation."
48  * @note: System version has to support port and switch configuration
49  */
50  void get(out PortConfigList list);
51 
52  /**
53  * Stores configuration for system ports
54  *
55  * If some of given items has id, that doesn't exist in current configuration, Error is returned \n
56  * Unknown items are not added, no item is deleted
57  * @param errors - list of errors \n
58  * 1000 Operation failed. - "Unable to modify port '%1'." \n
59  * 8000 Internal error. - "Internal error."
60  * @param ports - list of ports (order is not significant)
61  * @param revertTimeout - If client doesn't confirm config to this timeout, configuration is reverted (0 - revert disabled)
62  * @throws kerio::web::ApiException \n
63  * -32001 Session expired. - "The user is not logged in." \n
64  * 1004 Access denied. - "Insufficient rights to perform the requested operation."
65  * @note: System version has to support port and switch configuration
66  */
67  void set(out kerio::web::ErrorList errors, in PortConfigList ports, in long revertTimeout);
68 
69 };
70 
71 }; //webadmin
Definition: Ports.idl:28
Common Kerio Control structures, enums and types.
string name
Definition: Ports.idl:31
kerio::web::KId id
Definition: Ports.idl:29
PortType type
Definition: Ports.idl:30
Definition: Ports.idl:40
Definition: Accounting.idl:11
Definition: SharedStructures.idl:289