@aceplus/smartace-api 3.2.0-alpha.3 → 3.2.0-alpha.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/meta.spic_alert_pb.d.ts +230 -0
- package/meta.spic_alert_pb.js +1615 -0
- package/meta.spic_alert_pb_service.d.ts +121 -0
- package/meta.spic_alert_pb_service.js +182 -0
- package/meta.spic_config_pb.d.ts +0 -29
- package/meta.spic_config_pb.js +0 -226
- package/meta.spic_config_pb_service.d.ts +11 -31
- package/meta.spic_config_pb_service.js +19 -60
- package/meta.spic_pb.d.ts +36 -0
- package/meta.spic_pb.js +254 -0
- package/meta.spic_pb_service.d.ts +64 -0
- package/meta.spic_pb_service.js +62 -0
- package/package.json +1 -1
|
@@ -3,94 +3,53 @@
|
|
|
3
3
|
|
|
4
4
|
var meta_spic_config_pb = require("./meta.spic_config_pb");
|
|
5
5
|
var google_protobuf_empty_pb = require("google-protobuf/google/protobuf/empty_pb");
|
|
6
|
-
var spic_cabinet_pb = require("./spic.cabinet_pb");
|
|
7
6
|
var grpc = require("@improbable-eng/grpc-web").grpc;
|
|
8
7
|
|
|
9
|
-
var
|
|
10
|
-
function
|
|
11
|
-
|
|
12
|
-
return
|
|
8
|
+
var MetaSpicConfigGRPC = (function () {
|
|
9
|
+
function MetaSpicConfigGRPC() {}
|
|
10
|
+
MetaSpicConfigGRPC.serviceName = "Meta.MetaSpicConfigGRPC";
|
|
11
|
+
return MetaSpicConfigGRPC;
|
|
13
12
|
}());
|
|
14
13
|
|
|
15
|
-
|
|
16
|
-
methodName: "Retrieve",
|
|
17
|
-
service: CabinetMetaGRPC,
|
|
18
|
-
requestStream: false,
|
|
19
|
-
responseStream: false,
|
|
20
|
-
requestType: spic_cabinet_pb.CabinetProto.RetrieveRequest,
|
|
21
|
-
responseType: meta_spic_config_pb.CabinetLocationMeta
|
|
22
|
-
};
|
|
23
|
-
|
|
24
|
-
CabinetMetaGRPC.SetTemperatureConfiguration = {
|
|
14
|
+
MetaSpicConfigGRPC.SetTemperatureConfiguration = {
|
|
25
15
|
methodName: "SetTemperatureConfiguration",
|
|
26
|
-
service:
|
|
16
|
+
service: MetaSpicConfigGRPC,
|
|
27
17
|
requestStream: false,
|
|
28
18
|
responseStream: false,
|
|
29
19
|
requestType: meta_spic_config_pb.TemperatureConfigurationProto.SetConfigurationRequest,
|
|
30
20
|
responseType: google_protobuf_empty_pb.Empty
|
|
31
21
|
};
|
|
32
22
|
|
|
33
|
-
|
|
23
|
+
MetaSpicConfigGRPC.CreateTemperatureConfigurationTemplate = {
|
|
34
24
|
methodName: "CreateTemperatureConfigurationTemplate",
|
|
35
|
-
service:
|
|
25
|
+
service: MetaSpicConfigGRPC,
|
|
36
26
|
requestStream: false,
|
|
37
27
|
responseStream: false,
|
|
38
28
|
requestType: meta_spic_config_pb.TemperatureConfigurationProto.CreateTemplateRequest,
|
|
39
29
|
responseType: google_protobuf_empty_pb.Empty
|
|
40
30
|
};
|
|
41
31
|
|
|
42
|
-
|
|
32
|
+
MetaSpicConfigGRPC.SearchTemperatureConfigurationTemplate = {
|
|
43
33
|
methodName: "SearchTemperatureConfigurationTemplate",
|
|
44
|
-
service:
|
|
34
|
+
service: MetaSpicConfigGRPC,
|
|
45
35
|
requestStream: false,
|
|
46
36
|
responseStream: false,
|
|
47
37
|
requestType: meta_spic_config_pb.TemperatureConfigurationProto.SearchTemplateRequest,
|
|
48
38
|
responseType: meta_spic_config_pb.TemperatureConfigurationProto.SearchTemplateReply
|
|
49
39
|
};
|
|
50
40
|
|
|
51
|
-
exports.
|
|
41
|
+
exports.MetaSpicConfigGRPC = MetaSpicConfigGRPC;
|
|
52
42
|
|
|
53
|
-
function
|
|
43
|
+
function MetaSpicConfigGRPCClient(serviceHost, options) {
|
|
54
44
|
this.serviceHost = serviceHost;
|
|
55
45
|
this.options = options || {};
|
|
56
46
|
}
|
|
57
47
|
|
|
58
|
-
|
|
59
|
-
if (arguments.length === 2) {
|
|
60
|
-
callback = arguments[1];
|
|
61
|
-
}
|
|
62
|
-
var client = grpc.unary(CabinetMetaGRPC.Retrieve, {
|
|
63
|
-
request: requestMessage,
|
|
64
|
-
host: this.serviceHost,
|
|
65
|
-
metadata: metadata,
|
|
66
|
-
transport: this.options.transport,
|
|
67
|
-
debug: this.options.debug,
|
|
68
|
-
onEnd: function (response) {
|
|
69
|
-
if (callback) {
|
|
70
|
-
if (response.status !== grpc.Code.OK) {
|
|
71
|
-
var err = new Error(response.statusMessage);
|
|
72
|
-
err.code = response.status;
|
|
73
|
-
err.metadata = response.trailers;
|
|
74
|
-
callback(err, null);
|
|
75
|
-
} else {
|
|
76
|
-
callback(null, response.message);
|
|
77
|
-
}
|
|
78
|
-
}
|
|
79
|
-
}
|
|
80
|
-
});
|
|
81
|
-
return {
|
|
82
|
-
cancel: function () {
|
|
83
|
-
callback = null;
|
|
84
|
-
client.close();
|
|
85
|
-
}
|
|
86
|
-
};
|
|
87
|
-
};
|
|
88
|
-
|
|
89
|
-
CabinetMetaGRPCClient.prototype.setTemperatureConfiguration = function setTemperatureConfiguration(requestMessage, metadata, callback) {
|
|
48
|
+
MetaSpicConfigGRPCClient.prototype.setTemperatureConfiguration = function setTemperatureConfiguration(requestMessage, metadata, callback) {
|
|
90
49
|
if (arguments.length === 2) {
|
|
91
50
|
callback = arguments[1];
|
|
92
51
|
}
|
|
93
|
-
var client = grpc.unary(
|
|
52
|
+
var client = grpc.unary(MetaSpicConfigGRPC.SetTemperatureConfiguration, {
|
|
94
53
|
request: requestMessage,
|
|
95
54
|
host: this.serviceHost,
|
|
96
55
|
metadata: metadata,
|
|
@@ -117,11 +76,11 @@ CabinetMetaGRPCClient.prototype.setTemperatureConfiguration = function setTemper
|
|
|
117
76
|
};
|
|
118
77
|
};
|
|
119
78
|
|
|
120
|
-
|
|
79
|
+
MetaSpicConfigGRPCClient.prototype.createTemperatureConfigurationTemplate = function createTemperatureConfigurationTemplate(requestMessage, metadata, callback) {
|
|
121
80
|
if (arguments.length === 2) {
|
|
122
81
|
callback = arguments[1];
|
|
123
82
|
}
|
|
124
|
-
var client = grpc.unary(
|
|
83
|
+
var client = grpc.unary(MetaSpicConfigGRPC.CreateTemperatureConfigurationTemplate, {
|
|
125
84
|
request: requestMessage,
|
|
126
85
|
host: this.serviceHost,
|
|
127
86
|
metadata: metadata,
|
|
@@ -148,11 +107,11 @@ CabinetMetaGRPCClient.prototype.createTemperatureConfigurationTemplate = functio
|
|
|
148
107
|
};
|
|
149
108
|
};
|
|
150
109
|
|
|
151
|
-
|
|
110
|
+
MetaSpicConfigGRPCClient.prototype.searchTemperatureConfigurationTemplate = function searchTemperatureConfigurationTemplate(requestMessage, metadata, callback) {
|
|
152
111
|
if (arguments.length === 2) {
|
|
153
112
|
callback = arguments[1];
|
|
154
113
|
}
|
|
155
|
-
var client = grpc.unary(
|
|
114
|
+
var client = grpc.unary(MetaSpicConfigGRPC.SearchTemperatureConfigurationTemplate, {
|
|
156
115
|
request: requestMessage,
|
|
157
116
|
host: this.serviceHost,
|
|
158
117
|
metadata: metadata,
|
|
@@ -179,5 +138,5 @@ CabinetMetaGRPCClient.prototype.searchTemperatureConfigurationTemplate = functio
|
|
|
179
138
|
};
|
|
180
139
|
};
|
|
181
140
|
|
|
182
|
-
exports.
|
|
141
|
+
exports.MetaSpicConfigGRPCClient = MetaSpicConfigGRPCClient;
|
|
183
142
|
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
// package: Meta
|
|
2
|
+
// file: meta.spic.proto
|
|
3
|
+
|
|
4
|
+
import * as jspb from "google-protobuf";
|
|
5
|
+
import * as spic_cabinet_pb from "./spic.cabinet_pb";
|
|
6
|
+
import * as google_api_annotations_pb from "./google/api/annotations_pb";
|
|
7
|
+
import * as meta_spic_config_pb from "./meta.spic_config_pb";
|
|
8
|
+
|
|
9
|
+
export class CabinetLocationMeta extends jspb.Message {
|
|
10
|
+
hasCabinetLocation(): boolean;
|
|
11
|
+
clearCabinetLocation(): void;
|
|
12
|
+
getCabinetLocation(): spic_cabinet_pb.CabinetWithLocation | undefined;
|
|
13
|
+
setCabinetLocation(value?: spic_cabinet_pb.CabinetWithLocation): void;
|
|
14
|
+
|
|
15
|
+
hasTemperatureConfiguration(): boolean;
|
|
16
|
+
clearTemperatureConfiguration(): void;
|
|
17
|
+
getTemperatureConfiguration(): meta_spic_config_pb.TemperatureConfigurationProto | undefined;
|
|
18
|
+
setTemperatureConfiguration(value?: meta_spic_config_pb.TemperatureConfigurationProto): void;
|
|
19
|
+
|
|
20
|
+
serializeBinary(): Uint8Array;
|
|
21
|
+
toObject(includeInstance?: boolean): CabinetLocationMeta.AsObject;
|
|
22
|
+
static toObject(includeInstance: boolean, msg: CabinetLocationMeta): CabinetLocationMeta.AsObject;
|
|
23
|
+
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
|
|
24
|
+
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
|
|
25
|
+
static serializeBinaryToWriter(message: CabinetLocationMeta, writer: jspb.BinaryWriter): void;
|
|
26
|
+
static deserializeBinary(bytes: Uint8Array): CabinetLocationMeta;
|
|
27
|
+
static deserializeBinaryFromReader(message: CabinetLocationMeta, reader: jspb.BinaryReader): CabinetLocationMeta;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
export namespace CabinetLocationMeta {
|
|
31
|
+
export type AsObject = {
|
|
32
|
+
cabinetLocation?: spic_cabinet_pb.CabinetWithLocation.AsObject,
|
|
33
|
+
temperatureConfiguration?: meta_spic_config_pb.TemperatureConfigurationProto.AsObject,
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
|
package/meta.spic_pb.js
ADDED
|
@@ -0,0 +1,254 @@
|
|
|
1
|
+
// source: meta.spic.proto
|
|
2
|
+
/**
|
|
3
|
+
* @fileoverview
|
|
4
|
+
* @enhanceable
|
|
5
|
+
* @suppress {missingRequire} reports error on implicit type usages.
|
|
6
|
+
* @suppress {messageConventions} JS Compiler reports an error if a variable or
|
|
7
|
+
* field starts with 'MSG_' and isn't a translatable message.
|
|
8
|
+
* @public
|
|
9
|
+
*/
|
|
10
|
+
// GENERATED CODE -- DO NOT EDIT!
|
|
11
|
+
/* eslint-disable */
|
|
12
|
+
// @ts-nocheck
|
|
13
|
+
|
|
14
|
+
var jspb = require('google-protobuf');
|
|
15
|
+
var goog = jspb;
|
|
16
|
+
var global =
|
|
17
|
+
(typeof globalThis !== 'undefined' && globalThis) ||
|
|
18
|
+
(typeof window !== 'undefined' && window) ||
|
|
19
|
+
(typeof global !== 'undefined' && global) ||
|
|
20
|
+
(typeof self !== 'undefined' && self) ||
|
|
21
|
+
(function () { return this; }).call(null) ||
|
|
22
|
+
Function('return this')();
|
|
23
|
+
|
|
24
|
+
var spic_cabinet_pb = require('./spic.cabinet_pb.js');
|
|
25
|
+
goog.object.extend(proto, spic_cabinet_pb);
|
|
26
|
+
var google_api_annotations_pb = require('./google/api/annotations_pb.js');
|
|
27
|
+
goog.object.extend(proto, google_api_annotations_pb);
|
|
28
|
+
var meta_spic_config_pb = require('./meta.spic_config_pb.js');
|
|
29
|
+
goog.object.extend(proto, meta_spic_config_pb);
|
|
30
|
+
goog.exportSymbol('proto.Meta.CabinetLocationMeta', null, global);
|
|
31
|
+
/**
|
|
32
|
+
* Generated by JsPbCodeGenerator.
|
|
33
|
+
* @param {Array=} opt_data Optional initial data array, typically from a
|
|
34
|
+
* server response, or constructed directly in Javascript. The array is used
|
|
35
|
+
* in place and becomes part of the constructed object. It is not cloned.
|
|
36
|
+
* If no data is provided, the constructed object will be empty, but still
|
|
37
|
+
* valid.
|
|
38
|
+
* @extends {jspb.Message}
|
|
39
|
+
* @constructor
|
|
40
|
+
*/
|
|
41
|
+
proto.Meta.CabinetLocationMeta = function(opt_data) {
|
|
42
|
+
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
|
|
43
|
+
};
|
|
44
|
+
goog.inherits(proto.Meta.CabinetLocationMeta, jspb.Message);
|
|
45
|
+
if (goog.DEBUG && !COMPILED) {
|
|
46
|
+
/**
|
|
47
|
+
* @public
|
|
48
|
+
* @override
|
|
49
|
+
*/
|
|
50
|
+
proto.Meta.CabinetLocationMeta.displayName = 'proto.Meta.CabinetLocationMeta';
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
|
|
54
|
+
|
|
55
|
+
if (jspb.Message.GENERATE_TO_OBJECT) {
|
|
56
|
+
/**
|
|
57
|
+
* Creates an object representation of this proto.
|
|
58
|
+
* Field names that are reserved in JavaScript and will be renamed to pb_name.
|
|
59
|
+
* Optional fields that are not set will be set to undefined.
|
|
60
|
+
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
|
|
61
|
+
* For the list of reserved names please see:
|
|
62
|
+
* net/proto2/compiler/js/internal/generator.cc#kKeyword.
|
|
63
|
+
* @param {boolean=} opt_includeInstance Deprecated. whether to include the
|
|
64
|
+
* JSPB instance for transitional soy proto support:
|
|
65
|
+
* http://goto/soy-param-migration
|
|
66
|
+
* @return {!Object}
|
|
67
|
+
*/
|
|
68
|
+
proto.Meta.CabinetLocationMeta.prototype.toObject = function(opt_includeInstance) {
|
|
69
|
+
return proto.Meta.CabinetLocationMeta.toObject(opt_includeInstance, this);
|
|
70
|
+
};
|
|
71
|
+
|
|
72
|
+
|
|
73
|
+
/**
|
|
74
|
+
* Static version of the {@see toObject} method.
|
|
75
|
+
* @param {boolean|undefined} includeInstance Deprecated. Whether to include
|
|
76
|
+
* the JSPB instance for transitional soy proto support:
|
|
77
|
+
* http://goto/soy-param-migration
|
|
78
|
+
* @param {!proto.Meta.CabinetLocationMeta} msg The msg instance to transform.
|
|
79
|
+
* @return {!Object}
|
|
80
|
+
* @suppress {unusedLocalVariables} f is only used for nested messages
|
|
81
|
+
*/
|
|
82
|
+
proto.Meta.CabinetLocationMeta.toObject = function(includeInstance, msg) {
|
|
83
|
+
var f, obj = {
|
|
84
|
+
cabinetLocation: (f = msg.getCabinetLocation()) && spic_cabinet_pb.CabinetWithLocation.toObject(includeInstance, f),
|
|
85
|
+
temperatureConfiguration: (f = msg.getTemperatureConfiguration()) && meta_spic_config_pb.TemperatureConfigurationProto.toObject(includeInstance, f)
|
|
86
|
+
};
|
|
87
|
+
|
|
88
|
+
if (includeInstance) {
|
|
89
|
+
obj.$jspbMessageInstance = msg;
|
|
90
|
+
}
|
|
91
|
+
return obj;
|
|
92
|
+
};
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
|
|
96
|
+
/**
|
|
97
|
+
* Deserializes binary data (in protobuf wire format).
|
|
98
|
+
* @param {jspb.ByteSource} bytes The bytes to deserialize.
|
|
99
|
+
* @return {!proto.Meta.CabinetLocationMeta}
|
|
100
|
+
*/
|
|
101
|
+
proto.Meta.CabinetLocationMeta.deserializeBinary = function(bytes) {
|
|
102
|
+
var reader = new jspb.BinaryReader(bytes);
|
|
103
|
+
var msg = new proto.Meta.CabinetLocationMeta;
|
|
104
|
+
return proto.Meta.CabinetLocationMeta.deserializeBinaryFromReader(msg, reader);
|
|
105
|
+
};
|
|
106
|
+
|
|
107
|
+
|
|
108
|
+
/**
|
|
109
|
+
* Deserializes binary data (in protobuf wire format) from the
|
|
110
|
+
* given reader into the given message object.
|
|
111
|
+
* @param {!proto.Meta.CabinetLocationMeta} msg The message object to deserialize into.
|
|
112
|
+
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
|
|
113
|
+
* @return {!proto.Meta.CabinetLocationMeta}
|
|
114
|
+
*/
|
|
115
|
+
proto.Meta.CabinetLocationMeta.deserializeBinaryFromReader = function(msg, reader) {
|
|
116
|
+
while (reader.nextField()) {
|
|
117
|
+
if (reader.isEndGroup()) {
|
|
118
|
+
break;
|
|
119
|
+
}
|
|
120
|
+
var field = reader.getFieldNumber();
|
|
121
|
+
switch (field) {
|
|
122
|
+
case 1:
|
|
123
|
+
var value = new spic_cabinet_pb.CabinetWithLocation;
|
|
124
|
+
reader.readMessage(value,spic_cabinet_pb.CabinetWithLocation.deserializeBinaryFromReader);
|
|
125
|
+
msg.setCabinetLocation(value);
|
|
126
|
+
break;
|
|
127
|
+
case 2:
|
|
128
|
+
var value = new meta_spic_config_pb.TemperatureConfigurationProto;
|
|
129
|
+
reader.readMessage(value,meta_spic_config_pb.TemperatureConfigurationProto.deserializeBinaryFromReader);
|
|
130
|
+
msg.setTemperatureConfiguration(value);
|
|
131
|
+
break;
|
|
132
|
+
default:
|
|
133
|
+
reader.skipField();
|
|
134
|
+
break;
|
|
135
|
+
}
|
|
136
|
+
}
|
|
137
|
+
return msg;
|
|
138
|
+
};
|
|
139
|
+
|
|
140
|
+
|
|
141
|
+
/**
|
|
142
|
+
* Serializes the message to binary data (in protobuf wire format).
|
|
143
|
+
* @return {!Uint8Array}
|
|
144
|
+
*/
|
|
145
|
+
proto.Meta.CabinetLocationMeta.prototype.serializeBinary = function() {
|
|
146
|
+
var writer = new jspb.BinaryWriter();
|
|
147
|
+
proto.Meta.CabinetLocationMeta.serializeBinaryToWriter(this, writer);
|
|
148
|
+
return writer.getResultBuffer();
|
|
149
|
+
};
|
|
150
|
+
|
|
151
|
+
|
|
152
|
+
/**
|
|
153
|
+
* Serializes the given message to binary data (in protobuf wire
|
|
154
|
+
* format), writing to the given BinaryWriter.
|
|
155
|
+
* @param {!proto.Meta.CabinetLocationMeta} message
|
|
156
|
+
* @param {!jspb.BinaryWriter} writer
|
|
157
|
+
* @suppress {unusedLocalVariables} f is only used for nested messages
|
|
158
|
+
*/
|
|
159
|
+
proto.Meta.CabinetLocationMeta.serializeBinaryToWriter = function(message, writer) {
|
|
160
|
+
var f = undefined;
|
|
161
|
+
f = message.getCabinetLocation();
|
|
162
|
+
if (f != null) {
|
|
163
|
+
writer.writeMessage(
|
|
164
|
+
1,
|
|
165
|
+
f,
|
|
166
|
+
spic_cabinet_pb.CabinetWithLocation.serializeBinaryToWriter
|
|
167
|
+
);
|
|
168
|
+
}
|
|
169
|
+
f = message.getTemperatureConfiguration();
|
|
170
|
+
if (f != null) {
|
|
171
|
+
writer.writeMessage(
|
|
172
|
+
2,
|
|
173
|
+
f,
|
|
174
|
+
meta_spic_config_pb.TemperatureConfigurationProto.serializeBinaryToWriter
|
|
175
|
+
);
|
|
176
|
+
}
|
|
177
|
+
};
|
|
178
|
+
|
|
179
|
+
|
|
180
|
+
/**
|
|
181
|
+
* optional Spic.CabinetWithLocation cabinet_location = 1;
|
|
182
|
+
* @return {?proto.Spic.CabinetWithLocation}
|
|
183
|
+
*/
|
|
184
|
+
proto.Meta.CabinetLocationMeta.prototype.getCabinetLocation = function() {
|
|
185
|
+
return /** @type{?proto.Spic.CabinetWithLocation} */ (
|
|
186
|
+
jspb.Message.getWrapperField(this, spic_cabinet_pb.CabinetWithLocation, 1));
|
|
187
|
+
};
|
|
188
|
+
|
|
189
|
+
|
|
190
|
+
/**
|
|
191
|
+
* @param {?proto.Spic.CabinetWithLocation|undefined} value
|
|
192
|
+
* @return {!proto.Meta.CabinetLocationMeta} returns this
|
|
193
|
+
*/
|
|
194
|
+
proto.Meta.CabinetLocationMeta.prototype.setCabinetLocation = function(value) {
|
|
195
|
+
return jspb.Message.setWrapperField(this, 1, value);
|
|
196
|
+
};
|
|
197
|
+
|
|
198
|
+
|
|
199
|
+
/**
|
|
200
|
+
* Clears the message field making it undefined.
|
|
201
|
+
* @return {!proto.Meta.CabinetLocationMeta} returns this
|
|
202
|
+
*/
|
|
203
|
+
proto.Meta.CabinetLocationMeta.prototype.clearCabinetLocation = function() {
|
|
204
|
+
return this.setCabinetLocation(undefined);
|
|
205
|
+
};
|
|
206
|
+
|
|
207
|
+
|
|
208
|
+
/**
|
|
209
|
+
* Returns whether this field is set.
|
|
210
|
+
* @return {boolean}
|
|
211
|
+
*/
|
|
212
|
+
proto.Meta.CabinetLocationMeta.prototype.hasCabinetLocation = function() {
|
|
213
|
+
return jspb.Message.getField(this, 1) != null;
|
|
214
|
+
};
|
|
215
|
+
|
|
216
|
+
|
|
217
|
+
/**
|
|
218
|
+
* optional TemperatureConfigurationProto temperature_configuration = 2;
|
|
219
|
+
* @return {?proto.Meta.TemperatureConfigurationProto}
|
|
220
|
+
*/
|
|
221
|
+
proto.Meta.CabinetLocationMeta.prototype.getTemperatureConfiguration = function() {
|
|
222
|
+
return /** @type{?proto.Meta.TemperatureConfigurationProto} */ (
|
|
223
|
+
jspb.Message.getWrapperField(this, meta_spic_config_pb.TemperatureConfigurationProto, 2));
|
|
224
|
+
};
|
|
225
|
+
|
|
226
|
+
|
|
227
|
+
/**
|
|
228
|
+
* @param {?proto.Meta.TemperatureConfigurationProto|undefined} value
|
|
229
|
+
* @return {!proto.Meta.CabinetLocationMeta} returns this
|
|
230
|
+
*/
|
|
231
|
+
proto.Meta.CabinetLocationMeta.prototype.setTemperatureConfiguration = function(value) {
|
|
232
|
+
return jspb.Message.setWrapperField(this, 2, value);
|
|
233
|
+
};
|
|
234
|
+
|
|
235
|
+
|
|
236
|
+
/**
|
|
237
|
+
* Clears the message field making it undefined.
|
|
238
|
+
* @return {!proto.Meta.CabinetLocationMeta} returns this
|
|
239
|
+
*/
|
|
240
|
+
proto.Meta.CabinetLocationMeta.prototype.clearTemperatureConfiguration = function() {
|
|
241
|
+
return this.setTemperatureConfiguration(undefined);
|
|
242
|
+
};
|
|
243
|
+
|
|
244
|
+
|
|
245
|
+
/**
|
|
246
|
+
* Returns whether this field is set.
|
|
247
|
+
* @return {boolean}
|
|
248
|
+
*/
|
|
249
|
+
proto.Meta.CabinetLocationMeta.prototype.hasTemperatureConfiguration = function() {
|
|
250
|
+
return jspb.Message.getField(this, 2) != null;
|
|
251
|
+
};
|
|
252
|
+
|
|
253
|
+
|
|
254
|
+
goog.object.extend(exports, proto.Meta);
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
// package: Meta
|
|
2
|
+
// file: meta.spic.proto
|
|
3
|
+
|
|
4
|
+
import * as meta_spic_pb from "./meta.spic_pb";
|
|
5
|
+
import * as spic_cabinet_pb from "./spic.cabinet_pb";
|
|
6
|
+
import {grpc} from "@improbable-eng/grpc-web";
|
|
7
|
+
|
|
8
|
+
type MetaSpicGRPCRetrieve = {
|
|
9
|
+
readonly methodName: string;
|
|
10
|
+
readonly service: typeof MetaSpicGRPC;
|
|
11
|
+
readonly requestStream: false;
|
|
12
|
+
readonly responseStream: false;
|
|
13
|
+
readonly requestType: typeof spic_cabinet_pb.CabinetProto.RetrieveRequest;
|
|
14
|
+
readonly responseType: typeof meta_spic_pb.CabinetLocationMeta;
|
|
15
|
+
};
|
|
16
|
+
|
|
17
|
+
export class MetaSpicGRPC {
|
|
18
|
+
static readonly serviceName: string;
|
|
19
|
+
static readonly Retrieve: MetaSpicGRPCRetrieve;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
export type ServiceError = { message: string, code: number; metadata: grpc.Metadata }
|
|
23
|
+
export type Status = { details: string, code: number; metadata: grpc.Metadata }
|
|
24
|
+
|
|
25
|
+
interface UnaryResponse {
|
|
26
|
+
cancel(): void;
|
|
27
|
+
}
|
|
28
|
+
interface ResponseStream<T> {
|
|
29
|
+
cancel(): void;
|
|
30
|
+
on(type: 'data', handler: (message: T) => void): ResponseStream<T>;
|
|
31
|
+
on(type: 'end', handler: (status?: Status) => void): ResponseStream<T>;
|
|
32
|
+
on(type: 'status', handler: (status: Status) => void): ResponseStream<T>;
|
|
33
|
+
}
|
|
34
|
+
interface RequestStream<T> {
|
|
35
|
+
write(message: T): RequestStream<T>;
|
|
36
|
+
end(): void;
|
|
37
|
+
cancel(): void;
|
|
38
|
+
on(type: 'end', handler: (status?: Status) => void): RequestStream<T>;
|
|
39
|
+
on(type: 'status', handler: (status: Status) => void): RequestStream<T>;
|
|
40
|
+
}
|
|
41
|
+
interface BidirectionalStream<ReqT, ResT> {
|
|
42
|
+
write(message: ReqT): BidirectionalStream<ReqT, ResT>;
|
|
43
|
+
end(): void;
|
|
44
|
+
cancel(): void;
|
|
45
|
+
on(type: 'data', handler: (message: ResT) => void): BidirectionalStream<ReqT, ResT>;
|
|
46
|
+
on(type: 'end', handler: (status?: Status) => void): BidirectionalStream<ReqT, ResT>;
|
|
47
|
+
on(type: 'status', handler: (status: Status) => void): BidirectionalStream<ReqT, ResT>;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
export class MetaSpicGRPCClient {
|
|
51
|
+
readonly serviceHost: string;
|
|
52
|
+
|
|
53
|
+
constructor(serviceHost: string, options?: grpc.RpcOptions);
|
|
54
|
+
retrieve(
|
|
55
|
+
requestMessage: spic_cabinet_pb.CabinetProto.RetrieveRequest,
|
|
56
|
+
metadata: grpc.Metadata,
|
|
57
|
+
callback: (error: ServiceError|null, responseMessage: meta_spic_pb.CabinetLocationMeta|null) => void
|
|
58
|
+
): UnaryResponse;
|
|
59
|
+
retrieve(
|
|
60
|
+
requestMessage: spic_cabinet_pb.CabinetProto.RetrieveRequest,
|
|
61
|
+
callback: (error: ServiceError|null, responseMessage: meta_spic_pb.CabinetLocationMeta|null) => void
|
|
62
|
+
): UnaryResponse;
|
|
63
|
+
}
|
|
64
|
+
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
// package: Meta
|
|
2
|
+
// file: meta.spic.proto
|
|
3
|
+
|
|
4
|
+
var meta_spic_pb = require("./meta.spic_pb");
|
|
5
|
+
var spic_cabinet_pb = require("./spic.cabinet_pb");
|
|
6
|
+
var grpc = require("@improbable-eng/grpc-web").grpc;
|
|
7
|
+
|
|
8
|
+
var MetaSpicGRPC = (function () {
|
|
9
|
+
function MetaSpicGRPC() {}
|
|
10
|
+
MetaSpicGRPC.serviceName = "Meta.MetaSpicGRPC";
|
|
11
|
+
return MetaSpicGRPC;
|
|
12
|
+
}());
|
|
13
|
+
|
|
14
|
+
MetaSpicGRPC.Retrieve = {
|
|
15
|
+
methodName: "Retrieve",
|
|
16
|
+
service: MetaSpicGRPC,
|
|
17
|
+
requestStream: false,
|
|
18
|
+
responseStream: false,
|
|
19
|
+
requestType: spic_cabinet_pb.CabinetProto.RetrieveRequest,
|
|
20
|
+
responseType: meta_spic_pb.CabinetLocationMeta
|
|
21
|
+
};
|
|
22
|
+
|
|
23
|
+
exports.MetaSpicGRPC = MetaSpicGRPC;
|
|
24
|
+
|
|
25
|
+
function MetaSpicGRPCClient(serviceHost, options) {
|
|
26
|
+
this.serviceHost = serviceHost;
|
|
27
|
+
this.options = options || {};
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
MetaSpicGRPCClient.prototype.retrieve = function retrieve(requestMessage, metadata, callback) {
|
|
31
|
+
if (arguments.length === 2) {
|
|
32
|
+
callback = arguments[1];
|
|
33
|
+
}
|
|
34
|
+
var client = grpc.unary(MetaSpicGRPC.Retrieve, {
|
|
35
|
+
request: requestMessage,
|
|
36
|
+
host: this.serviceHost,
|
|
37
|
+
metadata: metadata,
|
|
38
|
+
transport: this.options.transport,
|
|
39
|
+
debug: this.options.debug,
|
|
40
|
+
onEnd: function (response) {
|
|
41
|
+
if (callback) {
|
|
42
|
+
if (response.status !== grpc.Code.OK) {
|
|
43
|
+
var err = new Error(response.statusMessage);
|
|
44
|
+
err.code = response.status;
|
|
45
|
+
err.metadata = response.trailers;
|
|
46
|
+
callback(err, null);
|
|
47
|
+
} else {
|
|
48
|
+
callback(null, response.message);
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
});
|
|
53
|
+
return {
|
|
54
|
+
cancel: function () {
|
|
55
|
+
callback = null;
|
|
56
|
+
client.close();
|
|
57
|
+
}
|
|
58
|
+
};
|
|
59
|
+
};
|
|
60
|
+
|
|
61
|
+
exports.MetaSpicGRPCClient = MetaSpicGRPCClient;
|
|
62
|
+
|