@blues-inc/notehub-js 1.0.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +297 -0
- package/dist/ApiClient.js +699 -0
- package/dist/api/AuthorizationApi.js +74 -0
- package/dist/api/BillingAccountApi.js +68 -0
- package/dist/api/DeviceApi.js +784 -0
- package/dist/api/DevicesApi.js +293 -0
- package/dist/api/EnvironmentVariablesApi.js +567 -0
- package/dist/api/EventApi.js +284 -0
- package/dist/api/FilesApi.js +193 -0
- package/dist/api/FleetApi.js +715 -0
- package/dist/api/NotesApi.js +435 -0
- package/dist/api/ProductApi.js +163 -0
- package/dist/api/ProjectApi.js +716 -0
- package/dist/api/RouteApi.js +266 -0
- package/dist/index.js +566 -0
- package/dist/model/Aws.js +233 -0
- package/dist/model/Azure.js +166 -0
- package/dist/model/BillingAccount.js +130 -0
- package/dist/model/BillingAccountRole.js +42 -0
- package/dist/model/Body.js +78 -0
- package/dist/model/Contact.js +118 -0
- package/dist/model/CreateFleetRequest.js +83 -0
- package/dist/model/CreateProductRequest.js +142 -0
- package/dist/model/CreateProjectRequest.js +119 -0
- package/dist/model/DFUEnv.js +97 -0
- package/dist/model/DFUState.js +276 -0
- package/dist/model/DeleteDeviceFleetsRequest.js +106 -0
- package/dist/model/Device.js +267 -0
- package/dist/model/DeviceSession.js +537 -0
- package/dist/model/DeviceTowerInfo.js +102 -0
- package/dist/model/DeviceUsage.js +150 -0
- package/dist/model/EnvironmentVariables.js +103 -0
- package/dist/model/Error.js +164 -0
- package/dist/model/Event.js +676 -0
- package/dist/model/Fleet.js +129 -0
- package/dist/model/GetBillingAccounts200Response.js +103 -0
- package/dist/model/GetDeviceEnvironmentVariables200Response.js +117 -0
- package/dist/model/GetDeviceHealthLog200Response.js +123 -0
- package/dist/model/GetDeviceHealthLog200ResponseHealthLogInner.js +125 -0
- package/dist/model/GetDeviceLatest200Response.js +104 -0
- package/dist/model/GetDevicePublicKey200Response.js +119 -0
- package/dist/model/GetDeviceSessions200Response.js +133 -0
- package/dist/model/GetProjectDevicePublicKeys200Response.js +133 -0
- package/dist/model/GetProjectDevicePublicKeys200ResponseDevicePublicKeysInner.js +94 -0
- package/dist/model/GetProjectDevices200Response.js +133 -0
- package/dist/model/GetProjectEvents200Response.js +149 -0
- package/dist/model/GetProjectEventsByCursor200Response.js +149 -0
- package/dist/model/GetProjectFleets200Response.js +123 -0
- package/dist/model/GetProjectMembers200Response.js +123 -0
- package/dist/model/GetProjectProducts200Response.js +103 -0
- package/dist/model/GetProjects200Response.js +103 -0
- package/dist/model/Google.js +142 -0
- package/dist/model/HandleNoteChanges200Response.js +97 -0
- package/dist/model/HandleNoteGet200Response.js +101 -0
- package/dist/model/HandleNoteSignal200Response.js +79 -0
- package/dist/model/HandleNotefileChanges200Response.js +97 -0
- package/dist/model/HandleNotefileChangesPending200Response.js +106 -0
- package/dist/model/HandleNotefileDeleteRequest.js +83 -0
- package/dist/model/Http.js +163 -0
- package/dist/model/HttpFilter.js +128 -0
- package/dist/model/HttpTransform.js +139 -0
- package/dist/model/Location.js +167 -0
- package/dist/model/Login200Response.js +82 -0
- package/dist/model/LoginRequest.js +94 -0
- package/dist/model/Mqtt.js +240 -0
- package/dist/model/Note.js +90 -0
- package/dist/model/Product.js +141 -0
- package/dist/model/Project.js +165 -0
- package/dist/model/ProjectMember.js +131 -0
- package/dist/model/Proxy.js +128 -0
- package/dist/model/PutDeviceFleetsRequest.js +106 -0
- package/dist/model/Radresponder.js +130 -0
- package/dist/model/Role.js +43 -0
- package/dist/model/Route.js +245 -0
- package/dist/model/RouteSchema.js +427 -0
- package/dist/model/Snowflake.js +185 -0
- package/dist/model/SnowflakeTransform.js +97 -0
- package/dist/model/Thingworx.js +154 -0
- package/dist/model/TowerLocation.js +204 -0
- package/dist/model/Twilio.js +181 -0
- package/dist/model/UpdateFleetRequest.js +109 -0
- package/dist/model/UserDbRoute.js +131 -0
- package/package.json +49 -0
|
@@ -0,0 +1,537 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports["default"] = void 0;
|
|
7
|
+
var _ApiClient = _interopRequireDefault(require("../ApiClient"));
|
|
8
|
+
var _DeviceUsage = _interopRequireDefault(require("./DeviceUsage"));
|
|
9
|
+
var _TowerLocation = _interopRequireDefault(require("./TowerLocation"));
|
|
10
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
11
|
+
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
12
|
+
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
13
|
+
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor); } }
|
|
14
|
+
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
15
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
16
|
+
function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
17
|
+
/**
|
|
18
|
+
* The DeviceSession model module.
|
|
19
|
+
* @module model/DeviceSession
|
|
20
|
+
* @version 1.0.4
|
|
21
|
+
*/
|
|
22
|
+
var DeviceSession = /*#__PURE__*/function () {
|
|
23
|
+
/**
|
|
24
|
+
* Constructs a new <code>DeviceSession</code>.
|
|
25
|
+
* @alias module:model/DeviceSession
|
|
26
|
+
*/
|
|
27
|
+
function DeviceSession() {
|
|
28
|
+
_classCallCheck(this, DeviceSession);
|
|
29
|
+
DeviceSession.initialize(this);
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
/**
|
|
33
|
+
* Initializes the fields of this object.
|
|
34
|
+
* This method is used by the constructors of any subclasses, in order to implement multiple inheritance (mix-ins).
|
|
35
|
+
* Only for internal use.
|
|
36
|
+
*/
|
|
37
|
+
_createClass(DeviceSession, null, [{
|
|
38
|
+
key: "initialize",
|
|
39
|
+
value: function initialize(obj) {}
|
|
40
|
+
|
|
41
|
+
/**
|
|
42
|
+
* Constructs a <code>DeviceSession</code> from a plain JavaScript object, optionally creating a new instance.
|
|
43
|
+
* Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
|
|
44
|
+
* @param {Object} data The plain JavaScript object bearing properties of interest.
|
|
45
|
+
* @param {module:model/DeviceSession} obj Optional instance to populate.
|
|
46
|
+
* @return {module:model/DeviceSession} The populated <code>DeviceSession</code> instance.
|
|
47
|
+
*/
|
|
48
|
+
}, {
|
|
49
|
+
key: "constructFromObject",
|
|
50
|
+
value: function constructFromObject(data, obj) {
|
|
51
|
+
if (data) {
|
|
52
|
+
obj = obj || new DeviceSession();
|
|
53
|
+
if (data.hasOwnProperty('session')) {
|
|
54
|
+
obj['session'] = _ApiClient["default"].convertToType(data['session'], 'String');
|
|
55
|
+
}
|
|
56
|
+
if (data.hasOwnProperty('device')) {
|
|
57
|
+
obj['device'] = _ApiClient["default"].convertToType(data['device'], 'String');
|
|
58
|
+
}
|
|
59
|
+
if (data.hasOwnProperty('sn')) {
|
|
60
|
+
obj['sn'] = _ApiClient["default"].convertToType(data['sn'], 'String');
|
|
61
|
+
}
|
|
62
|
+
if (data.hasOwnProperty('product')) {
|
|
63
|
+
obj['product'] = _ApiClient["default"].convertToType(data['product'], 'String');
|
|
64
|
+
}
|
|
65
|
+
if (data.hasOwnProperty('fleets')) {
|
|
66
|
+
obj['fleets'] = _ApiClient["default"].convertToType(data['fleets'], ['String']);
|
|
67
|
+
}
|
|
68
|
+
if (data.hasOwnProperty('cell')) {
|
|
69
|
+
obj['cell'] = _ApiClient["default"].convertToType(data['cell'], 'String');
|
|
70
|
+
}
|
|
71
|
+
if (data.hasOwnProperty('scan')) {
|
|
72
|
+
obj['scan'] = _ApiClient["default"].convertToType(data['scan'], 'Blob');
|
|
73
|
+
}
|
|
74
|
+
if (data.hasOwnProperty('triangulate')) {
|
|
75
|
+
obj['triangulate'] = _ApiClient["default"].convertToType(data['triangulate'], Object);
|
|
76
|
+
}
|
|
77
|
+
if (data.hasOwnProperty('rssi')) {
|
|
78
|
+
obj['rssi'] = _ApiClient["default"].convertToType(data['rssi'], 'Number');
|
|
79
|
+
}
|
|
80
|
+
if (data.hasOwnProperty('sinr')) {
|
|
81
|
+
obj['sinr'] = _ApiClient["default"].convertToType(data['sinr'], 'Number');
|
|
82
|
+
}
|
|
83
|
+
if (data.hasOwnProperty('rsrp')) {
|
|
84
|
+
obj['rsrp'] = _ApiClient["default"].convertToType(data['rsrp'], 'Number');
|
|
85
|
+
}
|
|
86
|
+
if (data.hasOwnProperty('rsrq')) {
|
|
87
|
+
obj['rsrq'] = _ApiClient["default"].convertToType(data['rsrq'], 'Number');
|
|
88
|
+
}
|
|
89
|
+
if (data.hasOwnProperty('bars')) {
|
|
90
|
+
obj['bars'] = _ApiClient["default"].convertToType(data['bars'], 'Number');
|
|
91
|
+
}
|
|
92
|
+
if (data.hasOwnProperty('rat')) {
|
|
93
|
+
obj['rat'] = _ApiClient["default"].convertToType(data['rat'], 'String');
|
|
94
|
+
}
|
|
95
|
+
if (data.hasOwnProperty('bearer')) {
|
|
96
|
+
obj['bearer'] = _ApiClient["default"].convertToType(data['bearer'], 'String');
|
|
97
|
+
}
|
|
98
|
+
if (data.hasOwnProperty('ip')) {
|
|
99
|
+
obj['ip'] = _ApiClient["default"].convertToType(data['ip'], 'String');
|
|
100
|
+
}
|
|
101
|
+
if (data.hasOwnProperty('bssid')) {
|
|
102
|
+
obj['bssid'] = _ApiClient["default"].convertToType(data['bssid'], 'String');
|
|
103
|
+
}
|
|
104
|
+
if (data.hasOwnProperty('ssid')) {
|
|
105
|
+
obj['ssid'] = _ApiClient["default"].convertToType(data['ssid'], 'String');
|
|
106
|
+
}
|
|
107
|
+
if (data.hasOwnProperty('iccid')) {
|
|
108
|
+
obj['iccid'] = _ApiClient["default"].convertToType(data['iccid'], 'String');
|
|
109
|
+
}
|
|
110
|
+
if (data.hasOwnProperty('apn')) {
|
|
111
|
+
obj['apn'] = _ApiClient["default"].convertToType(data['apn'], 'String');
|
|
112
|
+
}
|
|
113
|
+
if (data.hasOwnProperty('tower')) {
|
|
114
|
+
obj['tower'] = _TowerLocation["default"].constructFromObject(data['tower']);
|
|
115
|
+
}
|
|
116
|
+
if (data.hasOwnProperty('tri')) {
|
|
117
|
+
obj['tri'] = _TowerLocation["default"].constructFromObject(data['tri']);
|
|
118
|
+
}
|
|
119
|
+
if (data.hasOwnProperty('when')) {
|
|
120
|
+
obj['when'] = _ApiClient["default"].convertToType(data['when'], 'Number');
|
|
121
|
+
}
|
|
122
|
+
if (data.hasOwnProperty('where_when')) {
|
|
123
|
+
obj['where_when'] = _ApiClient["default"].convertToType(data['where_when'], 'Number');
|
|
124
|
+
}
|
|
125
|
+
if (data.hasOwnProperty('where')) {
|
|
126
|
+
obj['where'] = _ApiClient["default"].convertToType(data['where'], 'String');
|
|
127
|
+
}
|
|
128
|
+
if (data.hasOwnProperty('where_lat')) {
|
|
129
|
+
obj['where_lat'] = _ApiClient["default"].convertToType(data['where_lat'], 'Number');
|
|
130
|
+
}
|
|
131
|
+
if (data.hasOwnProperty('where_lon')) {
|
|
132
|
+
obj['where_lon'] = _ApiClient["default"].convertToType(data['where_lon'], 'Number');
|
|
133
|
+
}
|
|
134
|
+
if (data.hasOwnProperty('where_location')) {
|
|
135
|
+
obj['where_location'] = _ApiClient["default"].convertToType(data['where_location'], 'String');
|
|
136
|
+
}
|
|
137
|
+
if (data.hasOwnProperty('where_country')) {
|
|
138
|
+
obj['where_country'] = _ApiClient["default"].convertToType(data['where_country'], 'String');
|
|
139
|
+
}
|
|
140
|
+
if (data.hasOwnProperty('where_timezone')) {
|
|
141
|
+
obj['where_timezone'] = _ApiClient["default"].convertToType(data['where_timezone'], 'String');
|
|
142
|
+
}
|
|
143
|
+
if (data.hasOwnProperty('usage_actual')) {
|
|
144
|
+
obj['usage_actual'] = _ApiClient["default"].convertToType(data['usage_actual'], 'Boolean');
|
|
145
|
+
}
|
|
146
|
+
if (data.hasOwnProperty('voltage')) {
|
|
147
|
+
obj['voltage'] = _ApiClient["default"].convertToType(data['voltage'], 'Number');
|
|
148
|
+
}
|
|
149
|
+
if (data.hasOwnProperty('temp')) {
|
|
150
|
+
obj['temp'] = _ApiClient["default"].convertToType(data['temp'], 'Number');
|
|
151
|
+
}
|
|
152
|
+
if (data.hasOwnProperty('continuous')) {
|
|
153
|
+
obj['continuous'] = _ApiClient["default"].convertToType(data['continuous'], 'Boolean');
|
|
154
|
+
}
|
|
155
|
+
if (data.hasOwnProperty('tls')) {
|
|
156
|
+
obj['tls'] = _ApiClient["default"].convertToType(data['tls'], 'Boolean');
|
|
157
|
+
}
|
|
158
|
+
if (data.hasOwnProperty('work')) {
|
|
159
|
+
obj['work'] = _ApiClient["default"].convertToType(data['work'], 'Number');
|
|
160
|
+
}
|
|
161
|
+
if (data.hasOwnProperty('events')) {
|
|
162
|
+
obj['events'] = _ApiClient["default"].convertToType(data['events'], 'Number');
|
|
163
|
+
}
|
|
164
|
+
if (data.hasOwnProperty('moved')) {
|
|
165
|
+
obj['moved'] = _ApiClient["default"].convertToType(data['moved'], 'Number');
|
|
166
|
+
}
|
|
167
|
+
if (data.hasOwnProperty('orientation')) {
|
|
168
|
+
obj['orientation'] = _ApiClient["default"].convertToType(data['orientation'], 'String');
|
|
169
|
+
}
|
|
170
|
+
if (data.hasOwnProperty('hp_secs_total')) {
|
|
171
|
+
obj['hp_secs_total'] = _ApiClient["default"].convertToType(data['hp_secs_total'], 'Number');
|
|
172
|
+
}
|
|
173
|
+
if (data.hasOwnProperty('hp_secs_data')) {
|
|
174
|
+
obj['hp_secs_data'] = _ApiClient["default"].convertToType(data['hp_secs_data'], 'Number');
|
|
175
|
+
}
|
|
176
|
+
if (data.hasOwnProperty('hp_secs_gps')) {
|
|
177
|
+
obj['hp_secs_gps'] = _ApiClient["default"].convertToType(data['hp_secs_gps'], 'Number');
|
|
178
|
+
}
|
|
179
|
+
if (data.hasOwnProperty('hp_cycles_total')) {
|
|
180
|
+
obj['hp_cycles_total'] = _ApiClient["default"].convertToType(data['hp_cycles_total'], 'Number');
|
|
181
|
+
}
|
|
182
|
+
if (data.hasOwnProperty('hp_cycles_data')) {
|
|
183
|
+
obj['hp_cycles_data'] = _ApiClient["default"].convertToType(data['hp_cycles_data'], 'Number');
|
|
184
|
+
}
|
|
185
|
+
if (data.hasOwnProperty('hp_cycles_gps')) {
|
|
186
|
+
obj['hp_cycles_gps'] = _ApiClient["default"].convertToType(data['hp_cycles_gps'], 'Number');
|
|
187
|
+
}
|
|
188
|
+
if (data.hasOwnProperty('period')) {
|
|
189
|
+
obj['period'] = _DeviceUsage["default"].constructFromObject(data['period']);
|
|
190
|
+
}
|
|
191
|
+
} else if (data === null) {
|
|
192
|
+
return null;
|
|
193
|
+
}
|
|
194
|
+
return obj;
|
|
195
|
+
}
|
|
196
|
+
|
|
197
|
+
/**
|
|
198
|
+
* Validates the JSON data with respect to <code>DeviceSession</code>.
|
|
199
|
+
* @param {Object} data The plain JavaScript object bearing properties of interest.
|
|
200
|
+
* @return {boolean} to indicate whether the JSON data is valid with respect to <code>DeviceSession</code>.
|
|
201
|
+
*/
|
|
202
|
+
}, {
|
|
203
|
+
key: "validateJSON",
|
|
204
|
+
value: function validateJSON(data) {
|
|
205
|
+
// ensure the json data is a string
|
|
206
|
+
if (data['session'] && !(typeof data['session'] === 'string' || data['session'] instanceof String)) {
|
|
207
|
+
throw new Error("Expected the field `session` to be a primitive type in the JSON string but got " + data['session']);
|
|
208
|
+
}
|
|
209
|
+
// ensure the json data is a string
|
|
210
|
+
if (data['device'] && !(typeof data['device'] === 'string' || data['device'] instanceof String)) {
|
|
211
|
+
throw new Error("Expected the field `device` to be a primitive type in the JSON string but got " + data['device']);
|
|
212
|
+
}
|
|
213
|
+
// ensure the json data is a string
|
|
214
|
+
if (data['sn'] && !(typeof data['sn'] === 'string' || data['sn'] instanceof String)) {
|
|
215
|
+
throw new Error("Expected the field `sn` to be a primitive type in the JSON string but got " + data['sn']);
|
|
216
|
+
}
|
|
217
|
+
// ensure the json data is a string
|
|
218
|
+
if (data['product'] && !(typeof data['product'] === 'string' || data['product'] instanceof String)) {
|
|
219
|
+
throw new Error("Expected the field `product` to be a primitive type in the JSON string but got " + data['product']);
|
|
220
|
+
}
|
|
221
|
+
// ensure the json data is an array
|
|
222
|
+
if (!Array.isArray(data['fleets'])) {
|
|
223
|
+
throw new Error("Expected the field `fleets` to be an array in the JSON data but got " + data['fleets']);
|
|
224
|
+
}
|
|
225
|
+
// ensure the json data is a string
|
|
226
|
+
if (data['cell'] && !(typeof data['cell'] === 'string' || data['cell'] instanceof String)) {
|
|
227
|
+
throw new Error("Expected the field `cell` to be a primitive type in the JSON string but got " + data['cell']);
|
|
228
|
+
}
|
|
229
|
+
// ensure the json data is a string
|
|
230
|
+
if (data['rat'] && !(typeof data['rat'] === 'string' || data['rat'] instanceof String)) {
|
|
231
|
+
throw new Error("Expected the field `rat` to be a primitive type in the JSON string but got " + data['rat']);
|
|
232
|
+
}
|
|
233
|
+
// ensure the json data is a string
|
|
234
|
+
if (data['bearer'] && !(typeof data['bearer'] === 'string' || data['bearer'] instanceof String)) {
|
|
235
|
+
throw new Error("Expected the field `bearer` to be a primitive type in the JSON string but got " + data['bearer']);
|
|
236
|
+
}
|
|
237
|
+
// ensure the json data is a string
|
|
238
|
+
if (data['ip'] && !(typeof data['ip'] === 'string' || data['ip'] instanceof String)) {
|
|
239
|
+
throw new Error("Expected the field `ip` to be a primitive type in the JSON string but got " + data['ip']);
|
|
240
|
+
}
|
|
241
|
+
// ensure the json data is a string
|
|
242
|
+
if (data['bssid'] && !(typeof data['bssid'] === 'string' || data['bssid'] instanceof String)) {
|
|
243
|
+
throw new Error("Expected the field `bssid` to be a primitive type in the JSON string but got " + data['bssid']);
|
|
244
|
+
}
|
|
245
|
+
// ensure the json data is a string
|
|
246
|
+
if (data['ssid'] && !(typeof data['ssid'] === 'string' || data['ssid'] instanceof String)) {
|
|
247
|
+
throw new Error("Expected the field `ssid` to be a primitive type in the JSON string but got " + data['ssid']);
|
|
248
|
+
}
|
|
249
|
+
// ensure the json data is a string
|
|
250
|
+
if (data['iccid'] && !(typeof data['iccid'] === 'string' || data['iccid'] instanceof String)) {
|
|
251
|
+
throw new Error("Expected the field `iccid` to be a primitive type in the JSON string but got " + data['iccid']);
|
|
252
|
+
}
|
|
253
|
+
// ensure the json data is a string
|
|
254
|
+
if (data['apn'] && !(typeof data['apn'] === 'string' || data['apn'] instanceof String)) {
|
|
255
|
+
throw new Error("Expected the field `apn` to be a primitive type in the JSON string but got " + data['apn']);
|
|
256
|
+
}
|
|
257
|
+
// validate the optional field `tower`
|
|
258
|
+
if (data['tower']) {
|
|
259
|
+
// data not null
|
|
260
|
+
_TowerLocation["default"].validateJSON(data['tower']);
|
|
261
|
+
}
|
|
262
|
+
// validate the optional field `tri`
|
|
263
|
+
if (data['tri']) {
|
|
264
|
+
// data not null
|
|
265
|
+
_TowerLocation["default"].validateJSON(data['tri']);
|
|
266
|
+
}
|
|
267
|
+
// ensure the json data is a string
|
|
268
|
+
if (data['where'] && !(typeof data['where'] === 'string' || data['where'] instanceof String)) {
|
|
269
|
+
throw new Error("Expected the field `where` to be a primitive type in the JSON string but got " + data['where']);
|
|
270
|
+
}
|
|
271
|
+
// ensure the json data is a string
|
|
272
|
+
if (data['where_location'] && !(typeof data['where_location'] === 'string' || data['where_location'] instanceof String)) {
|
|
273
|
+
throw new Error("Expected the field `where_location` to be a primitive type in the JSON string but got " + data['where_location']);
|
|
274
|
+
}
|
|
275
|
+
// ensure the json data is a string
|
|
276
|
+
if (data['where_country'] && !(typeof data['where_country'] === 'string' || data['where_country'] instanceof String)) {
|
|
277
|
+
throw new Error("Expected the field `where_country` to be a primitive type in the JSON string but got " + data['where_country']);
|
|
278
|
+
}
|
|
279
|
+
// ensure the json data is a string
|
|
280
|
+
if (data['where_timezone'] && !(typeof data['where_timezone'] === 'string' || data['where_timezone'] instanceof String)) {
|
|
281
|
+
throw new Error("Expected the field `where_timezone` to be a primitive type in the JSON string but got " + data['where_timezone']);
|
|
282
|
+
}
|
|
283
|
+
// ensure the json data is a string
|
|
284
|
+
if (data['orientation'] && !(typeof data['orientation'] === 'string' || data['orientation'] instanceof String)) {
|
|
285
|
+
throw new Error("Expected the field `orientation` to be a primitive type in the JSON string but got " + data['orientation']);
|
|
286
|
+
}
|
|
287
|
+
// validate the optional field `period`
|
|
288
|
+
if (data['period']) {
|
|
289
|
+
// data not null
|
|
290
|
+
_DeviceUsage["default"].validateJSON(data['period']);
|
|
291
|
+
}
|
|
292
|
+
return true;
|
|
293
|
+
}
|
|
294
|
+
}]);
|
|
295
|
+
return DeviceSession;
|
|
296
|
+
}();
|
|
297
|
+
/**
|
|
298
|
+
* Session UID
|
|
299
|
+
* @member {String} session
|
|
300
|
+
*/
|
|
301
|
+
DeviceSession.prototype['session'] = undefined;
|
|
302
|
+
|
|
303
|
+
/**
|
|
304
|
+
* Device UID
|
|
305
|
+
* @member {String} device
|
|
306
|
+
*/
|
|
307
|
+
DeviceSession.prototype['device'] = undefined;
|
|
308
|
+
|
|
309
|
+
/**
|
|
310
|
+
* Device Serial Number
|
|
311
|
+
* @member {String} sn
|
|
312
|
+
*/
|
|
313
|
+
DeviceSession.prototype['sn'] = undefined;
|
|
314
|
+
|
|
315
|
+
/**
|
|
316
|
+
* Product UID
|
|
317
|
+
* @member {String} product
|
|
318
|
+
*/
|
|
319
|
+
DeviceSession.prototype['product'] = undefined;
|
|
320
|
+
|
|
321
|
+
/**
|
|
322
|
+
* Array of Fleet UIDs
|
|
323
|
+
* @member {Array.<String>} fleets
|
|
324
|
+
*/
|
|
325
|
+
DeviceSession.prototype['fleets'] = undefined;
|
|
326
|
+
|
|
327
|
+
/**
|
|
328
|
+
* Cell ID where the session originated and quality (\"mcc,mnc,lac,cellid\")
|
|
329
|
+
* @member {String} cell
|
|
330
|
+
*/
|
|
331
|
+
DeviceSession.prototype['cell'] = undefined;
|
|
332
|
+
|
|
333
|
+
/**
|
|
334
|
+
* @member {Blob} scan
|
|
335
|
+
*/
|
|
336
|
+
DeviceSession.prototype['scan'] = undefined;
|
|
337
|
+
|
|
338
|
+
/**
|
|
339
|
+
* @member {Object} triangulate
|
|
340
|
+
*/
|
|
341
|
+
DeviceSession.prototype['triangulate'] = undefined;
|
|
342
|
+
|
|
343
|
+
/**
|
|
344
|
+
* @member {Number} rssi
|
|
345
|
+
*/
|
|
346
|
+
DeviceSession.prototype['rssi'] = undefined;
|
|
347
|
+
|
|
348
|
+
/**
|
|
349
|
+
* @member {Number} sinr
|
|
350
|
+
*/
|
|
351
|
+
DeviceSession.prototype['sinr'] = undefined;
|
|
352
|
+
|
|
353
|
+
/**
|
|
354
|
+
* @member {Number} rsrp
|
|
355
|
+
*/
|
|
356
|
+
DeviceSession.prototype['rsrp'] = undefined;
|
|
357
|
+
|
|
358
|
+
/**
|
|
359
|
+
* @member {Number} rsrq
|
|
360
|
+
*/
|
|
361
|
+
DeviceSession.prototype['rsrq'] = undefined;
|
|
362
|
+
|
|
363
|
+
/**
|
|
364
|
+
* @member {Number} bars
|
|
365
|
+
*/
|
|
366
|
+
DeviceSession.prototype['bars'] = undefined;
|
|
367
|
+
|
|
368
|
+
/**
|
|
369
|
+
* @member {String} rat
|
|
370
|
+
*/
|
|
371
|
+
DeviceSession.prototype['rat'] = undefined;
|
|
372
|
+
|
|
373
|
+
/**
|
|
374
|
+
* @member {String} bearer
|
|
375
|
+
*/
|
|
376
|
+
DeviceSession.prototype['bearer'] = undefined;
|
|
377
|
+
|
|
378
|
+
/**
|
|
379
|
+
* @member {String} ip
|
|
380
|
+
*/
|
|
381
|
+
DeviceSession.prototype['ip'] = undefined;
|
|
382
|
+
|
|
383
|
+
/**
|
|
384
|
+
* @member {String} bssid
|
|
385
|
+
*/
|
|
386
|
+
DeviceSession.prototype['bssid'] = undefined;
|
|
387
|
+
|
|
388
|
+
/**
|
|
389
|
+
* @member {String} ssid
|
|
390
|
+
*/
|
|
391
|
+
DeviceSession.prototype['ssid'] = undefined;
|
|
392
|
+
|
|
393
|
+
/**
|
|
394
|
+
* @member {String} iccid
|
|
395
|
+
*/
|
|
396
|
+
DeviceSession.prototype['iccid'] = undefined;
|
|
397
|
+
|
|
398
|
+
/**
|
|
399
|
+
* @member {String} apn
|
|
400
|
+
*/
|
|
401
|
+
DeviceSession.prototype['apn'] = undefined;
|
|
402
|
+
|
|
403
|
+
/**
|
|
404
|
+
* @member {module:model/TowerLocation} tower
|
|
405
|
+
*/
|
|
406
|
+
DeviceSession.prototype['tower'] = undefined;
|
|
407
|
+
|
|
408
|
+
/**
|
|
409
|
+
* @member {module:model/TowerLocation} tri
|
|
410
|
+
*/
|
|
411
|
+
DeviceSession.prototype['tri'] = undefined;
|
|
412
|
+
|
|
413
|
+
/**
|
|
414
|
+
* Last known capture time of a note routed through this session
|
|
415
|
+
* @member {Number} when
|
|
416
|
+
*/
|
|
417
|
+
DeviceSession.prototype['when'] = undefined;
|
|
418
|
+
|
|
419
|
+
/**
|
|
420
|
+
* @member {Number} where_when
|
|
421
|
+
*/
|
|
422
|
+
DeviceSession.prototype['where_when'] = undefined;
|
|
423
|
+
|
|
424
|
+
/**
|
|
425
|
+
* Where OLC
|
|
426
|
+
* @member {String} where
|
|
427
|
+
*/
|
|
428
|
+
DeviceSession.prototype['where'] = undefined;
|
|
429
|
+
|
|
430
|
+
/**
|
|
431
|
+
* @member {Number} where_lat
|
|
432
|
+
*/
|
|
433
|
+
DeviceSession.prototype['where_lat'] = undefined;
|
|
434
|
+
|
|
435
|
+
/**
|
|
436
|
+
* @member {Number} where_lon
|
|
437
|
+
*/
|
|
438
|
+
DeviceSession.prototype['where_lon'] = undefined;
|
|
439
|
+
|
|
440
|
+
/**
|
|
441
|
+
* @member {String} where_location
|
|
442
|
+
*/
|
|
443
|
+
DeviceSession.prototype['where_location'] = undefined;
|
|
444
|
+
|
|
445
|
+
/**
|
|
446
|
+
* @member {String} where_country
|
|
447
|
+
*/
|
|
448
|
+
DeviceSession.prototype['where_country'] = undefined;
|
|
449
|
+
|
|
450
|
+
/**
|
|
451
|
+
* @member {String} where_timezone
|
|
452
|
+
*/
|
|
453
|
+
DeviceSession.prototype['where_timezone'] = undefined;
|
|
454
|
+
|
|
455
|
+
/**
|
|
456
|
+
* @member {Boolean} usage_actual
|
|
457
|
+
*/
|
|
458
|
+
DeviceSession.prototype['usage_actual'] = undefined;
|
|
459
|
+
|
|
460
|
+
/**
|
|
461
|
+
* @member {Number} voltage
|
|
462
|
+
*/
|
|
463
|
+
DeviceSession.prototype['voltage'] = undefined;
|
|
464
|
+
|
|
465
|
+
/**
|
|
466
|
+
* @member {Number} temp
|
|
467
|
+
*/
|
|
468
|
+
DeviceSession.prototype['temp'] = undefined;
|
|
469
|
+
|
|
470
|
+
/**
|
|
471
|
+
* @member {Boolean} continuous
|
|
472
|
+
*/
|
|
473
|
+
DeviceSession.prototype['continuous'] = undefined;
|
|
474
|
+
|
|
475
|
+
/**
|
|
476
|
+
* @member {Boolean} tls
|
|
477
|
+
*/
|
|
478
|
+
DeviceSession.prototype['tls'] = undefined;
|
|
479
|
+
|
|
480
|
+
/**
|
|
481
|
+
* Last time work was done for this session
|
|
482
|
+
* @member {Number} work
|
|
483
|
+
*/
|
|
484
|
+
DeviceSession.prototype['work'] = undefined;
|
|
485
|
+
|
|
486
|
+
/**
|
|
487
|
+
* Number of events routed
|
|
488
|
+
* @member {Number} events
|
|
489
|
+
*/
|
|
490
|
+
DeviceSession.prototype['events'] = undefined;
|
|
491
|
+
|
|
492
|
+
/**
|
|
493
|
+
* @member {Number} moved
|
|
494
|
+
*/
|
|
495
|
+
DeviceSession.prototype['moved'] = undefined;
|
|
496
|
+
|
|
497
|
+
/**
|
|
498
|
+
* @member {String} orientation
|
|
499
|
+
*/
|
|
500
|
+
DeviceSession.prototype['orientation'] = undefined;
|
|
501
|
+
|
|
502
|
+
/**
|
|
503
|
+
* @member {Number} hp_secs_total
|
|
504
|
+
*/
|
|
505
|
+
DeviceSession.prototype['hp_secs_total'] = undefined;
|
|
506
|
+
|
|
507
|
+
/**
|
|
508
|
+
* @member {Number} hp_secs_data
|
|
509
|
+
*/
|
|
510
|
+
DeviceSession.prototype['hp_secs_data'] = undefined;
|
|
511
|
+
|
|
512
|
+
/**
|
|
513
|
+
* @member {Number} hp_secs_gps
|
|
514
|
+
*/
|
|
515
|
+
DeviceSession.prototype['hp_secs_gps'] = undefined;
|
|
516
|
+
|
|
517
|
+
/**
|
|
518
|
+
* @member {Number} hp_cycles_total
|
|
519
|
+
*/
|
|
520
|
+
DeviceSession.prototype['hp_cycles_total'] = undefined;
|
|
521
|
+
|
|
522
|
+
/**
|
|
523
|
+
* @member {Number} hp_cycles_data
|
|
524
|
+
*/
|
|
525
|
+
DeviceSession.prototype['hp_cycles_data'] = undefined;
|
|
526
|
+
|
|
527
|
+
/**
|
|
528
|
+
* @member {Number} hp_cycles_gps
|
|
529
|
+
*/
|
|
530
|
+
DeviceSession.prototype['hp_cycles_gps'] = undefined;
|
|
531
|
+
|
|
532
|
+
/**
|
|
533
|
+
* @member {module:model/DeviceUsage} period
|
|
534
|
+
*/
|
|
535
|
+
DeviceSession.prototype['period'] = undefined;
|
|
536
|
+
var _default = DeviceSession;
|
|
537
|
+
exports["default"] = _default;
|
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports["default"] = void 0;
|
|
7
|
+
var _ApiClient = _interopRequireDefault(require("../ApiClient"));
|
|
8
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
9
|
+
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
10
|
+
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
11
|
+
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor); } }
|
|
12
|
+
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
13
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
14
|
+
function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
15
|
+
/**
|
|
16
|
+
* The DeviceTowerInfo model module.
|
|
17
|
+
* @module model/DeviceTowerInfo
|
|
18
|
+
* @version 1.0.4
|
|
19
|
+
*/
|
|
20
|
+
var DeviceTowerInfo = /*#__PURE__*/function () {
|
|
21
|
+
/**
|
|
22
|
+
* Constructs a new <code>DeviceTowerInfo</code>.
|
|
23
|
+
* @alias module:model/DeviceTowerInfo
|
|
24
|
+
*/
|
|
25
|
+
function DeviceTowerInfo() {
|
|
26
|
+
_classCallCheck(this, DeviceTowerInfo);
|
|
27
|
+
DeviceTowerInfo.initialize(this);
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
/**
|
|
31
|
+
* Initializes the fields of this object.
|
|
32
|
+
* This method is used by the constructors of any subclasses, in order to implement multiple inheritance (mix-ins).
|
|
33
|
+
* Only for internal use.
|
|
34
|
+
*/
|
|
35
|
+
_createClass(DeviceTowerInfo, null, [{
|
|
36
|
+
key: "initialize",
|
|
37
|
+
value: function initialize(obj) {}
|
|
38
|
+
|
|
39
|
+
/**
|
|
40
|
+
* Constructs a <code>DeviceTowerInfo</code> from a plain JavaScript object, optionally creating a new instance.
|
|
41
|
+
* Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
|
|
42
|
+
* @param {Object} data The plain JavaScript object bearing properties of interest.
|
|
43
|
+
* @param {module:model/DeviceTowerInfo} obj Optional instance to populate.
|
|
44
|
+
* @return {module:model/DeviceTowerInfo} The populated <code>DeviceTowerInfo</code> instance.
|
|
45
|
+
*/
|
|
46
|
+
}, {
|
|
47
|
+
key: "constructFromObject",
|
|
48
|
+
value: function constructFromObject(data, obj) {
|
|
49
|
+
if (data) {
|
|
50
|
+
obj = obj || new DeviceTowerInfo();
|
|
51
|
+
if (data.hasOwnProperty('mcc')) {
|
|
52
|
+
obj['mcc'] = _ApiClient["default"].convertToType(data['mcc'], 'Number');
|
|
53
|
+
}
|
|
54
|
+
if (data.hasOwnProperty('mnc')) {
|
|
55
|
+
obj['mnc'] = _ApiClient["default"].convertToType(data['mnc'], 'Number');
|
|
56
|
+
}
|
|
57
|
+
if (data.hasOwnProperty('lac')) {
|
|
58
|
+
obj['lac'] = _ApiClient["default"].convertToType(data['lac'], 'Number');
|
|
59
|
+
}
|
|
60
|
+
if (data.hasOwnProperty('cell_id')) {
|
|
61
|
+
obj['cell_id'] = _ApiClient["default"].convertToType(data['cell_id'], 'Number');
|
|
62
|
+
}
|
|
63
|
+
} else if (data === null) {
|
|
64
|
+
return null;
|
|
65
|
+
}
|
|
66
|
+
return obj;
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
/**
|
|
70
|
+
* Validates the JSON data with respect to <code>DeviceTowerInfo</code>.
|
|
71
|
+
* @param {Object} data The plain JavaScript object bearing properties of interest.
|
|
72
|
+
* @return {boolean} to indicate whether the JSON data is valid with respect to <code>DeviceTowerInfo</code>.
|
|
73
|
+
*/
|
|
74
|
+
}, {
|
|
75
|
+
key: "validateJSON",
|
|
76
|
+
value: function validateJSON(data) {
|
|
77
|
+
return true;
|
|
78
|
+
}
|
|
79
|
+
}]);
|
|
80
|
+
return DeviceTowerInfo;
|
|
81
|
+
}();
|
|
82
|
+
/**
|
|
83
|
+
* @member {Number} mcc
|
|
84
|
+
*/
|
|
85
|
+
DeviceTowerInfo.prototype['mcc'] = undefined;
|
|
86
|
+
|
|
87
|
+
/**
|
|
88
|
+
* @member {Number} mnc
|
|
89
|
+
*/
|
|
90
|
+
DeviceTowerInfo.prototype['mnc'] = undefined;
|
|
91
|
+
|
|
92
|
+
/**
|
|
93
|
+
* @member {Number} lac
|
|
94
|
+
*/
|
|
95
|
+
DeviceTowerInfo.prototype['lac'] = undefined;
|
|
96
|
+
|
|
97
|
+
/**
|
|
98
|
+
* @member {Number} cell_id
|
|
99
|
+
*/
|
|
100
|
+
DeviceTowerInfo.prototype['cell_id'] = undefined;
|
|
101
|
+
var _default = DeviceTowerInfo;
|
|
102
|
+
exports["default"] = _default;
|