Qore HueRestClient Module Reference 1.0
Loading...
Searching...
No Matches
HueRestClient.qm.dox.h
1// -*- mode: c++; indent-tabs-mode: nil -*-
3
4/* HueRestClient.qm Copyright (C) 2020 - 2024 Qore Technologies, s.r.o.
5
6 Permission is hereby granted, free of charge, to any person obtaining a
7 copy of this software and associated documentation files (the "Software"),
8 to deal in the Software without restriction, including without limitation
9 the rights to use, copy, modify, merge, publish, distribute, sublicense,
10 and/or sell copies of the Software, and to permit persons to whom the
11 Software is furnished to do so, subject to the following conditions:
12
13 The above copyright notice and this permission notice shall be included in
14 all copies or substantial portions of the Software.
15
16 THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17 IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18 FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19 AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20 LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
21 FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
22 DEALINGS IN THE SOFTWARE.
23*/
24
25// minimum qore version
26
27// require type definitions everywhere
28
29// enable all warnings
30
31// don't use "$" for vars, members, and methods, assume local variable scope
32
33// do not ignore argument errors
34
35
36
81namespace HueRestClient {
83
92
93public:
95 const DefaultUrl = "rests://api.meethue.com/route/api";
96
98 const DefaultAuthUrl = "https://api.meethue.com/v2/oauth2/authorize";
99
101 const DefaultGrantType = "authorization_code";
102
104 const DefaultTokenUrl = "https://api.meethue.com/v2/oauth2/token";
105
107 const DefaultOptions = ...;
108
109
111 const DefaultHuePingMethod= "GET";
112
114 const DefaultHuePingHeaders = ...;
115
116
118
131 constructor(hash<auto> opts, *softbool do_not_connect) ;
132
133
135 static hash<auto> getOptions(hash<auto> opts);
136};
137
139
149
150public:
152 const ConnectionScheme = ...;
153
154
156
166 constructor(string name, string description, string url = HueRestClient::DefaultUrl, hash<auto> attributes = {}, hash<auto> options = {})
167 ;
168
169
171
188 constructor(hash<auto> config, *hash<auto> attr) ;
189
190
192 string getType();
193
194
196
201
202
204
208 DataProvider::AbstractDataProvider getDataProvider(*hash<auto> constructor_options);
209
210
212protected:
214public:
215
216
218
223protected:
224 HueRestClient getImpl(bool connect = True, *hash<auto> rtopts);
225public:
226
227
229protected:
230 hash<ConnectionSchemeInfo> getConnectionSchemeInfoImpl();
231public:
232
233};
234};
const DefaultUrl
Default Hue REST API URL.
Definition HueRestClient.qm.dox.h:95
static hash< auto > getOptions(hash< auto > opts)
returns options for HueRestClient::HueRestClient::constructor()
constructor(hash< auto > opts, *softbool do_not_connect)
creates the object with the given options
Class for Hue REST connections; returns HueRestClient objects.
Definition HueRestClient.qm.dox.h:148
constructor(hash< auto > config, *hash< auto > attr)
creates the HueRestConnection object
DataProvider::AbstractDataProvider getDataProvider(*hash< auto > constructor_options)
returns a data provider object for this connection
string getType()
returns "hue"
bool hasDataProvider()
returns True as this connection returns a data provider with the getDataProvider() method
setChildCapabilities()
Sets child data provider capabilities.
hash< ConnectionSchemeInfo > getConnectionSchemeInfoImpl()
Returns the ConnectionSchemeInfo hash for this object.
constructor(string name, string description, string url=HueRestClient::DefaultUrl, hash< auto > attributes={}, hash< auto > options={})
creates the HueRestConnection object
const ConnectionScheme
Connection entry info.
Definition HueRestClient.qm.dox.h:152
HueRestClient getImpl(bool connect=True, *hash< auto > rtopts)
returns a HueRestClient object
the HueRestClient namespace contains all the objects in the HueRestClient module
Definition HueRestClient.qm.dox.h:81