@aceplus/smartace-api 3.6.0 → 3.7.0-alpha.1

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.
Files changed (245) hide show
  1. package/package.json +1 -1
  2. package/auth.account_pb.d.ts +0 -582
  3. package/auth.account_pb.js +0 -4287
  4. package/auth.account_pb_service.d.ts +0 -340
  5. package/auth.account_pb_service.js +0 -637
  6. package/auth.account_two_factor_pb.d.ts +0 -159
  7. package/auth.account_two_factor_pb.js +0 -1184
  8. package/auth.account_two_factor_pb_service.d.ts +0 -121
  9. package/auth.account_two_factor_pb_service.js +0 -182
  10. package/auth.app_account_pb.d.ts +0 -156
  11. package/auth.app_account_pb.js +0 -1153
  12. package/auth.app_account_pb_service.d.ts +0 -160
  13. package/auth.app_account_pb_service.js +0 -263
  14. package/auth.app_authn_pb.d.ts +0 -172
  15. package/auth.app_authn_pb.js +0 -1233
  16. package/auth.app_authn_pb_service.d.ts +0 -140
  17. package/auth.app_authn_pb_service.js +0 -222
  18. package/auth.app_distribution_pb.d.ts +0 -174
  19. package/auth.app_distribution_pb.js +0 -1338
  20. package/auth.app_distribution_pb_service.d.ts +0 -120
  21. package/auth.app_distribution_pb_service.js +0 -181
  22. package/auth.authn_pb.d.ts +0 -95
  23. package/auth.authn_pb.js +0 -637
  24. package/auth.authn_pb_service.d.ts +0 -82
  25. package/auth.authn_pb_service.js +0 -101
  26. package/auth.cluster_pb.d.ts +0 -142
  27. package/auth.cluster_pb.js +0 -1050
  28. package/auth.cluster_pb_service.d.ts +0 -82
  29. package/auth.cluster_pb_service.js +0 -101
  30. package/auth.distribution_pb.d.ts +0 -233
  31. package/auth.distribution_pb.js +0 -1785
  32. package/auth.distribution_pb_service.d.ts +0 -82
  33. package/auth.distribution_pb_service.js +0 -101
  34. package/auth.email_pb.d.ts +0 -217
  35. package/auth.email_pb.js +0 -1508
  36. package/auth.email_pb_service.d.ts +0 -102
  37. package/auth.email_pb_service.js +0 -142
  38. package/auth.firmware_pb.d.ts +0 -256
  39. package/auth.firmware_pb.js +0 -1997
  40. package/auth.firmware_pb_service.d.ts +0 -120
  41. package/auth.firmware_pb_service.js +0 -181
  42. package/auth.push_notification_pb.d.ts +0 -69
  43. package/auth.push_notification_pb.js +0 -411
  44. package/auth.push_notification_pb_service.d.ts +0 -64
  45. package/auth.push_notification_pb_service.js +0 -62
  46. package/auth.sms_pb.d.ts +0 -79
  47. package/auth.sms_pb.js +0 -575
  48. package/auth.sms_pb_service.d.ts +0 -83
  49. package/auth.sms_pb_service.js +0 -102
  50. package/google/api/annotations_pb.d.ts +0 -9
  51. package/google/api/annotations_pb.js +0 -54
  52. package/google/api/annotations_pb_service.d.ts +0 -3
  53. package/google/api/annotations_pb_service.js +0 -3
  54. package/google/api/auth_pb.d.ts +0 -150
  55. package/google/api/auth_pb.js +0 -1160
  56. package/google/api/auth_pb_service.d.ts +0 -3
  57. package/google/api/auth_pb_service.js +0 -3
  58. package/google/api/backend_pb.d.ts +0 -59
  59. package/google/api/backend_pb.js +0 -448
  60. package/google/api/backend_pb_service.d.ts +0 -3
  61. package/google/api/backend_pb_service.js +0 -3
  62. package/google/api/billing_pb.d.ts +0 -54
  63. package/google/api/billing_pb.js +0 -416
  64. package/google/api/billing_pb_service.d.ts +0 -3
  65. package/google/api/billing_pb_service.js +0 -3
  66. package/google/api/client_pb.d.ts +0 -12
  67. package/google/api/client_pb.js +0 -104
  68. package/google/api/client_pb_service.d.ts +0 -3
  69. package/google/api/client_pb_service.js +0 -3
  70. package/google/api/config_change_pb.d.ts +0 -72
  71. package/google/api/config_change_pb.js +0 -489
  72. package/google/api/config_change_pb_service.d.ts +0 -3
  73. package/google/api/config_change_pb_service.js +0 -3
  74. package/google/api/consumer_pb.d.ts +0 -65
  75. package/google/api/consumer_pb.js +0 -430
  76. package/google/api/consumer_pb_service.d.ts +0 -3
  77. package/google/api/consumer_pb_service.js +0 -3
  78. package/google/api/context_pb.d.ts +0 -59
  79. package/google/api/context_pb.js +0 -463
  80. package/google/api/context_pb_service.d.ts +0 -3
  81. package/google/api/context_pb_service.js +0 -3
  82. package/google/api/control_pb.d.ts +0 -25
  83. package/google/api/control_pb.js +0 -176
  84. package/google/api/control_pb_service.d.ts +0 -3
  85. package/google/api/control_pb_service.js +0 -3
  86. package/google/api/distribution_pb.d.ts +0 -235
  87. package/google/api/distribution_pb.js +0 -1805
  88. package/google/api/distribution_pb_service.d.ts +0 -3
  89. package/google/api/distribution_pb_service.js +0 -3
  90. package/google/api/documentation_pb.d.ts +0 -103
  91. package/google/api/documentation_pb.js +0 -803
  92. package/google/api/documentation_pb_service.d.ts +0 -3
  93. package/google/api/documentation_pb_service.js +0 -3
  94. package/google/api/endpoint_pb.d.ts +0 -46
  95. package/google/api/endpoint_pb.js +0 -343
  96. package/google/api/endpoint_pb_service.d.ts +0 -3
  97. package/google/api/endpoint_pb_service.js +0 -3
  98. package/google/api/error_reason_pb.d.ts +0 -40
  99. package/google/api/error_reason_pb.js +0 -61
  100. package/google/api/error_reason_pb_service.d.ts +0 -3
  101. package/google/api/error_reason_pb_service.js +0 -3
  102. package/google/api/field_behavior_pb.d.ts +0 -20
  103. package/google/api/field_behavior_pb.js +0 -66
  104. package/google/api/field_behavior_pb_service.d.ts +0 -3
  105. package/google/api/field_behavior_pb_service.js +0 -3
  106. package/google/api/http_pb.d.ts +0 -136
  107. package/google/api/http_pb.js +0 -1012
  108. package/google/api/http_pb_service.d.ts +0 -3
  109. package/google/api/http_pb_service.js +0 -3
  110. package/google/api/httpbody_pb.d.ts +0 -38
  111. package/google/api/httpbody_pb.js +0 -292
  112. package/google/api/httpbody_pb_service.d.ts +0 -3
  113. package/google/api/httpbody_pb_service.js +0 -3
  114. package/google/api/label_pb.d.ts +0 -41
  115. package/google/api/label_pb.js +0 -246
  116. package/google/api/label_pb_service.d.ts +0 -3
  117. package/google/api/label_pb_service.js +0 -3
  118. package/google/api/launch_stage_pb.d.ts +0 -16
  119. package/google/api/launch_stage_pb.js +0 -37
  120. package/google/api/launch_stage_pb_service.d.ts +0 -3
  121. package/google/api/launch_stage_pb_service.js +0 -3
  122. package/google/api/log_pb.d.ts +0 -40
  123. package/google/api/log_pb.js +0 -298
  124. package/google/api/log_pb_service.d.ts +0 -3
  125. package/google/api/log_pb_service.js +0 -3
  126. package/google/api/logging_pb.d.ts +0 -60
  127. package/google/api/logging_pb.js +0 -469
  128. package/google/api/logging_pb_service.d.ts +0 -3
  129. package/google/api/logging_pb_service.js +0 -3
  130. package/google/api/metric_pb.d.ts +0 -100
  131. package/google/api/metric_pb.js +0 -629
  132. package/google/api/metric_pb_service.d.ts +0 -3
  133. package/google/api/metric_pb_service.js +0 -3
  134. package/google/api/monitored_resource_pb.d.ts +0 -93
  135. package/google/api/monitored_resource_pb.js +0 -723
  136. package/google/api/monitored_resource_pb_service.d.ts +0 -3
  137. package/google/api/monitored_resource_pb_service.js +0 -3
  138. package/google/api/monitoring_pb.d.ts +0 -60
  139. package/google/api/monitoring_pb.js +0 -469
  140. package/google/api/monitoring_pb_service.d.ts +0 -3
  141. package/google/api/monitoring_pb_service.js +0 -3
  142. package/google/api/policy_pb.d.ts +0 -64
  143. package/google/api/policy_pb.js +0 -502
  144. package/google/api/policy_pb_service.d.ts +0 -3
  145. package/google/api/policy_pb_service.js +0 -3
  146. package/google/api/quota_pb.d.ts +0 -112
  147. package/google/api/quota_pb.js +0 -873
  148. package/google/api/quota_pb_service.d.ts +0 -3
  149. package/google/api/quota_pb_service.js +0 -3
  150. package/google/api/resource_pb.d.ts +0 -99
  151. package/google/api/resource_pb.js +0 -684
  152. package/google/api/resource_pb_service.d.ts +0 -3
  153. package/google/api/resource_pb_service.js +0 -3
  154. package/google/api/routing_pb.d.ts +0 -54
  155. package/google/api/routing_pb.js +0 -416
  156. package/google/api/routing_pb_service.d.ts +0 -3
  157. package/google/api/routing_pb_service.js +0 -3
  158. package/google/api/service_pb.d.ts +0 -184
  159. package/google/api/service_pb.js +0 -1400
  160. package/google/api/service_pb_service.d.ts +0 -3
  161. package/google/api/service_pb_service.js +0 -3
  162. package/google/api/source_info_pb.d.ts +0 -28
  163. package/google/api/source_info_pb.js +0 -208
  164. package/google/api/source_info_pb_service.d.ts +0 -3
  165. package/google/api/source_info_pb_service.js +0 -3
  166. package/google/api/system_parameter_pb.d.ts +0 -81
  167. package/google/api/system_parameter_pb.js +0 -630
  168. package/google/api/system_parameter_pb_service.d.ts +0 -3
  169. package/google/api/system_parameter_pb_service.js +0 -3
  170. package/google/api/usage_pb.d.ts +0 -66
  171. package/google/api/usage_pb.js +0 -499
  172. package/google/api/usage_pb_service.d.ts +0 -3
  173. package/google/api/usage_pb_service.js +0 -3
  174. package/google/api/visibility_pb.d.ts +0 -64
  175. package/google/api/visibility_pb.js +0 -546
  176. package/google/api/visibility_pb_service.d.ts +0 -3
  177. package/google/api/visibility_pb_service.js +0 -3
  178. package/meta.client_pb.d.ts +0 -167
  179. package/meta.client_pb.js +0 -1266
  180. package/meta.client_pb_service.d.ts +0 -122
  181. package/meta.client_pb_service.js +0 -183
  182. package/meta.spic_config_pb.d.ts +0 -184
  183. package/meta.spic_config_pb.js +0 -1382
  184. package/meta.spic_config_pb_service.d.ts +0 -122
  185. package/meta.spic_config_pb_service.js +0 -183
  186. package/platform.activity_log_pb.d.ts +0 -177
  187. package/platform.activity_log_pb.js +0 -1294
  188. package/platform.activity_log_pb_service.d.ts +0 -82
  189. package/platform.activity_log_pb_service.js +0 -101
  190. package/platform.client_pb.d.ts +0 -350
  191. package/platform.client_pb.js +0 -2663
  192. package/platform.client_pb_service.d.ts +0 -158
  193. package/platform.client_pb_service.js +0 -261
  194. package/platform.group_pb.d.ts +0 -195
  195. package/platform.group_pb.js +0 -1476
  196. package/platform.group_pb_service.d.ts +0 -139
  197. package/platform.group_pb_service.js +0 -221
  198. package/platform.local_account_internal_pb.d.ts +0 -125
  199. package/platform.local_account_internal_pb.js +0 -933
  200. package/platform.local_account_internal_pb_service.d.ts +0 -121
  201. package/platform.local_account_internal_pb_service.js +0 -182
  202. package/platform.local_account_pb.d.ts +0 -446
  203. package/platform.local_account_pb.js +0 -3337
  204. package/platform.local_account_pb_service.d.ts +0 -331
  205. package/platform.local_account_pb_service.js +0 -623
  206. package/platform.local_distribution_pb.d.ts +0 -73
  207. package/platform.local_distribution_pb.js +0 -536
  208. package/platform.local_distribution_pb_service.d.ts +0 -63
  209. package/platform.local_distribution_pb_service.js +0 -61
  210. package/platform.location_pb.d.ts +0 -271
  211. package/platform.location_pb.js +0 -2046
  212. package/platform.location_pb_service.d.ts +0 -139
  213. package/platform.location_pb_service.js +0 -221
  214. package/platform.pagination_pb.d.ts +0 -45
  215. package/platform.pagination_pb.js +0 -276
  216. package/platform.pagination_pb_service.d.ts +0 -3
  217. package/platform.pagination_pb_service.js +0 -3
  218. package/spic.alarm_pb.d.ts +0 -382
  219. package/spic.alarm_pb.js +0 -2915
  220. package/spic.alarm_pb_service.d.ts +0 -101
  221. package/spic.alarm_pb_service.js +0 -141
  222. package/spic.asset_pb.d.ts +0 -689
  223. package/spic.asset_pb.js +0 -4935
  224. package/spic.asset_pb_service.d.ts +0 -197
  225. package/spic.asset_pb_service.js +0 -342
  226. package/spic.cabinet_pb.d.ts +0 -1062
  227. package/spic.cabinet_pb.js +0 -7723
  228. package/spic.cabinet_pb_service.d.ts +0 -245
  229. package/spic.cabinet_pb_service.js +0 -437
  230. package/spic.config_pb.d.ts +0 -249
  231. package/spic.config_pb.js +0 -1891
  232. package/spic.config_pb_service.d.ts +0 -120
  233. package/spic.config_pb_service.js +0 -181
  234. package/spic.contractor_pb.d.ts +0 -195
  235. package/spic.contractor_pb.js +0 -1476
  236. package/spic.contractor_pb_service.d.ts +0 -139
  237. package/spic.contractor_pb_service.js +0 -221
  238. package/spic.history_pb.d.ts +0 -142
  239. package/spic.history_pb.js +0 -1130
  240. package/spic.history_pb_service.d.ts +0 -63
  241. package/spic.history_pb_service.js +0 -61
  242. package/spic.open_request_pb.d.ts +0 -237
  243. package/spic.open_request_pb.js +0 -1784
  244. package/spic.open_request_pb_service.d.ts +0 -101
  245. package/spic.open_request_pb_service.js +0 -141
package/spic.asset_pb.js DELETED
@@ -1,4935 +0,0 @@
1
- // source: spic.asset.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 google_protobuf_empty_pb = require('google-protobuf/google/protobuf/empty_pb.js');
25
- goog.object.extend(proto, google_protobuf_empty_pb);
26
- var google_protobuf_wrappers_pb = require('google-protobuf/google/protobuf/wrappers_pb.js');
27
- goog.object.extend(proto, google_protobuf_wrappers_pb);
28
- var google_protobuf_timestamp_pb = require('google-protobuf/google/protobuf/timestamp_pb.js');
29
- goog.object.extend(proto, google_protobuf_timestamp_pb);
30
- var platform_location_pb = require('./platform.location_pb.js');
31
- goog.object.extend(proto, platform_location_pb);
32
- var platform_pagination_pb = require('./platform.pagination_pb.js');
33
- goog.object.extend(proto, platform_pagination_pb);
34
- var google_api_annotations_pb = require('./google/api/annotations_pb.js');
35
- goog.object.extend(proto, google_api_annotations_pb);
36
- goog.exportSymbol('proto.Spic.AssetProto', null, global);
37
- goog.exportSymbol('proto.Spic.AssetProto.AssetType', null, global);
38
- goog.exportSymbol('proto.Spic.AssetProto.BatteryStatus', null, global);
39
- goog.exportSymbol('proto.Spic.AssetProto.ComponentState', null, global);
40
- goog.exportSymbol('proto.Spic.AssetProto.CreateRequest', null, global);
41
- goog.exportSymbol('proto.Spic.AssetProto.DeleteRequest', null, global);
42
- goog.exportSymbol('proto.Spic.AssetProto.DeleteRequest.SearchCase', null, global);
43
- goog.exportSymbol('proto.Spic.AssetProto.DeviceType', null, global);
44
- goog.exportSymbol('proto.Spic.AssetProto.Image', null, global);
45
- goog.exportSymbol('proto.Spic.AssetProto.Image.RetrieveReply', null, global);
46
- goog.exportSymbol('proto.Spic.AssetProto.Image.RetrieveRequest', null, global);
47
- goog.exportSymbol('proto.Spic.AssetProto.LocationSearchReply', null, global);
48
- goog.exportSymbol('proto.Spic.AssetProto.LocationSearchRequest', null, global);
49
- goog.exportSymbol('proto.Spic.AssetProto.ReplaceBatteryRequest', null, global);
50
- goog.exportSymbol('proto.Spic.AssetProto.RetrieveRequest', null, global);
51
- goog.exportSymbol('proto.Spic.AssetProto.RetrieveRequest.SearchCase', null, global);
52
- goog.exportSymbol('proto.Spic.AssetProto.SearchReply', null, global);
53
- goog.exportSymbol('proto.Spic.AssetProto.SearchRequest', null, global);
54
- goog.exportSymbol('proto.Spic.AssetProto.StateChangedEvent', null, global);
55
- goog.exportSymbol('proto.Spic.AssetProto.UpdateRequest', null, global);
56
- goog.exportSymbol('proto.Spic.AssetWithLocation', null, global);
57
- goog.exportSymbol('proto.Spic.AssetWithLocationAndDistance', null, global);
58
- goog.exportSymbol('proto.Spic.ComponentIdentifier', null, global);
59
- /**
60
- * Generated by JsPbCodeGenerator.
61
- * @param {Array=} opt_data Optional initial data array, typically from a
62
- * server response, or constructed directly in Javascript. The array is used
63
- * in place and becomes part of the constructed object. It is not cloned.
64
- * If no data is provided, the constructed object will be empty, but still
65
- * valid.
66
- * @extends {jspb.Message}
67
- * @constructor
68
- */
69
- proto.Spic.AssetProto = function(opt_data) {
70
- jspb.Message.initialize(this, opt_data, 0, -1, proto.Spic.AssetProto.repeatedFields_, null);
71
- };
72
- goog.inherits(proto.Spic.AssetProto, jspb.Message);
73
- if (goog.DEBUG && !COMPILED) {
74
- /**
75
- * @public
76
- * @override
77
- */
78
- proto.Spic.AssetProto.displayName = 'proto.Spic.AssetProto';
79
- }
80
- /**
81
- * Generated by JsPbCodeGenerator.
82
- * @param {Array=} opt_data Optional initial data array, typically from a
83
- * server response, or constructed directly in Javascript. The array is used
84
- * in place and becomes part of the constructed object. It is not cloned.
85
- * If no data is provided, the constructed object will be empty, but still
86
- * valid.
87
- * @extends {jspb.Message}
88
- * @constructor
89
- */
90
- proto.Spic.AssetProto.CreateRequest = function(opt_data) {
91
- jspb.Message.initialize(this, opt_data, 0, -1, null, null);
92
- };
93
- goog.inherits(proto.Spic.AssetProto.CreateRequest, jspb.Message);
94
- if (goog.DEBUG && !COMPILED) {
95
- /**
96
- * @public
97
- * @override
98
- */
99
- proto.Spic.AssetProto.CreateRequest.displayName = 'proto.Spic.AssetProto.CreateRequest';
100
- }
101
- /**
102
- * Generated by JsPbCodeGenerator.
103
- * @param {Array=} opt_data Optional initial data array, typically from a
104
- * server response, or constructed directly in Javascript. The array is used
105
- * in place and becomes part of the constructed object. It is not cloned.
106
- * If no data is provided, the constructed object will be empty, but still
107
- * valid.
108
- * @extends {jspb.Message}
109
- * @constructor
110
- */
111
- proto.Spic.AssetProto.RetrieveRequest = function(opt_data) {
112
- jspb.Message.initialize(this, opt_data, 0, -1, null, proto.Spic.AssetProto.RetrieveRequest.oneofGroups_);
113
- };
114
- goog.inherits(proto.Spic.AssetProto.RetrieveRequest, jspb.Message);
115
- if (goog.DEBUG && !COMPILED) {
116
- /**
117
- * @public
118
- * @override
119
- */
120
- proto.Spic.AssetProto.RetrieveRequest.displayName = 'proto.Spic.AssetProto.RetrieveRequest';
121
- }
122
- /**
123
- * Generated by JsPbCodeGenerator.
124
- * @param {Array=} opt_data Optional initial data array, typically from a
125
- * server response, or constructed directly in Javascript. The array is used
126
- * in place and becomes part of the constructed object. It is not cloned.
127
- * If no data is provided, the constructed object will be empty, but still
128
- * valid.
129
- * @extends {jspb.Message}
130
- * @constructor
131
- */
132
- proto.Spic.AssetProto.UpdateRequest = function(opt_data) {
133
- jspb.Message.initialize(this, opt_data, 0, -1, null, null);
134
- };
135
- goog.inherits(proto.Spic.AssetProto.UpdateRequest, jspb.Message);
136
- if (goog.DEBUG && !COMPILED) {
137
- /**
138
- * @public
139
- * @override
140
- */
141
- proto.Spic.AssetProto.UpdateRequest.displayName = 'proto.Spic.AssetProto.UpdateRequest';
142
- }
143
- /**
144
- * Generated by JsPbCodeGenerator.
145
- * @param {Array=} opt_data Optional initial data array, typically from a
146
- * server response, or constructed directly in Javascript. The array is used
147
- * in place and becomes part of the constructed object. It is not cloned.
148
- * If no data is provided, the constructed object will be empty, but still
149
- * valid.
150
- * @extends {jspb.Message}
151
- * @constructor
152
- */
153
- proto.Spic.AssetProto.DeleteRequest = function(opt_data) {
154
- jspb.Message.initialize(this, opt_data, 0, -1, null, proto.Spic.AssetProto.DeleteRequest.oneofGroups_);
155
- };
156
- goog.inherits(proto.Spic.AssetProto.DeleteRequest, jspb.Message);
157
- if (goog.DEBUG && !COMPILED) {
158
- /**
159
- * @public
160
- * @override
161
- */
162
- proto.Spic.AssetProto.DeleteRequest.displayName = 'proto.Spic.AssetProto.DeleteRequest';
163
- }
164
- /**
165
- * Generated by JsPbCodeGenerator.
166
- * @param {Array=} opt_data Optional initial data array, typically from a
167
- * server response, or constructed directly in Javascript. The array is used
168
- * in place and becomes part of the constructed object. It is not cloned.
169
- * If no data is provided, the constructed object will be empty, but still
170
- * valid.
171
- * @extends {jspb.Message}
172
- * @constructor
173
- */
174
- proto.Spic.AssetProto.SearchRequest = function(opt_data) {
175
- jspb.Message.initialize(this, opt_data, 0, -1, null, null);
176
- };
177
- goog.inherits(proto.Spic.AssetProto.SearchRequest, jspb.Message);
178
- if (goog.DEBUG && !COMPILED) {
179
- /**
180
- * @public
181
- * @override
182
- */
183
- proto.Spic.AssetProto.SearchRequest.displayName = 'proto.Spic.AssetProto.SearchRequest';
184
- }
185
- /**
186
- * Generated by JsPbCodeGenerator.
187
- * @param {Array=} opt_data Optional initial data array, typically from a
188
- * server response, or constructed directly in Javascript. The array is used
189
- * in place and becomes part of the constructed object. It is not cloned.
190
- * If no data is provided, the constructed object will be empty, but still
191
- * valid.
192
- * @extends {jspb.Message}
193
- * @constructor
194
- */
195
- proto.Spic.AssetProto.SearchReply = function(opt_data) {
196
- jspb.Message.initialize(this, opt_data, 0, -1, proto.Spic.AssetProto.SearchReply.repeatedFields_, null);
197
- };
198
- goog.inherits(proto.Spic.AssetProto.SearchReply, jspb.Message);
199
- if (goog.DEBUG && !COMPILED) {
200
- /**
201
- * @public
202
- * @override
203
- */
204
- proto.Spic.AssetProto.SearchReply.displayName = 'proto.Spic.AssetProto.SearchReply';
205
- }
206
- /**
207
- * Generated by JsPbCodeGenerator.
208
- * @param {Array=} opt_data Optional initial data array, typically from a
209
- * server response, or constructed directly in Javascript. The array is used
210
- * in place and becomes part of the constructed object. It is not cloned.
211
- * If no data is provided, the constructed object will be empty, but still
212
- * valid.
213
- * @extends {jspb.Message}
214
- * @constructor
215
- */
216
- proto.Spic.AssetProto.LocationSearchRequest = function(opt_data) {
217
- jspb.Message.initialize(this, opt_data, 0, -1, null, null);
218
- };
219
- goog.inherits(proto.Spic.AssetProto.LocationSearchRequest, jspb.Message);
220
- if (goog.DEBUG && !COMPILED) {
221
- /**
222
- * @public
223
- * @override
224
- */
225
- proto.Spic.AssetProto.LocationSearchRequest.displayName = 'proto.Spic.AssetProto.LocationSearchRequest';
226
- }
227
- /**
228
- * Generated by JsPbCodeGenerator.
229
- * @param {Array=} opt_data Optional initial data array, typically from a
230
- * server response, or constructed directly in Javascript. The array is used
231
- * in place and becomes part of the constructed object. It is not cloned.
232
- * If no data is provided, the constructed object will be empty, but still
233
- * valid.
234
- * @extends {jspb.Message}
235
- * @constructor
236
- */
237
- proto.Spic.AssetProto.LocationSearchReply = function(opt_data) {
238
- jspb.Message.initialize(this, opt_data, 0, -1, proto.Spic.AssetProto.LocationSearchReply.repeatedFields_, null);
239
- };
240
- goog.inherits(proto.Spic.AssetProto.LocationSearchReply, jspb.Message);
241
- if (goog.DEBUG && !COMPILED) {
242
- /**
243
- * @public
244
- * @override
245
- */
246
- proto.Spic.AssetProto.LocationSearchReply.displayName = 'proto.Spic.AssetProto.LocationSearchReply';
247
- }
248
- /**
249
- * Generated by JsPbCodeGenerator.
250
- * @param {Array=} opt_data Optional initial data array, typically from a
251
- * server response, or constructed directly in Javascript. The array is used
252
- * in place and becomes part of the constructed object. It is not cloned.
253
- * If no data is provided, the constructed object will be empty, but still
254
- * valid.
255
- * @extends {jspb.Message}
256
- * @constructor
257
- */
258
- proto.Spic.AssetProto.ReplaceBatteryRequest = function(opt_data) {
259
- jspb.Message.initialize(this, opt_data, 0, -1, null, null);
260
- };
261
- goog.inherits(proto.Spic.AssetProto.ReplaceBatteryRequest, jspb.Message);
262
- if (goog.DEBUG && !COMPILED) {
263
- /**
264
- * @public
265
- * @override
266
- */
267
- proto.Spic.AssetProto.ReplaceBatteryRequest.displayName = 'proto.Spic.AssetProto.ReplaceBatteryRequest';
268
- }
269
- /**
270
- * Generated by JsPbCodeGenerator.
271
- * @param {Array=} opt_data Optional initial data array, typically from a
272
- * server response, or constructed directly in Javascript. The array is used
273
- * in place and becomes part of the constructed object. It is not cloned.
274
- * If no data is provided, the constructed object will be empty, but still
275
- * valid.
276
- * @extends {jspb.Message}
277
- * @constructor
278
- */
279
- proto.Spic.AssetProto.Image = function(opt_data) {
280
- jspb.Message.initialize(this, opt_data, 0, -1, null, null);
281
- };
282
- goog.inherits(proto.Spic.AssetProto.Image, jspb.Message);
283
- if (goog.DEBUG && !COMPILED) {
284
- /**
285
- * @public
286
- * @override
287
- */
288
- proto.Spic.AssetProto.Image.displayName = 'proto.Spic.AssetProto.Image';
289
- }
290
- /**
291
- * Generated by JsPbCodeGenerator.
292
- * @param {Array=} opt_data Optional initial data array, typically from a
293
- * server response, or constructed directly in Javascript. The array is used
294
- * in place and becomes part of the constructed object. It is not cloned.
295
- * If no data is provided, the constructed object will be empty, but still
296
- * valid.
297
- * @extends {jspb.Message}
298
- * @constructor
299
- */
300
- proto.Spic.AssetProto.Image.RetrieveRequest = function(opt_data) {
301
- jspb.Message.initialize(this, opt_data, 0, -1, null, null);
302
- };
303
- goog.inherits(proto.Spic.AssetProto.Image.RetrieveRequest, jspb.Message);
304
- if (goog.DEBUG && !COMPILED) {
305
- /**
306
- * @public
307
- * @override
308
- */
309
- proto.Spic.AssetProto.Image.RetrieveRequest.displayName = 'proto.Spic.AssetProto.Image.RetrieveRequest';
310
- }
311
- /**
312
- * Generated by JsPbCodeGenerator.
313
- * @param {Array=} opt_data Optional initial data array, typically from a
314
- * server response, or constructed directly in Javascript. The array is used
315
- * in place and becomes part of the constructed object. It is not cloned.
316
- * If no data is provided, the constructed object will be empty, but still
317
- * valid.
318
- * @extends {jspb.Message}
319
- * @constructor
320
- */
321
- proto.Spic.AssetProto.Image.RetrieveReply = function(opt_data) {
322
- jspb.Message.initialize(this, opt_data, 0, -1, null, null);
323
- };
324
- goog.inherits(proto.Spic.AssetProto.Image.RetrieveReply, jspb.Message);
325
- if (goog.DEBUG && !COMPILED) {
326
- /**
327
- * @public
328
- * @override
329
- */
330
- proto.Spic.AssetProto.Image.RetrieveReply.displayName = 'proto.Spic.AssetProto.Image.RetrieveReply';
331
- }
332
- /**
333
- * Generated by JsPbCodeGenerator.
334
- * @param {Array=} opt_data Optional initial data array, typically from a
335
- * server response, or constructed directly in Javascript. The array is used
336
- * in place and becomes part of the constructed object. It is not cloned.
337
- * If no data is provided, the constructed object will be empty, but still
338
- * valid.
339
- * @extends {jspb.Message}
340
- * @constructor
341
- */
342
- proto.Spic.AssetProto.ComponentState = function(opt_data) {
343
- jspb.Message.initialize(this, opt_data, 0, -1, null, null);
344
- };
345
- goog.inherits(proto.Spic.AssetProto.ComponentState, jspb.Message);
346
- if (goog.DEBUG && !COMPILED) {
347
- /**
348
- * @public
349
- * @override
350
- */
351
- proto.Spic.AssetProto.ComponentState.displayName = 'proto.Spic.AssetProto.ComponentState';
352
- }
353
- /**
354
- * Generated by JsPbCodeGenerator.
355
- * @param {Array=} opt_data Optional initial data array, typically from a
356
- * server response, or constructed directly in Javascript. The array is used
357
- * in place and becomes part of the constructed object. It is not cloned.
358
- * If no data is provided, the constructed object will be empty, but still
359
- * valid.
360
- * @extends {jspb.Message}
361
- * @constructor
362
- */
363
- proto.Spic.AssetProto.StateChangedEvent = function(opt_data) {
364
- jspb.Message.initialize(this, opt_data, 0, -1, null, null);
365
- };
366
- goog.inherits(proto.Spic.AssetProto.StateChangedEvent, jspb.Message);
367
- if (goog.DEBUG && !COMPILED) {
368
- /**
369
- * @public
370
- * @override
371
- */
372
- proto.Spic.AssetProto.StateChangedEvent.displayName = 'proto.Spic.AssetProto.StateChangedEvent';
373
- }
374
- /**
375
- * Generated by JsPbCodeGenerator.
376
- * @param {Array=} opt_data Optional initial data array, typically from a
377
- * server response, or constructed directly in Javascript. The array is used
378
- * in place and becomes part of the constructed object. It is not cloned.
379
- * If no data is provided, the constructed object will be empty, but still
380
- * valid.
381
- * @extends {jspb.Message}
382
- * @constructor
383
- */
384
- proto.Spic.AssetWithLocation = function(opt_data) {
385
- jspb.Message.initialize(this, opt_data, 0, -1, null, null);
386
- };
387
- goog.inherits(proto.Spic.AssetWithLocation, jspb.Message);
388
- if (goog.DEBUG && !COMPILED) {
389
- /**
390
- * @public
391
- * @override
392
- */
393
- proto.Spic.AssetWithLocation.displayName = 'proto.Spic.AssetWithLocation';
394
- }
395
- /**
396
- * Generated by JsPbCodeGenerator.
397
- * @param {Array=} opt_data Optional initial data array, typically from a
398
- * server response, or constructed directly in Javascript. The array is used
399
- * in place and becomes part of the constructed object. It is not cloned.
400
- * If no data is provided, the constructed object will be empty, but still
401
- * valid.
402
- * @extends {jspb.Message}
403
- * @constructor
404
- */
405
- proto.Spic.AssetWithLocationAndDistance = function(opt_data) {
406
- jspb.Message.initialize(this, opt_data, 0, -1, null, null);
407
- };
408
- goog.inherits(proto.Spic.AssetWithLocationAndDistance, jspb.Message);
409
- if (goog.DEBUG && !COMPILED) {
410
- /**
411
- * @public
412
- * @override
413
- */
414
- proto.Spic.AssetWithLocationAndDistance.displayName = 'proto.Spic.AssetWithLocationAndDistance';
415
- }
416
-
417
- /**
418
- * List of repeated fields within this message type.
419
- * @private {!Array<number>}
420
- * @const
421
- */
422
- proto.Spic.AssetProto.repeatedFields_ = [19];
423
-
424
-
425
-
426
- if (jspb.Message.GENERATE_TO_OBJECT) {
427
- /**
428
- * Creates an object representation of this proto.
429
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
430
- * Optional fields that are not set will be set to undefined.
431
- * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
432
- * For the list of reserved names please see:
433
- * net/proto2/compiler/js/internal/generator.cc#kKeyword.
434
- * @param {boolean=} opt_includeInstance Deprecated. whether to include the
435
- * JSPB instance for transitional soy proto support:
436
- * http://goto/soy-param-migration
437
- * @return {!Object}
438
- */
439
- proto.Spic.AssetProto.prototype.toObject = function(opt_includeInstance) {
440
- return proto.Spic.AssetProto.toObject(opt_includeInstance, this);
441
- };
442
-
443
-
444
- /**
445
- * Static version of the {@see toObject} method.
446
- * @param {boolean|undefined} includeInstance Deprecated. Whether to include
447
- * the JSPB instance for transitional soy proto support:
448
- * http://goto/soy-param-migration
449
- * @param {!proto.Spic.AssetProto} msg The msg instance to transform.
450
- * @return {!Object}
451
- * @suppress {unusedLocalVariables} f is only used for nested messages
452
- */
453
- proto.Spic.AssetProto.toObject = function(includeInstance, msg) {
454
- var f, obj = {
455
- id: jspb.Message.getFieldWithDefault(msg, 1, 0),
456
- name: jspb.Message.getFieldWithDefault(msg, 2, ""),
457
- locationId: jspb.Message.getFieldWithDefault(msg, 3, 0),
458
- uid: jspb.Message.getFieldWithDefault(msg, 4, ""),
459
- status: jspb.Message.getFieldWithDefault(msg, 5, 0),
460
- lastStatusUpdate: (f = msg.getLastStatusUpdate()) && google_protobuf_timestamp_pb.Timestamp.toObject(includeInstance, f),
461
- groupId: jspb.Message.getFieldWithDefault(msg, 8, ""),
462
- clientId: jspb.Message.getFieldWithDefault(msg, 9, 0),
463
- isMaintenance: jspb.Message.getBooleanFieldWithDefault(msg, 10, false),
464
- imageBlob: jspb.Message.getFieldWithDefault(msg, 11, ""),
465
- batteryPlaced: (f = msg.getBatteryPlaced()) && google_protobuf_timestamp_pb.Timestamp.toObject(includeInstance, f),
466
- batteryPercentage: jspb.Message.getFieldWithDefault(msg, 13, 0),
467
- communicationTime: jspb.Message.getFieldWithDefault(msg, 14, 0),
468
- lastConfigString: jspb.Message.getFieldWithDefault(msg, 15, ""),
469
- lastConfigUpdated: (f = msg.getLastConfigUpdated()) && google_protobuf_timestamp_pb.Timestamp.toObject(includeInstance, f),
470
- assetType: jspb.Message.getFieldWithDefault(msg, 17, 0),
471
- batteryStatus: jspb.Message.getFieldWithDefault(msg, 18, 0),
472
- statesList: jspb.Message.toObjectList(msg.getStatesList(),
473
- proto.Spic.AssetProto.ComponentState.toObject, includeInstance),
474
- deviceType: jspb.Message.getFieldWithDefault(msg, 20, 0)
475
- };
476
-
477
- if (includeInstance) {
478
- obj.$jspbMessageInstance = msg;
479
- }
480
- return obj;
481
- };
482
- }
483
-
484
-
485
- /**
486
- * Deserializes binary data (in protobuf wire format).
487
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
488
- * @return {!proto.Spic.AssetProto}
489
- */
490
- proto.Spic.AssetProto.deserializeBinary = function(bytes) {
491
- var reader = new jspb.BinaryReader(bytes);
492
- var msg = new proto.Spic.AssetProto;
493
- return proto.Spic.AssetProto.deserializeBinaryFromReader(msg, reader);
494
- };
495
-
496
-
497
- /**
498
- * Deserializes binary data (in protobuf wire format) from the
499
- * given reader into the given message object.
500
- * @param {!proto.Spic.AssetProto} msg The message object to deserialize into.
501
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
502
- * @return {!proto.Spic.AssetProto}
503
- */
504
- proto.Spic.AssetProto.deserializeBinaryFromReader = function(msg, reader) {
505
- while (reader.nextField()) {
506
- if (reader.isEndGroup()) {
507
- break;
508
- }
509
- var field = reader.getFieldNumber();
510
- switch (field) {
511
- case 1:
512
- var value = /** @type {number} */ (reader.readInt64());
513
- msg.setId(value);
514
- break;
515
- case 2:
516
- var value = /** @type {string} */ (reader.readString());
517
- msg.setName(value);
518
- break;
519
- case 3:
520
- var value = /** @type {number} */ (reader.readInt64());
521
- msg.setLocationId(value);
522
- break;
523
- case 4:
524
- var value = /** @type {string} */ (reader.readString());
525
- msg.setUid(value);
526
- break;
527
- case 5:
528
- var value = /** @type {number} */ (reader.readInt32());
529
- msg.setStatus(value);
530
- break;
531
- case 7:
532
- var value = new google_protobuf_timestamp_pb.Timestamp;
533
- reader.readMessage(value,google_protobuf_timestamp_pb.Timestamp.deserializeBinaryFromReader);
534
- msg.setLastStatusUpdate(value);
535
- break;
536
- case 8:
537
- var value = /** @type {string} */ (reader.readString());
538
- msg.setGroupId(value);
539
- break;
540
- case 9:
541
- var value = /** @type {number} */ (reader.readInt32());
542
- msg.setClientId(value);
543
- break;
544
- case 10:
545
- var value = /** @type {boolean} */ (reader.readBool());
546
- msg.setIsMaintenance(value);
547
- break;
548
- case 11:
549
- var value = /** @type {string} */ (reader.readString());
550
- msg.setImageBlob(value);
551
- break;
552
- case 12:
553
- var value = new google_protobuf_timestamp_pb.Timestamp;
554
- reader.readMessage(value,google_protobuf_timestamp_pb.Timestamp.deserializeBinaryFromReader);
555
- msg.setBatteryPlaced(value);
556
- break;
557
- case 13:
558
- var value = /** @type {number} */ (reader.readInt32());
559
- msg.setBatteryPercentage(value);
560
- break;
561
- case 14:
562
- var value = /** @type {number} */ (reader.readInt64());
563
- msg.setCommunicationTime(value);
564
- break;
565
- case 15:
566
- var value = /** @type {string} */ (reader.readString());
567
- msg.setLastConfigString(value);
568
- break;
569
- case 16:
570
- var value = new google_protobuf_timestamp_pb.Timestamp;
571
- reader.readMessage(value,google_protobuf_timestamp_pb.Timestamp.deserializeBinaryFromReader);
572
- msg.setLastConfigUpdated(value);
573
- break;
574
- case 17:
575
- var value = /** @type {!proto.Spic.AssetProto.AssetType} */ (reader.readEnum());
576
- msg.setAssetType(value);
577
- break;
578
- case 18:
579
- var value = /** @type {!proto.Spic.AssetProto.BatteryStatus} */ (reader.readEnum());
580
- msg.setBatteryStatus(value);
581
- break;
582
- case 19:
583
- var value = new proto.Spic.AssetProto.ComponentState;
584
- reader.readMessage(value,proto.Spic.AssetProto.ComponentState.deserializeBinaryFromReader);
585
- msg.addStates(value);
586
- break;
587
- case 20:
588
- var value = /** @type {!proto.Spic.AssetProto.DeviceType} */ (reader.readEnum());
589
- msg.setDeviceType(value);
590
- break;
591
- default:
592
- reader.skipField();
593
- break;
594
- }
595
- }
596
- return msg;
597
- };
598
-
599
-
600
- /**
601
- * Serializes the message to binary data (in protobuf wire format).
602
- * @return {!Uint8Array}
603
- */
604
- proto.Spic.AssetProto.prototype.serializeBinary = function() {
605
- var writer = new jspb.BinaryWriter();
606
- proto.Spic.AssetProto.serializeBinaryToWriter(this, writer);
607
- return writer.getResultBuffer();
608
- };
609
-
610
-
611
- /**
612
- * Serializes the given message to binary data (in protobuf wire
613
- * format), writing to the given BinaryWriter.
614
- * @param {!proto.Spic.AssetProto} message
615
- * @param {!jspb.BinaryWriter} writer
616
- * @suppress {unusedLocalVariables} f is only used for nested messages
617
- */
618
- proto.Spic.AssetProto.serializeBinaryToWriter = function(message, writer) {
619
- var f = undefined;
620
- f = message.getId();
621
- if (f !== 0) {
622
- writer.writeInt64(
623
- 1,
624
- f
625
- );
626
- }
627
- f = message.getName();
628
- if (f.length > 0) {
629
- writer.writeString(
630
- 2,
631
- f
632
- );
633
- }
634
- f = message.getLocationId();
635
- if (f !== 0) {
636
- writer.writeInt64(
637
- 3,
638
- f
639
- );
640
- }
641
- f = message.getUid();
642
- if (f.length > 0) {
643
- writer.writeString(
644
- 4,
645
- f
646
- );
647
- }
648
- f = message.getStatus();
649
- if (f !== 0) {
650
- writer.writeInt32(
651
- 5,
652
- f
653
- );
654
- }
655
- f = message.getLastStatusUpdate();
656
- if (f != null) {
657
- writer.writeMessage(
658
- 7,
659
- f,
660
- google_protobuf_timestamp_pb.Timestamp.serializeBinaryToWriter
661
- );
662
- }
663
- f = message.getGroupId();
664
- if (f.length > 0) {
665
- writer.writeString(
666
- 8,
667
- f
668
- );
669
- }
670
- f = message.getClientId();
671
- if (f !== 0) {
672
- writer.writeInt32(
673
- 9,
674
- f
675
- );
676
- }
677
- f = message.getIsMaintenance();
678
- if (f) {
679
- writer.writeBool(
680
- 10,
681
- f
682
- );
683
- }
684
- f = message.getImageBlob();
685
- if (f.length > 0) {
686
- writer.writeString(
687
- 11,
688
- f
689
- );
690
- }
691
- f = message.getBatteryPlaced();
692
- if (f != null) {
693
- writer.writeMessage(
694
- 12,
695
- f,
696
- google_protobuf_timestamp_pb.Timestamp.serializeBinaryToWriter
697
- );
698
- }
699
- f = message.getBatteryPercentage();
700
- if (f !== 0) {
701
- writer.writeInt32(
702
- 13,
703
- f
704
- );
705
- }
706
- f = message.getCommunicationTime();
707
- if (f !== 0) {
708
- writer.writeInt64(
709
- 14,
710
- f
711
- );
712
- }
713
- f = message.getLastConfigString();
714
- if (f.length > 0) {
715
- writer.writeString(
716
- 15,
717
- f
718
- );
719
- }
720
- f = message.getLastConfigUpdated();
721
- if (f != null) {
722
- writer.writeMessage(
723
- 16,
724
- f,
725
- google_protobuf_timestamp_pb.Timestamp.serializeBinaryToWriter
726
- );
727
- }
728
- f = message.getAssetType();
729
- if (f !== 0.0) {
730
- writer.writeEnum(
731
- 17,
732
- f
733
- );
734
- }
735
- f = message.getBatteryStatus();
736
- if (f !== 0.0) {
737
- writer.writeEnum(
738
- 18,
739
- f
740
- );
741
- }
742
- f = message.getStatesList();
743
- if (f.length > 0) {
744
- writer.writeRepeatedMessage(
745
- 19,
746
- f,
747
- proto.Spic.AssetProto.ComponentState.serializeBinaryToWriter
748
- );
749
- }
750
- f = message.getDeviceType();
751
- if (f !== 0.0) {
752
- writer.writeEnum(
753
- 20,
754
- f
755
- );
756
- }
757
- };
758
-
759
-
760
- /**
761
- * @enum {number}
762
- */
763
- proto.Spic.AssetProto.BatteryStatus = {
764
- UNKOWWN: 0,
765
- OK: 1,
766
- REPLACE_WARNING: 2,
767
- CRITICAL: 3
768
- };
769
-
770
- /**
771
- * @enum {number}
772
- */
773
- proto.Spic.AssetProto.DeviceType = {
774
- SPICV2_MANHOLE: 0,
775
- SPICV2_PASSIVE_CABINET: 1
776
- };
777
-
778
- /**
779
- * @enum {number}
780
- */
781
- proto.Spic.AssetProto.AssetType = {
782
- CABINET: 0,
783
- MANHOLE: 1,
784
- CLOSURE: 2
785
- };
786
-
787
-
788
-
789
-
790
- if (jspb.Message.GENERATE_TO_OBJECT) {
791
- /**
792
- * Creates an object representation of this proto.
793
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
794
- * Optional fields that are not set will be set to undefined.
795
- * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
796
- * For the list of reserved names please see:
797
- * net/proto2/compiler/js/internal/generator.cc#kKeyword.
798
- * @param {boolean=} opt_includeInstance Deprecated. whether to include the
799
- * JSPB instance for transitional soy proto support:
800
- * http://goto/soy-param-migration
801
- * @return {!Object}
802
- */
803
- proto.Spic.AssetProto.CreateRequest.prototype.toObject = function(opt_includeInstance) {
804
- return proto.Spic.AssetProto.CreateRequest.toObject(opt_includeInstance, this);
805
- };
806
-
807
-
808
- /**
809
- * Static version of the {@see toObject} method.
810
- * @param {boolean|undefined} includeInstance Deprecated. Whether to include
811
- * the JSPB instance for transitional soy proto support:
812
- * http://goto/soy-param-migration
813
- * @param {!proto.Spic.AssetProto.CreateRequest} msg The msg instance to transform.
814
- * @return {!Object}
815
- * @suppress {unusedLocalVariables} f is only used for nested messages
816
- */
817
- proto.Spic.AssetProto.CreateRequest.toObject = function(includeInstance, msg) {
818
- var f, obj = {
819
- name: jspb.Message.getFieldWithDefault(msg, 1, ""),
820
- locationId: jspb.Message.getFieldWithDefault(msg, 2, 0),
821
- uid: jspb.Message.getFieldWithDefault(msg, 3, ""),
822
- image: (f = msg.getImage()) && google_protobuf_wrappers_pb.BytesValue.toObject(includeInstance, f),
823
- groupId: jspb.Message.getFieldWithDefault(msg, 5, ""),
824
- clientId: jspb.Message.getFieldWithDefault(msg, 6, 0),
825
- assetType: jspb.Message.getFieldWithDefault(msg, 7, 0)
826
- };
827
-
828
- if (includeInstance) {
829
- obj.$jspbMessageInstance = msg;
830
- }
831
- return obj;
832
- };
833
- }
834
-
835
-
836
- /**
837
- * Deserializes binary data (in protobuf wire format).
838
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
839
- * @return {!proto.Spic.AssetProto.CreateRequest}
840
- */
841
- proto.Spic.AssetProto.CreateRequest.deserializeBinary = function(bytes) {
842
- var reader = new jspb.BinaryReader(bytes);
843
- var msg = new proto.Spic.AssetProto.CreateRequest;
844
- return proto.Spic.AssetProto.CreateRequest.deserializeBinaryFromReader(msg, reader);
845
- };
846
-
847
-
848
- /**
849
- * Deserializes binary data (in protobuf wire format) from the
850
- * given reader into the given message object.
851
- * @param {!proto.Spic.AssetProto.CreateRequest} msg The message object to deserialize into.
852
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
853
- * @return {!proto.Spic.AssetProto.CreateRequest}
854
- */
855
- proto.Spic.AssetProto.CreateRequest.deserializeBinaryFromReader = function(msg, reader) {
856
- while (reader.nextField()) {
857
- if (reader.isEndGroup()) {
858
- break;
859
- }
860
- var field = reader.getFieldNumber();
861
- switch (field) {
862
- case 1:
863
- var value = /** @type {string} */ (reader.readString());
864
- msg.setName(value);
865
- break;
866
- case 2:
867
- var value = /** @type {number} */ (reader.readInt64());
868
- msg.setLocationId(value);
869
- break;
870
- case 3:
871
- var value = /** @type {string} */ (reader.readString());
872
- msg.setUid(value);
873
- break;
874
- case 4:
875
- var value = new google_protobuf_wrappers_pb.BytesValue;
876
- reader.readMessage(value,google_protobuf_wrappers_pb.BytesValue.deserializeBinaryFromReader);
877
- msg.setImage(value);
878
- break;
879
- case 5:
880
- var value = /** @type {string} */ (reader.readString());
881
- msg.setGroupId(value);
882
- break;
883
- case 6:
884
- var value = /** @type {number} */ (reader.readInt32());
885
- msg.setClientId(value);
886
- break;
887
- case 7:
888
- var value = /** @type {!proto.Spic.AssetProto.AssetType} */ (reader.readEnum());
889
- msg.setAssetType(value);
890
- break;
891
- default:
892
- reader.skipField();
893
- break;
894
- }
895
- }
896
- return msg;
897
- };
898
-
899
-
900
- /**
901
- * Serializes the message to binary data (in protobuf wire format).
902
- * @return {!Uint8Array}
903
- */
904
- proto.Spic.AssetProto.CreateRequest.prototype.serializeBinary = function() {
905
- var writer = new jspb.BinaryWriter();
906
- proto.Spic.AssetProto.CreateRequest.serializeBinaryToWriter(this, writer);
907
- return writer.getResultBuffer();
908
- };
909
-
910
-
911
- /**
912
- * Serializes the given message to binary data (in protobuf wire
913
- * format), writing to the given BinaryWriter.
914
- * @param {!proto.Spic.AssetProto.CreateRequest} message
915
- * @param {!jspb.BinaryWriter} writer
916
- * @suppress {unusedLocalVariables} f is only used for nested messages
917
- */
918
- proto.Spic.AssetProto.CreateRequest.serializeBinaryToWriter = function(message, writer) {
919
- var f = undefined;
920
- f = message.getName();
921
- if (f.length > 0) {
922
- writer.writeString(
923
- 1,
924
- f
925
- );
926
- }
927
- f = message.getLocationId();
928
- if (f !== 0) {
929
- writer.writeInt64(
930
- 2,
931
- f
932
- );
933
- }
934
- f = message.getUid();
935
- if (f.length > 0) {
936
- writer.writeString(
937
- 3,
938
- f
939
- );
940
- }
941
- f = message.getImage();
942
- if (f != null) {
943
- writer.writeMessage(
944
- 4,
945
- f,
946
- google_protobuf_wrappers_pb.BytesValue.serializeBinaryToWriter
947
- );
948
- }
949
- f = message.getGroupId();
950
- if (f.length > 0) {
951
- writer.writeString(
952
- 5,
953
- f
954
- );
955
- }
956
- f = message.getClientId();
957
- if (f !== 0) {
958
- writer.writeInt32(
959
- 6,
960
- f
961
- );
962
- }
963
- f = message.getAssetType();
964
- if (f !== 0.0) {
965
- writer.writeEnum(
966
- 7,
967
- f
968
- );
969
- }
970
- };
971
-
972
-
973
- /**
974
- * optional string name = 1;
975
- * @return {string}
976
- */
977
- proto.Spic.AssetProto.CreateRequest.prototype.getName = function() {
978
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
979
- };
980
-
981
-
982
- /**
983
- * @param {string} value
984
- * @return {!proto.Spic.AssetProto.CreateRequest} returns this
985
- */
986
- proto.Spic.AssetProto.CreateRequest.prototype.setName = function(value) {
987
- return jspb.Message.setProto3StringField(this, 1, value);
988
- };
989
-
990
-
991
- /**
992
- * optional int64 location_id = 2;
993
- * @return {number}
994
- */
995
- proto.Spic.AssetProto.CreateRequest.prototype.getLocationId = function() {
996
- return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 2, 0));
997
- };
998
-
999
-
1000
- /**
1001
- * @param {number} value
1002
- * @return {!proto.Spic.AssetProto.CreateRequest} returns this
1003
- */
1004
- proto.Spic.AssetProto.CreateRequest.prototype.setLocationId = function(value) {
1005
- return jspb.Message.setProto3IntField(this, 2, value);
1006
- };
1007
-
1008
-
1009
- /**
1010
- * optional string uid = 3;
1011
- * @return {string}
1012
- */
1013
- proto.Spic.AssetProto.CreateRequest.prototype.getUid = function() {
1014
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
1015
- };
1016
-
1017
-
1018
- /**
1019
- * @param {string} value
1020
- * @return {!proto.Spic.AssetProto.CreateRequest} returns this
1021
- */
1022
- proto.Spic.AssetProto.CreateRequest.prototype.setUid = function(value) {
1023
- return jspb.Message.setProto3StringField(this, 3, value);
1024
- };
1025
-
1026
-
1027
- /**
1028
- * optional google.protobuf.BytesValue image = 4;
1029
- * @return {?proto.google.protobuf.BytesValue}
1030
- */
1031
- proto.Spic.AssetProto.CreateRequest.prototype.getImage = function() {
1032
- return /** @type{?proto.google.protobuf.BytesValue} */ (
1033
- jspb.Message.getWrapperField(this, google_protobuf_wrappers_pb.BytesValue, 4));
1034
- };
1035
-
1036
-
1037
- /**
1038
- * @param {?proto.google.protobuf.BytesValue|undefined} value
1039
- * @return {!proto.Spic.AssetProto.CreateRequest} returns this
1040
- */
1041
- proto.Spic.AssetProto.CreateRequest.prototype.setImage = function(value) {
1042
- return jspb.Message.setWrapperField(this, 4, value);
1043
- };
1044
-
1045
-
1046
- /**
1047
- * Clears the message field making it undefined.
1048
- * @return {!proto.Spic.AssetProto.CreateRequest} returns this
1049
- */
1050
- proto.Spic.AssetProto.CreateRequest.prototype.clearImage = function() {
1051
- return this.setImage(undefined);
1052
- };
1053
-
1054
-
1055
- /**
1056
- * Returns whether this field is set.
1057
- * @return {boolean}
1058
- */
1059
- proto.Spic.AssetProto.CreateRequest.prototype.hasImage = function() {
1060
- return jspb.Message.getField(this, 4) != null;
1061
- };
1062
-
1063
-
1064
- /**
1065
- * optional string group_id = 5;
1066
- * @return {string}
1067
- */
1068
- proto.Spic.AssetProto.CreateRequest.prototype.getGroupId = function() {
1069
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 5, ""));
1070
- };
1071
-
1072
-
1073
- /**
1074
- * @param {string} value
1075
- * @return {!proto.Spic.AssetProto.CreateRequest} returns this
1076
- */
1077
- proto.Spic.AssetProto.CreateRequest.prototype.setGroupId = function(value) {
1078
- return jspb.Message.setProto3StringField(this, 5, value);
1079
- };
1080
-
1081
-
1082
- /**
1083
- * optional int32 client_id = 6;
1084
- * @return {number}
1085
- */
1086
- proto.Spic.AssetProto.CreateRequest.prototype.getClientId = function() {
1087
- return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 6, 0));
1088
- };
1089
-
1090
-
1091
- /**
1092
- * @param {number} value
1093
- * @return {!proto.Spic.AssetProto.CreateRequest} returns this
1094
- */
1095
- proto.Spic.AssetProto.CreateRequest.prototype.setClientId = function(value) {
1096
- return jspb.Message.setProto3IntField(this, 6, value);
1097
- };
1098
-
1099
-
1100
- /**
1101
- * optional AssetType asset_type = 7;
1102
- * @return {!proto.Spic.AssetProto.AssetType}
1103
- */
1104
- proto.Spic.AssetProto.CreateRequest.prototype.getAssetType = function() {
1105
- return /** @type {!proto.Spic.AssetProto.AssetType} */ (jspb.Message.getFieldWithDefault(this, 7, 0));
1106
- };
1107
-
1108
-
1109
- /**
1110
- * @param {!proto.Spic.AssetProto.AssetType} value
1111
- * @return {!proto.Spic.AssetProto.CreateRequest} returns this
1112
- */
1113
- proto.Spic.AssetProto.CreateRequest.prototype.setAssetType = function(value) {
1114
- return jspb.Message.setProto3EnumField(this, 7, value);
1115
- };
1116
-
1117
-
1118
-
1119
- /**
1120
- * Oneof group definitions for this message. Each group defines the field
1121
- * numbers belonging to that group. When of these fields' value is set, all
1122
- * other fields in the group are cleared. During deserialization, if multiple
1123
- * fields are encountered for a group, only the last value seen will be kept.
1124
- * @private {!Array<!Array<number>>}
1125
- * @const
1126
- */
1127
- proto.Spic.AssetProto.RetrieveRequest.oneofGroups_ = [[1,2]];
1128
-
1129
- /**
1130
- * @enum {number}
1131
- */
1132
- proto.Spic.AssetProto.RetrieveRequest.SearchCase = {
1133
- SEARCH_NOT_SET: 0,
1134
- ID: 1,
1135
- UID: 2
1136
- };
1137
-
1138
- /**
1139
- * @return {proto.Spic.AssetProto.RetrieveRequest.SearchCase}
1140
- */
1141
- proto.Spic.AssetProto.RetrieveRequest.prototype.getSearchCase = function() {
1142
- return /** @type {proto.Spic.AssetProto.RetrieveRequest.SearchCase} */(jspb.Message.computeOneofCase(this, proto.Spic.AssetProto.RetrieveRequest.oneofGroups_[0]));
1143
- };
1144
-
1145
-
1146
-
1147
- if (jspb.Message.GENERATE_TO_OBJECT) {
1148
- /**
1149
- * Creates an object representation of this proto.
1150
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
1151
- * Optional fields that are not set will be set to undefined.
1152
- * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
1153
- * For the list of reserved names please see:
1154
- * net/proto2/compiler/js/internal/generator.cc#kKeyword.
1155
- * @param {boolean=} opt_includeInstance Deprecated. whether to include the
1156
- * JSPB instance for transitional soy proto support:
1157
- * http://goto/soy-param-migration
1158
- * @return {!Object}
1159
- */
1160
- proto.Spic.AssetProto.RetrieveRequest.prototype.toObject = function(opt_includeInstance) {
1161
- return proto.Spic.AssetProto.RetrieveRequest.toObject(opt_includeInstance, this);
1162
- };
1163
-
1164
-
1165
- /**
1166
- * Static version of the {@see toObject} method.
1167
- * @param {boolean|undefined} includeInstance Deprecated. Whether to include
1168
- * the JSPB instance for transitional soy proto support:
1169
- * http://goto/soy-param-migration
1170
- * @param {!proto.Spic.AssetProto.RetrieveRequest} msg The msg instance to transform.
1171
- * @return {!Object}
1172
- * @suppress {unusedLocalVariables} f is only used for nested messages
1173
- */
1174
- proto.Spic.AssetProto.RetrieveRequest.toObject = function(includeInstance, msg) {
1175
- var f, obj = {
1176
- id: jspb.Message.getFieldWithDefault(msg, 1, 0),
1177
- uid: jspb.Message.getFieldWithDefault(msg, 2, "")
1178
- };
1179
-
1180
- if (includeInstance) {
1181
- obj.$jspbMessageInstance = msg;
1182
- }
1183
- return obj;
1184
- };
1185
- }
1186
-
1187
-
1188
- /**
1189
- * Deserializes binary data (in protobuf wire format).
1190
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
1191
- * @return {!proto.Spic.AssetProto.RetrieveRequest}
1192
- */
1193
- proto.Spic.AssetProto.RetrieveRequest.deserializeBinary = function(bytes) {
1194
- var reader = new jspb.BinaryReader(bytes);
1195
- var msg = new proto.Spic.AssetProto.RetrieveRequest;
1196
- return proto.Spic.AssetProto.RetrieveRequest.deserializeBinaryFromReader(msg, reader);
1197
- };
1198
-
1199
-
1200
- /**
1201
- * Deserializes binary data (in protobuf wire format) from the
1202
- * given reader into the given message object.
1203
- * @param {!proto.Spic.AssetProto.RetrieveRequest} msg The message object to deserialize into.
1204
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
1205
- * @return {!proto.Spic.AssetProto.RetrieveRequest}
1206
- */
1207
- proto.Spic.AssetProto.RetrieveRequest.deserializeBinaryFromReader = function(msg, reader) {
1208
- while (reader.nextField()) {
1209
- if (reader.isEndGroup()) {
1210
- break;
1211
- }
1212
- var field = reader.getFieldNumber();
1213
- switch (field) {
1214
- case 1:
1215
- var value = /** @type {number} */ (reader.readInt64());
1216
- msg.setId(value);
1217
- break;
1218
- case 2:
1219
- var value = /** @type {string} */ (reader.readString());
1220
- msg.setUid(value);
1221
- break;
1222
- default:
1223
- reader.skipField();
1224
- break;
1225
- }
1226
- }
1227
- return msg;
1228
- };
1229
-
1230
-
1231
- /**
1232
- * Serializes the message to binary data (in protobuf wire format).
1233
- * @return {!Uint8Array}
1234
- */
1235
- proto.Spic.AssetProto.RetrieveRequest.prototype.serializeBinary = function() {
1236
- var writer = new jspb.BinaryWriter();
1237
- proto.Spic.AssetProto.RetrieveRequest.serializeBinaryToWriter(this, writer);
1238
- return writer.getResultBuffer();
1239
- };
1240
-
1241
-
1242
- /**
1243
- * Serializes the given message to binary data (in protobuf wire
1244
- * format), writing to the given BinaryWriter.
1245
- * @param {!proto.Spic.AssetProto.RetrieveRequest} message
1246
- * @param {!jspb.BinaryWriter} writer
1247
- * @suppress {unusedLocalVariables} f is only used for nested messages
1248
- */
1249
- proto.Spic.AssetProto.RetrieveRequest.serializeBinaryToWriter = function(message, writer) {
1250
- var f = undefined;
1251
- f = /** @type {number} */ (jspb.Message.getField(message, 1));
1252
- if (f != null) {
1253
- writer.writeInt64(
1254
- 1,
1255
- f
1256
- );
1257
- }
1258
- f = /** @type {string} */ (jspb.Message.getField(message, 2));
1259
- if (f != null) {
1260
- writer.writeString(
1261
- 2,
1262
- f
1263
- );
1264
- }
1265
- };
1266
-
1267
-
1268
- /**
1269
- * optional int64 id = 1;
1270
- * @return {number}
1271
- */
1272
- proto.Spic.AssetProto.RetrieveRequest.prototype.getId = function() {
1273
- return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 1, 0));
1274
- };
1275
-
1276
-
1277
- /**
1278
- * @param {number} value
1279
- * @return {!proto.Spic.AssetProto.RetrieveRequest} returns this
1280
- */
1281
- proto.Spic.AssetProto.RetrieveRequest.prototype.setId = function(value) {
1282
- return jspb.Message.setOneofField(this, 1, proto.Spic.AssetProto.RetrieveRequest.oneofGroups_[0], value);
1283
- };
1284
-
1285
-
1286
- /**
1287
- * Clears the field making it undefined.
1288
- * @return {!proto.Spic.AssetProto.RetrieveRequest} returns this
1289
- */
1290
- proto.Spic.AssetProto.RetrieveRequest.prototype.clearId = function() {
1291
- return jspb.Message.setOneofField(this, 1, proto.Spic.AssetProto.RetrieveRequest.oneofGroups_[0], undefined);
1292
- };
1293
-
1294
-
1295
- /**
1296
- * Returns whether this field is set.
1297
- * @return {boolean}
1298
- */
1299
- proto.Spic.AssetProto.RetrieveRequest.prototype.hasId = function() {
1300
- return jspb.Message.getField(this, 1) != null;
1301
- };
1302
-
1303
-
1304
- /**
1305
- * optional string uid = 2;
1306
- * @return {string}
1307
- */
1308
- proto.Spic.AssetProto.RetrieveRequest.prototype.getUid = function() {
1309
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
1310
- };
1311
-
1312
-
1313
- /**
1314
- * @param {string} value
1315
- * @return {!proto.Spic.AssetProto.RetrieveRequest} returns this
1316
- */
1317
- proto.Spic.AssetProto.RetrieveRequest.prototype.setUid = function(value) {
1318
- return jspb.Message.setOneofField(this, 2, proto.Spic.AssetProto.RetrieveRequest.oneofGroups_[0], value);
1319
- };
1320
-
1321
-
1322
- /**
1323
- * Clears the field making it undefined.
1324
- * @return {!proto.Spic.AssetProto.RetrieveRequest} returns this
1325
- */
1326
- proto.Spic.AssetProto.RetrieveRequest.prototype.clearUid = function() {
1327
- return jspb.Message.setOneofField(this, 2, proto.Spic.AssetProto.RetrieveRequest.oneofGroups_[0], undefined);
1328
- };
1329
-
1330
-
1331
- /**
1332
- * Returns whether this field is set.
1333
- * @return {boolean}
1334
- */
1335
- proto.Spic.AssetProto.RetrieveRequest.prototype.hasUid = function() {
1336
- return jspb.Message.getField(this, 2) != null;
1337
- };
1338
-
1339
-
1340
-
1341
-
1342
-
1343
- if (jspb.Message.GENERATE_TO_OBJECT) {
1344
- /**
1345
- * Creates an object representation of this proto.
1346
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
1347
- * Optional fields that are not set will be set to undefined.
1348
- * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
1349
- * For the list of reserved names please see:
1350
- * net/proto2/compiler/js/internal/generator.cc#kKeyword.
1351
- * @param {boolean=} opt_includeInstance Deprecated. whether to include the
1352
- * JSPB instance for transitional soy proto support:
1353
- * http://goto/soy-param-migration
1354
- * @return {!Object}
1355
- */
1356
- proto.Spic.AssetProto.UpdateRequest.prototype.toObject = function(opt_includeInstance) {
1357
- return proto.Spic.AssetProto.UpdateRequest.toObject(opt_includeInstance, this);
1358
- };
1359
-
1360
-
1361
- /**
1362
- * Static version of the {@see toObject} method.
1363
- * @param {boolean|undefined} includeInstance Deprecated. Whether to include
1364
- * the JSPB instance for transitional soy proto support:
1365
- * http://goto/soy-param-migration
1366
- * @param {!proto.Spic.AssetProto.UpdateRequest} msg The msg instance to transform.
1367
- * @return {!Object}
1368
- * @suppress {unusedLocalVariables} f is only used for nested messages
1369
- */
1370
- proto.Spic.AssetProto.UpdateRequest.toObject = function(includeInstance, msg) {
1371
- var f, obj = {
1372
- id: jspb.Message.getFieldWithDefault(msg, 1, 0),
1373
- name: jspb.Message.getFieldWithDefault(msg, 2, ""),
1374
- locationId: jspb.Message.getFieldWithDefault(msg, 3, 0),
1375
- uid: jspb.Message.getFieldWithDefault(msg, 4, ""),
1376
- image: (f = msg.getImage()) && google_protobuf_wrappers_pb.BytesValue.toObject(includeInstance, f),
1377
- groupId: jspb.Message.getFieldWithDefault(msg, 6, ""),
1378
- clientId: jspb.Message.getFieldWithDefault(msg, 7, 0),
1379
- assetType: jspb.Message.getFieldWithDefault(msg, 8, 0)
1380
- };
1381
-
1382
- if (includeInstance) {
1383
- obj.$jspbMessageInstance = msg;
1384
- }
1385
- return obj;
1386
- };
1387
- }
1388
-
1389
-
1390
- /**
1391
- * Deserializes binary data (in protobuf wire format).
1392
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
1393
- * @return {!proto.Spic.AssetProto.UpdateRequest}
1394
- */
1395
- proto.Spic.AssetProto.UpdateRequest.deserializeBinary = function(bytes) {
1396
- var reader = new jspb.BinaryReader(bytes);
1397
- var msg = new proto.Spic.AssetProto.UpdateRequest;
1398
- return proto.Spic.AssetProto.UpdateRequest.deserializeBinaryFromReader(msg, reader);
1399
- };
1400
-
1401
-
1402
- /**
1403
- * Deserializes binary data (in protobuf wire format) from the
1404
- * given reader into the given message object.
1405
- * @param {!proto.Spic.AssetProto.UpdateRequest} msg The message object to deserialize into.
1406
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
1407
- * @return {!proto.Spic.AssetProto.UpdateRequest}
1408
- */
1409
- proto.Spic.AssetProto.UpdateRequest.deserializeBinaryFromReader = function(msg, reader) {
1410
- while (reader.nextField()) {
1411
- if (reader.isEndGroup()) {
1412
- break;
1413
- }
1414
- var field = reader.getFieldNumber();
1415
- switch (field) {
1416
- case 1:
1417
- var value = /** @type {number} */ (reader.readInt64());
1418
- msg.setId(value);
1419
- break;
1420
- case 2:
1421
- var value = /** @type {string} */ (reader.readString());
1422
- msg.setName(value);
1423
- break;
1424
- case 3:
1425
- var value = /** @type {number} */ (reader.readInt64());
1426
- msg.setLocationId(value);
1427
- break;
1428
- case 4:
1429
- var value = /** @type {string} */ (reader.readString());
1430
- msg.setUid(value);
1431
- break;
1432
- case 5:
1433
- var value = new google_protobuf_wrappers_pb.BytesValue;
1434
- reader.readMessage(value,google_protobuf_wrappers_pb.BytesValue.deserializeBinaryFromReader);
1435
- msg.setImage(value);
1436
- break;
1437
- case 6:
1438
- var value = /** @type {string} */ (reader.readString());
1439
- msg.setGroupId(value);
1440
- break;
1441
- case 7:
1442
- var value = /** @type {number} */ (reader.readInt32());
1443
- msg.setClientId(value);
1444
- break;
1445
- case 8:
1446
- var value = /** @type {!proto.Spic.AssetProto.AssetType} */ (reader.readEnum());
1447
- msg.setAssetType(value);
1448
- break;
1449
- default:
1450
- reader.skipField();
1451
- break;
1452
- }
1453
- }
1454
- return msg;
1455
- };
1456
-
1457
-
1458
- /**
1459
- * Serializes the message to binary data (in protobuf wire format).
1460
- * @return {!Uint8Array}
1461
- */
1462
- proto.Spic.AssetProto.UpdateRequest.prototype.serializeBinary = function() {
1463
- var writer = new jspb.BinaryWriter();
1464
- proto.Spic.AssetProto.UpdateRequest.serializeBinaryToWriter(this, writer);
1465
- return writer.getResultBuffer();
1466
- };
1467
-
1468
-
1469
- /**
1470
- * Serializes the given message to binary data (in protobuf wire
1471
- * format), writing to the given BinaryWriter.
1472
- * @param {!proto.Spic.AssetProto.UpdateRequest} message
1473
- * @param {!jspb.BinaryWriter} writer
1474
- * @suppress {unusedLocalVariables} f is only used for nested messages
1475
- */
1476
- proto.Spic.AssetProto.UpdateRequest.serializeBinaryToWriter = function(message, writer) {
1477
- var f = undefined;
1478
- f = message.getId();
1479
- if (f !== 0) {
1480
- writer.writeInt64(
1481
- 1,
1482
- f
1483
- );
1484
- }
1485
- f = message.getName();
1486
- if (f.length > 0) {
1487
- writer.writeString(
1488
- 2,
1489
- f
1490
- );
1491
- }
1492
- f = message.getLocationId();
1493
- if (f !== 0) {
1494
- writer.writeInt64(
1495
- 3,
1496
- f
1497
- );
1498
- }
1499
- f = message.getUid();
1500
- if (f.length > 0) {
1501
- writer.writeString(
1502
- 4,
1503
- f
1504
- );
1505
- }
1506
- f = message.getImage();
1507
- if (f != null) {
1508
- writer.writeMessage(
1509
- 5,
1510
- f,
1511
- google_protobuf_wrappers_pb.BytesValue.serializeBinaryToWriter
1512
- );
1513
- }
1514
- f = message.getGroupId();
1515
- if (f.length > 0) {
1516
- writer.writeString(
1517
- 6,
1518
- f
1519
- );
1520
- }
1521
- f = message.getClientId();
1522
- if (f !== 0) {
1523
- writer.writeInt32(
1524
- 7,
1525
- f
1526
- );
1527
- }
1528
- f = message.getAssetType();
1529
- if (f !== 0.0) {
1530
- writer.writeEnum(
1531
- 8,
1532
- f
1533
- );
1534
- }
1535
- };
1536
-
1537
-
1538
- /**
1539
- * optional int64 id = 1;
1540
- * @return {number}
1541
- */
1542
- proto.Spic.AssetProto.UpdateRequest.prototype.getId = function() {
1543
- return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 1, 0));
1544
- };
1545
-
1546
-
1547
- /**
1548
- * @param {number} value
1549
- * @return {!proto.Spic.AssetProto.UpdateRequest} returns this
1550
- */
1551
- proto.Spic.AssetProto.UpdateRequest.prototype.setId = function(value) {
1552
- return jspb.Message.setProto3IntField(this, 1, value);
1553
- };
1554
-
1555
-
1556
- /**
1557
- * optional string name = 2;
1558
- * @return {string}
1559
- */
1560
- proto.Spic.AssetProto.UpdateRequest.prototype.getName = function() {
1561
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
1562
- };
1563
-
1564
-
1565
- /**
1566
- * @param {string} value
1567
- * @return {!proto.Spic.AssetProto.UpdateRequest} returns this
1568
- */
1569
- proto.Spic.AssetProto.UpdateRequest.prototype.setName = function(value) {
1570
- return jspb.Message.setProto3StringField(this, 2, value);
1571
- };
1572
-
1573
-
1574
- /**
1575
- * optional int64 location_id = 3;
1576
- * @return {number}
1577
- */
1578
- proto.Spic.AssetProto.UpdateRequest.prototype.getLocationId = function() {
1579
- return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 3, 0));
1580
- };
1581
-
1582
-
1583
- /**
1584
- * @param {number} value
1585
- * @return {!proto.Spic.AssetProto.UpdateRequest} returns this
1586
- */
1587
- proto.Spic.AssetProto.UpdateRequest.prototype.setLocationId = function(value) {
1588
- return jspb.Message.setProto3IntField(this, 3, value);
1589
- };
1590
-
1591
-
1592
- /**
1593
- * optional string uid = 4;
1594
- * @return {string}
1595
- */
1596
- proto.Spic.AssetProto.UpdateRequest.prototype.getUid = function() {
1597
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 4, ""));
1598
- };
1599
-
1600
-
1601
- /**
1602
- * @param {string} value
1603
- * @return {!proto.Spic.AssetProto.UpdateRequest} returns this
1604
- */
1605
- proto.Spic.AssetProto.UpdateRequest.prototype.setUid = function(value) {
1606
- return jspb.Message.setProto3StringField(this, 4, value);
1607
- };
1608
-
1609
-
1610
- /**
1611
- * optional google.protobuf.BytesValue image = 5;
1612
- * @return {?proto.google.protobuf.BytesValue}
1613
- */
1614
- proto.Spic.AssetProto.UpdateRequest.prototype.getImage = function() {
1615
- return /** @type{?proto.google.protobuf.BytesValue} */ (
1616
- jspb.Message.getWrapperField(this, google_protobuf_wrappers_pb.BytesValue, 5));
1617
- };
1618
-
1619
-
1620
- /**
1621
- * @param {?proto.google.protobuf.BytesValue|undefined} value
1622
- * @return {!proto.Spic.AssetProto.UpdateRequest} returns this
1623
- */
1624
- proto.Spic.AssetProto.UpdateRequest.prototype.setImage = function(value) {
1625
- return jspb.Message.setWrapperField(this, 5, value);
1626
- };
1627
-
1628
-
1629
- /**
1630
- * Clears the message field making it undefined.
1631
- * @return {!proto.Spic.AssetProto.UpdateRequest} returns this
1632
- */
1633
- proto.Spic.AssetProto.UpdateRequest.prototype.clearImage = function() {
1634
- return this.setImage(undefined);
1635
- };
1636
-
1637
-
1638
- /**
1639
- * Returns whether this field is set.
1640
- * @return {boolean}
1641
- */
1642
- proto.Spic.AssetProto.UpdateRequest.prototype.hasImage = function() {
1643
- return jspb.Message.getField(this, 5) != null;
1644
- };
1645
-
1646
-
1647
- /**
1648
- * optional string group_id = 6;
1649
- * @return {string}
1650
- */
1651
- proto.Spic.AssetProto.UpdateRequest.prototype.getGroupId = function() {
1652
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 6, ""));
1653
- };
1654
-
1655
-
1656
- /**
1657
- * @param {string} value
1658
- * @return {!proto.Spic.AssetProto.UpdateRequest} returns this
1659
- */
1660
- proto.Spic.AssetProto.UpdateRequest.prototype.setGroupId = function(value) {
1661
- return jspb.Message.setProto3StringField(this, 6, value);
1662
- };
1663
-
1664
-
1665
- /**
1666
- * optional int32 client_id = 7;
1667
- * @return {number}
1668
- */
1669
- proto.Spic.AssetProto.UpdateRequest.prototype.getClientId = function() {
1670
- return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 7, 0));
1671
- };
1672
-
1673
-
1674
- /**
1675
- * @param {number} value
1676
- * @return {!proto.Spic.AssetProto.UpdateRequest} returns this
1677
- */
1678
- proto.Spic.AssetProto.UpdateRequest.prototype.setClientId = function(value) {
1679
- return jspb.Message.setProto3IntField(this, 7, value);
1680
- };
1681
-
1682
-
1683
- /**
1684
- * optional AssetType asset_type = 8;
1685
- * @return {!proto.Spic.AssetProto.AssetType}
1686
- */
1687
- proto.Spic.AssetProto.UpdateRequest.prototype.getAssetType = function() {
1688
- return /** @type {!proto.Spic.AssetProto.AssetType} */ (jspb.Message.getFieldWithDefault(this, 8, 0));
1689
- };
1690
-
1691
-
1692
- /**
1693
- * @param {!proto.Spic.AssetProto.AssetType} value
1694
- * @return {!proto.Spic.AssetProto.UpdateRequest} returns this
1695
- */
1696
- proto.Spic.AssetProto.UpdateRequest.prototype.setAssetType = function(value) {
1697
- return jspb.Message.setProto3EnumField(this, 8, value);
1698
- };
1699
-
1700
-
1701
-
1702
- /**
1703
- * Oneof group definitions for this message. Each group defines the field
1704
- * numbers belonging to that group. When of these fields' value is set, all
1705
- * other fields in the group are cleared. During deserialization, if multiple
1706
- * fields are encountered for a group, only the last value seen will be kept.
1707
- * @private {!Array<!Array<number>>}
1708
- * @const
1709
- */
1710
- proto.Spic.AssetProto.DeleteRequest.oneofGroups_ = [[1,2]];
1711
-
1712
- /**
1713
- * @enum {number}
1714
- */
1715
- proto.Spic.AssetProto.DeleteRequest.SearchCase = {
1716
- SEARCH_NOT_SET: 0,
1717
- ID: 1,
1718
- UID: 2
1719
- };
1720
-
1721
- /**
1722
- * @return {proto.Spic.AssetProto.DeleteRequest.SearchCase}
1723
- */
1724
- proto.Spic.AssetProto.DeleteRequest.prototype.getSearchCase = function() {
1725
- return /** @type {proto.Spic.AssetProto.DeleteRequest.SearchCase} */(jspb.Message.computeOneofCase(this, proto.Spic.AssetProto.DeleteRequest.oneofGroups_[0]));
1726
- };
1727
-
1728
-
1729
-
1730
- if (jspb.Message.GENERATE_TO_OBJECT) {
1731
- /**
1732
- * Creates an object representation of this proto.
1733
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
1734
- * Optional fields that are not set will be set to undefined.
1735
- * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
1736
- * For the list of reserved names please see:
1737
- * net/proto2/compiler/js/internal/generator.cc#kKeyword.
1738
- * @param {boolean=} opt_includeInstance Deprecated. whether to include the
1739
- * JSPB instance for transitional soy proto support:
1740
- * http://goto/soy-param-migration
1741
- * @return {!Object}
1742
- */
1743
- proto.Spic.AssetProto.DeleteRequest.prototype.toObject = function(opt_includeInstance) {
1744
- return proto.Spic.AssetProto.DeleteRequest.toObject(opt_includeInstance, this);
1745
- };
1746
-
1747
-
1748
- /**
1749
- * Static version of the {@see toObject} method.
1750
- * @param {boolean|undefined} includeInstance Deprecated. Whether to include
1751
- * the JSPB instance for transitional soy proto support:
1752
- * http://goto/soy-param-migration
1753
- * @param {!proto.Spic.AssetProto.DeleteRequest} msg The msg instance to transform.
1754
- * @return {!Object}
1755
- * @suppress {unusedLocalVariables} f is only used for nested messages
1756
- */
1757
- proto.Spic.AssetProto.DeleteRequest.toObject = function(includeInstance, msg) {
1758
- var f, obj = {
1759
- id: jspb.Message.getFieldWithDefault(msg, 1, 0),
1760
- uid: jspb.Message.getFieldWithDefault(msg, 2, "")
1761
- };
1762
-
1763
- if (includeInstance) {
1764
- obj.$jspbMessageInstance = msg;
1765
- }
1766
- return obj;
1767
- };
1768
- }
1769
-
1770
-
1771
- /**
1772
- * Deserializes binary data (in protobuf wire format).
1773
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
1774
- * @return {!proto.Spic.AssetProto.DeleteRequest}
1775
- */
1776
- proto.Spic.AssetProto.DeleteRequest.deserializeBinary = function(bytes) {
1777
- var reader = new jspb.BinaryReader(bytes);
1778
- var msg = new proto.Spic.AssetProto.DeleteRequest;
1779
- return proto.Spic.AssetProto.DeleteRequest.deserializeBinaryFromReader(msg, reader);
1780
- };
1781
-
1782
-
1783
- /**
1784
- * Deserializes binary data (in protobuf wire format) from the
1785
- * given reader into the given message object.
1786
- * @param {!proto.Spic.AssetProto.DeleteRequest} msg The message object to deserialize into.
1787
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
1788
- * @return {!proto.Spic.AssetProto.DeleteRequest}
1789
- */
1790
- proto.Spic.AssetProto.DeleteRequest.deserializeBinaryFromReader = function(msg, reader) {
1791
- while (reader.nextField()) {
1792
- if (reader.isEndGroup()) {
1793
- break;
1794
- }
1795
- var field = reader.getFieldNumber();
1796
- switch (field) {
1797
- case 1:
1798
- var value = /** @type {number} */ (reader.readInt64());
1799
- msg.setId(value);
1800
- break;
1801
- case 2:
1802
- var value = /** @type {string} */ (reader.readString());
1803
- msg.setUid(value);
1804
- break;
1805
- default:
1806
- reader.skipField();
1807
- break;
1808
- }
1809
- }
1810
- return msg;
1811
- };
1812
-
1813
-
1814
- /**
1815
- * Serializes the message to binary data (in protobuf wire format).
1816
- * @return {!Uint8Array}
1817
- */
1818
- proto.Spic.AssetProto.DeleteRequest.prototype.serializeBinary = function() {
1819
- var writer = new jspb.BinaryWriter();
1820
- proto.Spic.AssetProto.DeleteRequest.serializeBinaryToWriter(this, writer);
1821
- return writer.getResultBuffer();
1822
- };
1823
-
1824
-
1825
- /**
1826
- * Serializes the given message to binary data (in protobuf wire
1827
- * format), writing to the given BinaryWriter.
1828
- * @param {!proto.Spic.AssetProto.DeleteRequest} message
1829
- * @param {!jspb.BinaryWriter} writer
1830
- * @suppress {unusedLocalVariables} f is only used for nested messages
1831
- */
1832
- proto.Spic.AssetProto.DeleteRequest.serializeBinaryToWriter = function(message, writer) {
1833
- var f = undefined;
1834
- f = /** @type {number} */ (jspb.Message.getField(message, 1));
1835
- if (f != null) {
1836
- writer.writeInt64(
1837
- 1,
1838
- f
1839
- );
1840
- }
1841
- f = /** @type {string} */ (jspb.Message.getField(message, 2));
1842
- if (f != null) {
1843
- writer.writeString(
1844
- 2,
1845
- f
1846
- );
1847
- }
1848
- };
1849
-
1850
-
1851
- /**
1852
- * optional int64 id = 1;
1853
- * @return {number}
1854
- */
1855
- proto.Spic.AssetProto.DeleteRequest.prototype.getId = function() {
1856
- return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 1, 0));
1857
- };
1858
-
1859
-
1860
- /**
1861
- * @param {number} value
1862
- * @return {!proto.Spic.AssetProto.DeleteRequest} returns this
1863
- */
1864
- proto.Spic.AssetProto.DeleteRequest.prototype.setId = function(value) {
1865
- return jspb.Message.setOneofField(this, 1, proto.Spic.AssetProto.DeleteRequest.oneofGroups_[0], value);
1866
- };
1867
-
1868
-
1869
- /**
1870
- * Clears the field making it undefined.
1871
- * @return {!proto.Spic.AssetProto.DeleteRequest} returns this
1872
- */
1873
- proto.Spic.AssetProto.DeleteRequest.prototype.clearId = function() {
1874
- return jspb.Message.setOneofField(this, 1, proto.Spic.AssetProto.DeleteRequest.oneofGroups_[0], undefined);
1875
- };
1876
-
1877
-
1878
- /**
1879
- * Returns whether this field is set.
1880
- * @return {boolean}
1881
- */
1882
- proto.Spic.AssetProto.DeleteRequest.prototype.hasId = function() {
1883
- return jspb.Message.getField(this, 1) != null;
1884
- };
1885
-
1886
-
1887
- /**
1888
- * optional string uid = 2;
1889
- * @return {string}
1890
- */
1891
- proto.Spic.AssetProto.DeleteRequest.prototype.getUid = function() {
1892
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
1893
- };
1894
-
1895
-
1896
- /**
1897
- * @param {string} value
1898
- * @return {!proto.Spic.AssetProto.DeleteRequest} returns this
1899
- */
1900
- proto.Spic.AssetProto.DeleteRequest.prototype.setUid = function(value) {
1901
- return jspb.Message.setOneofField(this, 2, proto.Spic.AssetProto.DeleteRequest.oneofGroups_[0], value);
1902
- };
1903
-
1904
-
1905
- /**
1906
- * Clears the field making it undefined.
1907
- * @return {!proto.Spic.AssetProto.DeleteRequest} returns this
1908
- */
1909
- proto.Spic.AssetProto.DeleteRequest.prototype.clearUid = function() {
1910
- return jspb.Message.setOneofField(this, 2, proto.Spic.AssetProto.DeleteRequest.oneofGroups_[0], undefined);
1911
- };
1912
-
1913
-
1914
- /**
1915
- * Returns whether this field is set.
1916
- * @return {boolean}
1917
- */
1918
- proto.Spic.AssetProto.DeleteRequest.prototype.hasUid = function() {
1919
- return jspb.Message.getField(this, 2) != null;
1920
- };
1921
-
1922
-
1923
-
1924
-
1925
-
1926
- if (jspb.Message.GENERATE_TO_OBJECT) {
1927
- /**
1928
- * Creates an object representation of this proto.
1929
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
1930
- * Optional fields that are not set will be set to undefined.
1931
- * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
1932
- * For the list of reserved names please see:
1933
- * net/proto2/compiler/js/internal/generator.cc#kKeyword.
1934
- * @param {boolean=} opt_includeInstance Deprecated. whether to include the
1935
- * JSPB instance for transitional soy proto support:
1936
- * http://goto/soy-param-migration
1937
- * @return {!Object}
1938
- */
1939
- proto.Spic.AssetProto.SearchRequest.prototype.toObject = function(opt_includeInstance) {
1940
- return proto.Spic.AssetProto.SearchRequest.toObject(opt_includeInstance, this);
1941
- };
1942
-
1943
-
1944
- /**
1945
- * Static version of the {@see toObject} method.
1946
- * @param {boolean|undefined} includeInstance Deprecated. Whether to include
1947
- * the JSPB instance for transitional soy proto support:
1948
- * http://goto/soy-param-migration
1949
- * @param {!proto.Spic.AssetProto.SearchRequest} msg The msg instance to transform.
1950
- * @return {!Object}
1951
- * @suppress {unusedLocalVariables} f is only used for nested messages
1952
- */
1953
- proto.Spic.AssetProto.SearchRequest.toObject = function(includeInstance, msg) {
1954
- var f, obj = {
1955
- name: jspb.Message.getFieldWithDefault(msg, 1, ""),
1956
- locationId: jspb.Message.getFieldWithDefault(msg, 2, 0),
1957
- groupId: jspb.Message.getFieldWithDefault(msg, 3, ""),
1958
- page: jspb.Message.getFieldWithDefault(msg, 4, 0),
1959
- count: jspb.Message.getFieldWithDefault(msg, 5, 0),
1960
- assetType: jspb.Message.getFieldWithDefault(msg, 6, 0)
1961
- };
1962
-
1963
- if (includeInstance) {
1964
- obj.$jspbMessageInstance = msg;
1965
- }
1966
- return obj;
1967
- };
1968
- }
1969
-
1970
-
1971
- /**
1972
- * Deserializes binary data (in protobuf wire format).
1973
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
1974
- * @return {!proto.Spic.AssetProto.SearchRequest}
1975
- */
1976
- proto.Spic.AssetProto.SearchRequest.deserializeBinary = function(bytes) {
1977
- var reader = new jspb.BinaryReader(bytes);
1978
- var msg = new proto.Spic.AssetProto.SearchRequest;
1979
- return proto.Spic.AssetProto.SearchRequest.deserializeBinaryFromReader(msg, reader);
1980
- };
1981
-
1982
-
1983
- /**
1984
- * Deserializes binary data (in protobuf wire format) from the
1985
- * given reader into the given message object.
1986
- * @param {!proto.Spic.AssetProto.SearchRequest} msg The message object to deserialize into.
1987
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
1988
- * @return {!proto.Spic.AssetProto.SearchRequest}
1989
- */
1990
- proto.Spic.AssetProto.SearchRequest.deserializeBinaryFromReader = function(msg, reader) {
1991
- while (reader.nextField()) {
1992
- if (reader.isEndGroup()) {
1993
- break;
1994
- }
1995
- var field = reader.getFieldNumber();
1996
- switch (field) {
1997
- case 1:
1998
- var value = /** @type {string} */ (reader.readString());
1999
- msg.setName(value);
2000
- break;
2001
- case 2:
2002
- var value = /** @type {number} */ (reader.readInt64());
2003
- msg.setLocationId(value);
2004
- break;
2005
- case 3:
2006
- var value = /** @type {string} */ (reader.readString());
2007
- msg.setGroupId(value);
2008
- break;
2009
- case 4:
2010
- var value = /** @type {number} */ (reader.readInt32());
2011
- msg.setPage(value);
2012
- break;
2013
- case 5:
2014
- var value = /** @type {number} */ (reader.readInt32());
2015
- msg.setCount(value);
2016
- break;
2017
- case 6:
2018
- var value = /** @type {!proto.Spic.AssetProto.AssetType} */ (reader.readEnum());
2019
- msg.setAssetType(value);
2020
- break;
2021
- default:
2022
- reader.skipField();
2023
- break;
2024
- }
2025
- }
2026
- return msg;
2027
- };
2028
-
2029
-
2030
- /**
2031
- * Serializes the message to binary data (in protobuf wire format).
2032
- * @return {!Uint8Array}
2033
- */
2034
- proto.Spic.AssetProto.SearchRequest.prototype.serializeBinary = function() {
2035
- var writer = new jspb.BinaryWriter();
2036
- proto.Spic.AssetProto.SearchRequest.serializeBinaryToWriter(this, writer);
2037
- return writer.getResultBuffer();
2038
- };
2039
-
2040
-
2041
- /**
2042
- * Serializes the given message to binary data (in protobuf wire
2043
- * format), writing to the given BinaryWriter.
2044
- * @param {!proto.Spic.AssetProto.SearchRequest} message
2045
- * @param {!jspb.BinaryWriter} writer
2046
- * @suppress {unusedLocalVariables} f is only used for nested messages
2047
- */
2048
- proto.Spic.AssetProto.SearchRequest.serializeBinaryToWriter = function(message, writer) {
2049
- var f = undefined;
2050
- f = message.getName();
2051
- if (f.length > 0) {
2052
- writer.writeString(
2053
- 1,
2054
- f
2055
- );
2056
- }
2057
- f = message.getLocationId();
2058
- if (f !== 0) {
2059
- writer.writeInt64(
2060
- 2,
2061
- f
2062
- );
2063
- }
2064
- f = message.getGroupId();
2065
- if (f.length > 0) {
2066
- writer.writeString(
2067
- 3,
2068
- f
2069
- );
2070
- }
2071
- f = message.getPage();
2072
- if (f !== 0) {
2073
- writer.writeInt32(
2074
- 4,
2075
- f
2076
- );
2077
- }
2078
- f = message.getCount();
2079
- if (f !== 0) {
2080
- writer.writeInt32(
2081
- 5,
2082
- f
2083
- );
2084
- }
2085
- f = message.getAssetType();
2086
- if (f !== 0.0) {
2087
- writer.writeEnum(
2088
- 6,
2089
- f
2090
- );
2091
- }
2092
- };
2093
-
2094
-
2095
- /**
2096
- * optional string name = 1;
2097
- * @return {string}
2098
- */
2099
- proto.Spic.AssetProto.SearchRequest.prototype.getName = function() {
2100
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
2101
- };
2102
-
2103
-
2104
- /**
2105
- * @param {string} value
2106
- * @return {!proto.Spic.AssetProto.SearchRequest} returns this
2107
- */
2108
- proto.Spic.AssetProto.SearchRequest.prototype.setName = function(value) {
2109
- return jspb.Message.setProto3StringField(this, 1, value);
2110
- };
2111
-
2112
-
2113
- /**
2114
- * optional int64 location_id = 2;
2115
- * @return {number}
2116
- */
2117
- proto.Spic.AssetProto.SearchRequest.prototype.getLocationId = function() {
2118
- return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 2, 0));
2119
- };
2120
-
2121
-
2122
- /**
2123
- * @param {number} value
2124
- * @return {!proto.Spic.AssetProto.SearchRequest} returns this
2125
- */
2126
- proto.Spic.AssetProto.SearchRequest.prototype.setLocationId = function(value) {
2127
- return jspb.Message.setProto3IntField(this, 2, value);
2128
- };
2129
-
2130
-
2131
- /**
2132
- * optional string group_id = 3;
2133
- * @return {string}
2134
- */
2135
- proto.Spic.AssetProto.SearchRequest.prototype.getGroupId = function() {
2136
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
2137
- };
2138
-
2139
-
2140
- /**
2141
- * @param {string} value
2142
- * @return {!proto.Spic.AssetProto.SearchRequest} returns this
2143
- */
2144
- proto.Spic.AssetProto.SearchRequest.prototype.setGroupId = function(value) {
2145
- return jspb.Message.setProto3StringField(this, 3, value);
2146
- };
2147
-
2148
-
2149
- /**
2150
- * optional int32 page = 4;
2151
- * @return {number}
2152
- */
2153
- proto.Spic.AssetProto.SearchRequest.prototype.getPage = function() {
2154
- return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 4, 0));
2155
- };
2156
-
2157
-
2158
- /**
2159
- * @param {number} value
2160
- * @return {!proto.Spic.AssetProto.SearchRequest} returns this
2161
- */
2162
- proto.Spic.AssetProto.SearchRequest.prototype.setPage = function(value) {
2163
- return jspb.Message.setProto3IntField(this, 4, value);
2164
- };
2165
-
2166
-
2167
- /**
2168
- * optional int32 count = 5;
2169
- * @return {number}
2170
- */
2171
- proto.Spic.AssetProto.SearchRequest.prototype.getCount = function() {
2172
- return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 5, 0));
2173
- };
2174
-
2175
-
2176
- /**
2177
- * @param {number} value
2178
- * @return {!proto.Spic.AssetProto.SearchRequest} returns this
2179
- */
2180
- proto.Spic.AssetProto.SearchRequest.prototype.setCount = function(value) {
2181
- return jspb.Message.setProto3IntField(this, 5, value);
2182
- };
2183
-
2184
-
2185
- /**
2186
- * optional AssetType asset_type = 6;
2187
- * @return {!proto.Spic.AssetProto.AssetType}
2188
- */
2189
- proto.Spic.AssetProto.SearchRequest.prototype.getAssetType = function() {
2190
- return /** @type {!proto.Spic.AssetProto.AssetType} */ (jspb.Message.getFieldWithDefault(this, 6, 0));
2191
- };
2192
-
2193
-
2194
- /**
2195
- * @param {!proto.Spic.AssetProto.AssetType} value
2196
- * @return {!proto.Spic.AssetProto.SearchRequest} returns this
2197
- */
2198
- proto.Spic.AssetProto.SearchRequest.prototype.setAssetType = function(value) {
2199
- return jspb.Message.setProto3EnumField(this, 6, value);
2200
- };
2201
-
2202
-
2203
-
2204
- /**
2205
- * List of repeated fields within this message type.
2206
- * @private {!Array<number>}
2207
- * @const
2208
- */
2209
- proto.Spic.AssetProto.SearchReply.repeatedFields_ = [1];
2210
-
2211
-
2212
-
2213
- if (jspb.Message.GENERATE_TO_OBJECT) {
2214
- /**
2215
- * Creates an object representation of this proto.
2216
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
2217
- * Optional fields that are not set will be set to undefined.
2218
- * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
2219
- * For the list of reserved names please see:
2220
- * net/proto2/compiler/js/internal/generator.cc#kKeyword.
2221
- * @param {boolean=} opt_includeInstance Deprecated. whether to include the
2222
- * JSPB instance for transitional soy proto support:
2223
- * http://goto/soy-param-migration
2224
- * @return {!Object}
2225
- */
2226
- proto.Spic.AssetProto.SearchReply.prototype.toObject = function(opt_includeInstance) {
2227
- return proto.Spic.AssetProto.SearchReply.toObject(opt_includeInstance, this);
2228
- };
2229
-
2230
-
2231
- /**
2232
- * Static version of the {@see toObject} method.
2233
- * @param {boolean|undefined} includeInstance Deprecated. Whether to include
2234
- * the JSPB instance for transitional soy proto support:
2235
- * http://goto/soy-param-migration
2236
- * @param {!proto.Spic.AssetProto.SearchReply} msg The msg instance to transform.
2237
- * @return {!Object}
2238
- * @suppress {unusedLocalVariables} f is only used for nested messages
2239
- */
2240
- proto.Spic.AssetProto.SearchReply.toObject = function(includeInstance, msg) {
2241
- var f, obj = {
2242
- assetsList: jspb.Message.toObjectList(msg.getAssetsList(),
2243
- proto.Spic.AssetWithLocation.toObject, includeInstance),
2244
- pagination: (f = msg.getPagination()) && platform_pagination_pb.PaginationProto.toObject(includeInstance, f)
2245
- };
2246
-
2247
- if (includeInstance) {
2248
- obj.$jspbMessageInstance = msg;
2249
- }
2250
- return obj;
2251
- };
2252
- }
2253
-
2254
-
2255
- /**
2256
- * Deserializes binary data (in protobuf wire format).
2257
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
2258
- * @return {!proto.Spic.AssetProto.SearchReply}
2259
- */
2260
- proto.Spic.AssetProto.SearchReply.deserializeBinary = function(bytes) {
2261
- var reader = new jspb.BinaryReader(bytes);
2262
- var msg = new proto.Spic.AssetProto.SearchReply;
2263
- return proto.Spic.AssetProto.SearchReply.deserializeBinaryFromReader(msg, reader);
2264
- };
2265
-
2266
-
2267
- /**
2268
- * Deserializes binary data (in protobuf wire format) from the
2269
- * given reader into the given message object.
2270
- * @param {!proto.Spic.AssetProto.SearchReply} msg The message object to deserialize into.
2271
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
2272
- * @return {!proto.Spic.AssetProto.SearchReply}
2273
- */
2274
- proto.Spic.AssetProto.SearchReply.deserializeBinaryFromReader = function(msg, reader) {
2275
- while (reader.nextField()) {
2276
- if (reader.isEndGroup()) {
2277
- break;
2278
- }
2279
- var field = reader.getFieldNumber();
2280
- switch (field) {
2281
- case 1:
2282
- var value = new proto.Spic.AssetWithLocation;
2283
- reader.readMessage(value,proto.Spic.AssetWithLocation.deserializeBinaryFromReader);
2284
- msg.addAssets(value);
2285
- break;
2286
- case 2:
2287
- var value = new platform_pagination_pb.PaginationProto;
2288
- reader.readMessage(value,platform_pagination_pb.PaginationProto.deserializeBinaryFromReader);
2289
- msg.setPagination(value);
2290
- break;
2291
- default:
2292
- reader.skipField();
2293
- break;
2294
- }
2295
- }
2296
- return msg;
2297
- };
2298
-
2299
-
2300
- /**
2301
- * Serializes the message to binary data (in protobuf wire format).
2302
- * @return {!Uint8Array}
2303
- */
2304
- proto.Spic.AssetProto.SearchReply.prototype.serializeBinary = function() {
2305
- var writer = new jspb.BinaryWriter();
2306
- proto.Spic.AssetProto.SearchReply.serializeBinaryToWriter(this, writer);
2307
- return writer.getResultBuffer();
2308
- };
2309
-
2310
-
2311
- /**
2312
- * Serializes the given message to binary data (in protobuf wire
2313
- * format), writing to the given BinaryWriter.
2314
- * @param {!proto.Spic.AssetProto.SearchReply} message
2315
- * @param {!jspb.BinaryWriter} writer
2316
- * @suppress {unusedLocalVariables} f is only used for nested messages
2317
- */
2318
- proto.Spic.AssetProto.SearchReply.serializeBinaryToWriter = function(message, writer) {
2319
- var f = undefined;
2320
- f = message.getAssetsList();
2321
- if (f.length > 0) {
2322
- writer.writeRepeatedMessage(
2323
- 1,
2324
- f,
2325
- proto.Spic.AssetWithLocation.serializeBinaryToWriter
2326
- );
2327
- }
2328
- f = message.getPagination();
2329
- if (f != null) {
2330
- writer.writeMessage(
2331
- 2,
2332
- f,
2333
- platform_pagination_pb.PaginationProto.serializeBinaryToWriter
2334
- );
2335
- }
2336
- };
2337
-
2338
-
2339
- /**
2340
- * repeated AssetWithLocation assets = 1;
2341
- * @return {!Array<!proto.Spic.AssetWithLocation>}
2342
- */
2343
- proto.Spic.AssetProto.SearchReply.prototype.getAssetsList = function() {
2344
- return /** @type{!Array<!proto.Spic.AssetWithLocation>} */ (
2345
- jspb.Message.getRepeatedWrapperField(this, proto.Spic.AssetWithLocation, 1));
2346
- };
2347
-
2348
-
2349
- /**
2350
- * @param {!Array<!proto.Spic.AssetWithLocation>} value
2351
- * @return {!proto.Spic.AssetProto.SearchReply} returns this
2352
- */
2353
- proto.Spic.AssetProto.SearchReply.prototype.setAssetsList = function(value) {
2354
- return jspb.Message.setRepeatedWrapperField(this, 1, value);
2355
- };
2356
-
2357
-
2358
- /**
2359
- * @param {!proto.Spic.AssetWithLocation=} opt_value
2360
- * @param {number=} opt_index
2361
- * @return {!proto.Spic.AssetWithLocation}
2362
- */
2363
- proto.Spic.AssetProto.SearchReply.prototype.addAssets = function(opt_value, opt_index) {
2364
- return jspb.Message.addToRepeatedWrapperField(this, 1, opt_value, proto.Spic.AssetWithLocation, opt_index);
2365
- };
2366
-
2367
-
2368
- /**
2369
- * Clears the list making it empty but non-null.
2370
- * @return {!proto.Spic.AssetProto.SearchReply} returns this
2371
- */
2372
- proto.Spic.AssetProto.SearchReply.prototype.clearAssetsList = function() {
2373
- return this.setAssetsList([]);
2374
- };
2375
-
2376
-
2377
- /**
2378
- * optional Platform.PaginationProto pagination = 2;
2379
- * @return {?proto.Platform.PaginationProto}
2380
- */
2381
- proto.Spic.AssetProto.SearchReply.prototype.getPagination = function() {
2382
- return /** @type{?proto.Platform.PaginationProto} */ (
2383
- jspb.Message.getWrapperField(this, platform_pagination_pb.PaginationProto, 2));
2384
- };
2385
-
2386
-
2387
- /**
2388
- * @param {?proto.Platform.PaginationProto|undefined} value
2389
- * @return {!proto.Spic.AssetProto.SearchReply} returns this
2390
- */
2391
- proto.Spic.AssetProto.SearchReply.prototype.setPagination = function(value) {
2392
- return jspb.Message.setWrapperField(this, 2, value);
2393
- };
2394
-
2395
-
2396
- /**
2397
- * Clears the message field making it undefined.
2398
- * @return {!proto.Spic.AssetProto.SearchReply} returns this
2399
- */
2400
- proto.Spic.AssetProto.SearchReply.prototype.clearPagination = function() {
2401
- return this.setPagination(undefined);
2402
- };
2403
-
2404
-
2405
- /**
2406
- * Returns whether this field is set.
2407
- * @return {boolean}
2408
- */
2409
- proto.Spic.AssetProto.SearchReply.prototype.hasPagination = function() {
2410
- return jspb.Message.getField(this, 2) != null;
2411
- };
2412
-
2413
-
2414
-
2415
-
2416
-
2417
- if (jspb.Message.GENERATE_TO_OBJECT) {
2418
- /**
2419
- * Creates an object representation of this proto.
2420
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
2421
- * Optional fields that are not set will be set to undefined.
2422
- * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
2423
- * For the list of reserved names please see:
2424
- * net/proto2/compiler/js/internal/generator.cc#kKeyword.
2425
- * @param {boolean=} opt_includeInstance Deprecated. whether to include the
2426
- * JSPB instance for transitional soy proto support:
2427
- * http://goto/soy-param-migration
2428
- * @return {!Object}
2429
- */
2430
- proto.Spic.AssetProto.LocationSearchRequest.prototype.toObject = function(opt_includeInstance) {
2431
- return proto.Spic.AssetProto.LocationSearchRequest.toObject(opt_includeInstance, this);
2432
- };
2433
-
2434
-
2435
- /**
2436
- * Static version of the {@see toObject} method.
2437
- * @param {boolean|undefined} includeInstance Deprecated. Whether to include
2438
- * the JSPB instance for transitional soy proto support:
2439
- * http://goto/soy-param-migration
2440
- * @param {!proto.Spic.AssetProto.LocationSearchRequest} msg The msg instance to transform.
2441
- * @return {!Object}
2442
- * @suppress {unusedLocalVariables} f is only used for nested messages
2443
- */
2444
- proto.Spic.AssetProto.LocationSearchRequest.toObject = function(includeInstance, msg) {
2445
- var f, obj = {
2446
- latitude: jspb.Message.getFloatingPointFieldWithDefault(msg, 1, 0.0),
2447
- longitude: jspb.Message.getFloatingPointFieldWithDefault(msg, 2, 0.0),
2448
- limit: jspb.Message.getFieldWithDefault(msg, 3, 0)
2449
- };
2450
-
2451
- if (includeInstance) {
2452
- obj.$jspbMessageInstance = msg;
2453
- }
2454
- return obj;
2455
- };
2456
- }
2457
-
2458
-
2459
- /**
2460
- * Deserializes binary data (in protobuf wire format).
2461
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
2462
- * @return {!proto.Spic.AssetProto.LocationSearchRequest}
2463
- */
2464
- proto.Spic.AssetProto.LocationSearchRequest.deserializeBinary = function(bytes) {
2465
- var reader = new jspb.BinaryReader(bytes);
2466
- var msg = new proto.Spic.AssetProto.LocationSearchRequest;
2467
- return proto.Spic.AssetProto.LocationSearchRequest.deserializeBinaryFromReader(msg, reader);
2468
- };
2469
-
2470
-
2471
- /**
2472
- * Deserializes binary data (in protobuf wire format) from the
2473
- * given reader into the given message object.
2474
- * @param {!proto.Spic.AssetProto.LocationSearchRequest} msg The message object to deserialize into.
2475
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
2476
- * @return {!proto.Spic.AssetProto.LocationSearchRequest}
2477
- */
2478
- proto.Spic.AssetProto.LocationSearchRequest.deserializeBinaryFromReader = function(msg, reader) {
2479
- while (reader.nextField()) {
2480
- if (reader.isEndGroup()) {
2481
- break;
2482
- }
2483
- var field = reader.getFieldNumber();
2484
- switch (field) {
2485
- case 1:
2486
- var value = /** @type {number} */ (reader.readDouble());
2487
- msg.setLatitude(value);
2488
- break;
2489
- case 2:
2490
- var value = /** @type {number} */ (reader.readDouble());
2491
- msg.setLongitude(value);
2492
- break;
2493
- case 3:
2494
- var value = /** @type {number} */ (reader.readInt32());
2495
- msg.setLimit(value);
2496
- break;
2497
- default:
2498
- reader.skipField();
2499
- break;
2500
- }
2501
- }
2502
- return msg;
2503
- };
2504
-
2505
-
2506
- /**
2507
- * Serializes the message to binary data (in protobuf wire format).
2508
- * @return {!Uint8Array}
2509
- */
2510
- proto.Spic.AssetProto.LocationSearchRequest.prototype.serializeBinary = function() {
2511
- var writer = new jspb.BinaryWriter();
2512
- proto.Spic.AssetProto.LocationSearchRequest.serializeBinaryToWriter(this, writer);
2513
- return writer.getResultBuffer();
2514
- };
2515
-
2516
-
2517
- /**
2518
- * Serializes the given message to binary data (in protobuf wire
2519
- * format), writing to the given BinaryWriter.
2520
- * @param {!proto.Spic.AssetProto.LocationSearchRequest} message
2521
- * @param {!jspb.BinaryWriter} writer
2522
- * @suppress {unusedLocalVariables} f is only used for nested messages
2523
- */
2524
- proto.Spic.AssetProto.LocationSearchRequest.serializeBinaryToWriter = function(message, writer) {
2525
- var f = undefined;
2526
- f = message.getLatitude();
2527
- if (f !== 0.0) {
2528
- writer.writeDouble(
2529
- 1,
2530
- f
2531
- );
2532
- }
2533
- f = message.getLongitude();
2534
- if (f !== 0.0) {
2535
- writer.writeDouble(
2536
- 2,
2537
- f
2538
- );
2539
- }
2540
- f = message.getLimit();
2541
- if (f !== 0) {
2542
- writer.writeInt32(
2543
- 3,
2544
- f
2545
- );
2546
- }
2547
- };
2548
-
2549
-
2550
- /**
2551
- * optional double latitude = 1;
2552
- * @return {number}
2553
- */
2554
- proto.Spic.AssetProto.LocationSearchRequest.prototype.getLatitude = function() {
2555
- return /** @type {number} */ (jspb.Message.getFloatingPointFieldWithDefault(this, 1, 0.0));
2556
- };
2557
-
2558
-
2559
- /**
2560
- * @param {number} value
2561
- * @return {!proto.Spic.AssetProto.LocationSearchRequest} returns this
2562
- */
2563
- proto.Spic.AssetProto.LocationSearchRequest.prototype.setLatitude = function(value) {
2564
- return jspb.Message.setProto3FloatField(this, 1, value);
2565
- };
2566
-
2567
-
2568
- /**
2569
- * optional double longitude = 2;
2570
- * @return {number}
2571
- */
2572
- proto.Spic.AssetProto.LocationSearchRequest.prototype.getLongitude = function() {
2573
- return /** @type {number} */ (jspb.Message.getFloatingPointFieldWithDefault(this, 2, 0.0));
2574
- };
2575
-
2576
-
2577
- /**
2578
- * @param {number} value
2579
- * @return {!proto.Spic.AssetProto.LocationSearchRequest} returns this
2580
- */
2581
- proto.Spic.AssetProto.LocationSearchRequest.prototype.setLongitude = function(value) {
2582
- return jspb.Message.setProto3FloatField(this, 2, value);
2583
- };
2584
-
2585
-
2586
- /**
2587
- * optional int32 limit = 3;
2588
- * @return {number}
2589
- */
2590
- proto.Spic.AssetProto.LocationSearchRequest.prototype.getLimit = function() {
2591
- return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 3, 0));
2592
- };
2593
-
2594
-
2595
- /**
2596
- * @param {number} value
2597
- * @return {!proto.Spic.AssetProto.LocationSearchRequest} returns this
2598
- */
2599
- proto.Spic.AssetProto.LocationSearchRequest.prototype.setLimit = function(value) {
2600
- return jspb.Message.setProto3IntField(this, 3, value);
2601
- };
2602
-
2603
-
2604
-
2605
- /**
2606
- * List of repeated fields within this message type.
2607
- * @private {!Array<number>}
2608
- * @const
2609
- */
2610
- proto.Spic.AssetProto.LocationSearchReply.repeatedFields_ = [1];
2611
-
2612
-
2613
-
2614
- if (jspb.Message.GENERATE_TO_OBJECT) {
2615
- /**
2616
- * Creates an object representation of this proto.
2617
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
2618
- * Optional fields that are not set will be set to undefined.
2619
- * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
2620
- * For the list of reserved names please see:
2621
- * net/proto2/compiler/js/internal/generator.cc#kKeyword.
2622
- * @param {boolean=} opt_includeInstance Deprecated. whether to include the
2623
- * JSPB instance for transitional soy proto support:
2624
- * http://goto/soy-param-migration
2625
- * @return {!Object}
2626
- */
2627
- proto.Spic.AssetProto.LocationSearchReply.prototype.toObject = function(opt_includeInstance) {
2628
- return proto.Spic.AssetProto.LocationSearchReply.toObject(opt_includeInstance, this);
2629
- };
2630
-
2631
-
2632
- /**
2633
- * Static version of the {@see toObject} method.
2634
- * @param {boolean|undefined} includeInstance Deprecated. Whether to include
2635
- * the JSPB instance for transitional soy proto support:
2636
- * http://goto/soy-param-migration
2637
- * @param {!proto.Spic.AssetProto.LocationSearchReply} msg The msg instance to transform.
2638
- * @return {!Object}
2639
- * @suppress {unusedLocalVariables} f is only used for nested messages
2640
- */
2641
- proto.Spic.AssetProto.LocationSearchReply.toObject = function(includeInstance, msg) {
2642
- var f, obj = {
2643
- assetsList: jspb.Message.toObjectList(msg.getAssetsList(),
2644
- proto.Spic.AssetWithLocationAndDistance.toObject, includeInstance)
2645
- };
2646
-
2647
- if (includeInstance) {
2648
- obj.$jspbMessageInstance = msg;
2649
- }
2650
- return obj;
2651
- };
2652
- }
2653
-
2654
-
2655
- /**
2656
- * Deserializes binary data (in protobuf wire format).
2657
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
2658
- * @return {!proto.Spic.AssetProto.LocationSearchReply}
2659
- */
2660
- proto.Spic.AssetProto.LocationSearchReply.deserializeBinary = function(bytes) {
2661
- var reader = new jspb.BinaryReader(bytes);
2662
- var msg = new proto.Spic.AssetProto.LocationSearchReply;
2663
- return proto.Spic.AssetProto.LocationSearchReply.deserializeBinaryFromReader(msg, reader);
2664
- };
2665
-
2666
-
2667
- /**
2668
- * Deserializes binary data (in protobuf wire format) from the
2669
- * given reader into the given message object.
2670
- * @param {!proto.Spic.AssetProto.LocationSearchReply} msg The message object to deserialize into.
2671
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
2672
- * @return {!proto.Spic.AssetProto.LocationSearchReply}
2673
- */
2674
- proto.Spic.AssetProto.LocationSearchReply.deserializeBinaryFromReader = function(msg, reader) {
2675
- while (reader.nextField()) {
2676
- if (reader.isEndGroup()) {
2677
- break;
2678
- }
2679
- var field = reader.getFieldNumber();
2680
- switch (field) {
2681
- case 1:
2682
- var value = new proto.Spic.AssetWithLocationAndDistance;
2683
- reader.readMessage(value,proto.Spic.AssetWithLocationAndDistance.deserializeBinaryFromReader);
2684
- msg.addAssets(value);
2685
- break;
2686
- default:
2687
- reader.skipField();
2688
- break;
2689
- }
2690
- }
2691
- return msg;
2692
- };
2693
-
2694
-
2695
- /**
2696
- * Serializes the message to binary data (in protobuf wire format).
2697
- * @return {!Uint8Array}
2698
- */
2699
- proto.Spic.AssetProto.LocationSearchReply.prototype.serializeBinary = function() {
2700
- var writer = new jspb.BinaryWriter();
2701
- proto.Spic.AssetProto.LocationSearchReply.serializeBinaryToWriter(this, writer);
2702
- return writer.getResultBuffer();
2703
- };
2704
-
2705
-
2706
- /**
2707
- * Serializes the given message to binary data (in protobuf wire
2708
- * format), writing to the given BinaryWriter.
2709
- * @param {!proto.Spic.AssetProto.LocationSearchReply} message
2710
- * @param {!jspb.BinaryWriter} writer
2711
- * @suppress {unusedLocalVariables} f is only used for nested messages
2712
- */
2713
- proto.Spic.AssetProto.LocationSearchReply.serializeBinaryToWriter = function(message, writer) {
2714
- var f = undefined;
2715
- f = message.getAssetsList();
2716
- if (f.length > 0) {
2717
- writer.writeRepeatedMessage(
2718
- 1,
2719
- f,
2720
- proto.Spic.AssetWithLocationAndDistance.serializeBinaryToWriter
2721
- );
2722
- }
2723
- };
2724
-
2725
-
2726
- /**
2727
- * repeated AssetWithLocationAndDistance assets = 1;
2728
- * @return {!Array<!proto.Spic.AssetWithLocationAndDistance>}
2729
- */
2730
- proto.Spic.AssetProto.LocationSearchReply.prototype.getAssetsList = function() {
2731
- return /** @type{!Array<!proto.Spic.AssetWithLocationAndDistance>} */ (
2732
- jspb.Message.getRepeatedWrapperField(this, proto.Spic.AssetWithLocationAndDistance, 1));
2733
- };
2734
-
2735
-
2736
- /**
2737
- * @param {!Array<!proto.Spic.AssetWithLocationAndDistance>} value
2738
- * @return {!proto.Spic.AssetProto.LocationSearchReply} returns this
2739
- */
2740
- proto.Spic.AssetProto.LocationSearchReply.prototype.setAssetsList = function(value) {
2741
- return jspb.Message.setRepeatedWrapperField(this, 1, value);
2742
- };
2743
-
2744
-
2745
- /**
2746
- * @param {!proto.Spic.AssetWithLocationAndDistance=} opt_value
2747
- * @param {number=} opt_index
2748
- * @return {!proto.Spic.AssetWithLocationAndDistance}
2749
- */
2750
- proto.Spic.AssetProto.LocationSearchReply.prototype.addAssets = function(opt_value, opt_index) {
2751
- return jspb.Message.addToRepeatedWrapperField(this, 1, opt_value, proto.Spic.AssetWithLocationAndDistance, opt_index);
2752
- };
2753
-
2754
-
2755
- /**
2756
- * Clears the list making it empty but non-null.
2757
- * @return {!proto.Spic.AssetProto.LocationSearchReply} returns this
2758
- */
2759
- proto.Spic.AssetProto.LocationSearchReply.prototype.clearAssetsList = function() {
2760
- return this.setAssetsList([]);
2761
- };
2762
-
2763
-
2764
-
2765
-
2766
-
2767
- if (jspb.Message.GENERATE_TO_OBJECT) {
2768
- /**
2769
- * Creates an object representation of this proto.
2770
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
2771
- * Optional fields that are not set will be set to undefined.
2772
- * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
2773
- * For the list of reserved names please see:
2774
- * net/proto2/compiler/js/internal/generator.cc#kKeyword.
2775
- * @param {boolean=} opt_includeInstance Deprecated. whether to include the
2776
- * JSPB instance for transitional soy proto support:
2777
- * http://goto/soy-param-migration
2778
- * @return {!Object}
2779
- */
2780
- proto.Spic.AssetProto.ReplaceBatteryRequest.prototype.toObject = function(opt_includeInstance) {
2781
- return proto.Spic.AssetProto.ReplaceBatteryRequest.toObject(opt_includeInstance, this);
2782
- };
2783
-
2784
-
2785
- /**
2786
- * Static version of the {@see toObject} method.
2787
- * @param {boolean|undefined} includeInstance Deprecated. Whether to include
2788
- * the JSPB instance for transitional soy proto support:
2789
- * http://goto/soy-param-migration
2790
- * @param {!proto.Spic.AssetProto.ReplaceBatteryRequest} msg The msg instance to transform.
2791
- * @return {!Object}
2792
- * @suppress {unusedLocalVariables} f is only used for nested messages
2793
- */
2794
- proto.Spic.AssetProto.ReplaceBatteryRequest.toObject = function(includeInstance, msg) {
2795
- var f, obj = {
2796
- id: jspb.Message.getFieldWithDefault(msg, 1, 0)
2797
- };
2798
-
2799
- if (includeInstance) {
2800
- obj.$jspbMessageInstance = msg;
2801
- }
2802
- return obj;
2803
- };
2804
- }
2805
-
2806
-
2807
- /**
2808
- * Deserializes binary data (in protobuf wire format).
2809
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
2810
- * @return {!proto.Spic.AssetProto.ReplaceBatteryRequest}
2811
- */
2812
- proto.Spic.AssetProto.ReplaceBatteryRequest.deserializeBinary = function(bytes) {
2813
- var reader = new jspb.BinaryReader(bytes);
2814
- var msg = new proto.Spic.AssetProto.ReplaceBatteryRequest;
2815
- return proto.Spic.AssetProto.ReplaceBatteryRequest.deserializeBinaryFromReader(msg, reader);
2816
- };
2817
-
2818
-
2819
- /**
2820
- * Deserializes binary data (in protobuf wire format) from the
2821
- * given reader into the given message object.
2822
- * @param {!proto.Spic.AssetProto.ReplaceBatteryRequest} msg The message object to deserialize into.
2823
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
2824
- * @return {!proto.Spic.AssetProto.ReplaceBatteryRequest}
2825
- */
2826
- proto.Spic.AssetProto.ReplaceBatteryRequest.deserializeBinaryFromReader = function(msg, reader) {
2827
- while (reader.nextField()) {
2828
- if (reader.isEndGroup()) {
2829
- break;
2830
- }
2831
- var field = reader.getFieldNumber();
2832
- switch (field) {
2833
- case 1:
2834
- var value = /** @type {number} */ (reader.readInt64());
2835
- msg.setId(value);
2836
- break;
2837
- default:
2838
- reader.skipField();
2839
- break;
2840
- }
2841
- }
2842
- return msg;
2843
- };
2844
-
2845
-
2846
- /**
2847
- * Serializes the message to binary data (in protobuf wire format).
2848
- * @return {!Uint8Array}
2849
- */
2850
- proto.Spic.AssetProto.ReplaceBatteryRequest.prototype.serializeBinary = function() {
2851
- var writer = new jspb.BinaryWriter();
2852
- proto.Spic.AssetProto.ReplaceBatteryRequest.serializeBinaryToWriter(this, writer);
2853
- return writer.getResultBuffer();
2854
- };
2855
-
2856
-
2857
- /**
2858
- * Serializes the given message to binary data (in protobuf wire
2859
- * format), writing to the given BinaryWriter.
2860
- * @param {!proto.Spic.AssetProto.ReplaceBatteryRequest} message
2861
- * @param {!jspb.BinaryWriter} writer
2862
- * @suppress {unusedLocalVariables} f is only used for nested messages
2863
- */
2864
- proto.Spic.AssetProto.ReplaceBatteryRequest.serializeBinaryToWriter = function(message, writer) {
2865
- var f = undefined;
2866
- f = message.getId();
2867
- if (f !== 0) {
2868
- writer.writeInt64(
2869
- 1,
2870
- f
2871
- );
2872
- }
2873
- };
2874
-
2875
-
2876
- /**
2877
- * optional int64 id = 1;
2878
- * @return {number}
2879
- */
2880
- proto.Spic.AssetProto.ReplaceBatteryRequest.prototype.getId = function() {
2881
- return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 1, 0));
2882
- };
2883
-
2884
-
2885
- /**
2886
- * @param {number} value
2887
- * @return {!proto.Spic.AssetProto.ReplaceBatteryRequest} returns this
2888
- */
2889
- proto.Spic.AssetProto.ReplaceBatteryRequest.prototype.setId = function(value) {
2890
- return jspb.Message.setProto3IntField(this, 1, value);
2891
- };
2892
-
2893
-
2894
-
2895
-
2896
-
2897
- if (jspb.Message.GENERATE_TO_OBJECT) {
2898
- /**
2899
- * Creates an object representation of this proto.
2900
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
2901
- * Optional fields that are not set will be set to undefined.
2902
- * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
2903
- * For the list of reserved names please see:
2904
- * net/proto2/compiler/js/internal/generator.cc#kKeyword.
2905
- * @param {boolean=} opt_includeInstance Deprecated. whether to include the
2906
- * JSPB instance for transitional soy proto support:
2907
- * http://goto/soy-param-migration
2908
- * @return {!Object}
2909
- */
2910
- proto.Spic.AssetProto.Image.prototype.toObject = function(opt_includeInstance) {
2911
- return proto.Spic.AssetProto.Image.toObject(opt_includeInstance, this);
2912
- };
2913
-
2914
-
2915
- /**
2916
- * Static version of the {@see toObject} method.
2917
- * @param {boolean|undefined} includeInstance Deprecated. Whether to include
2918
- * the JSPB instance for transitional soy proto support:
2919
- * http://goto/soy-param-migration
2920
- * @param {!proto.Spic.AssetProto.Image} msg The msg instance to transform.
2921
- * @return {!Object}
2922
- * @suppress {unusedLocalVariables} f is only used for nested messages
2923
- */
2924
- proto.Spic.AssetProto.Image.toObject = function(includeInstance, msg) {
2925
- var f, obj = {
2926
-
2927
- };
2928
-
2929
- if (includeInstance) {
2930
- obj.$jspbMessageInstance = msg;
2931
- }
2932
- return obj;
2933
- };
2934
- }
2935
-
2936
-
2937
- /**
2938
- * Deserializes binary data (in protobuf wire format).
2939
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
2940
- * @return {!proto.Spic.AssetProto.Image}
2941
- */
2942
- proto.Spic.AssetProto.Image.deserializeBinary = function(bytes) {
2943
- var reader = new jspb.BinaryReader(bytes);
2944
- var msg = new proto.Spic.AssetProto.Image;
2945
- return proto.Spic.AssetProto.Image.deserializeBinaryFromReader(msg, reader);
2946
- };
2947
-
2948
-
2949
- /**
2950
- * Deserializes binary data (in protobuf wire format) from the
2951
- * given reader into the given message object.
2952
- * @param {!proto.Spic.AssetProto.Image} msg The message object to deserialize into.
2953
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
2954
- * @return {!proto.Spic.AssetProto.Image}
2955
- */
2956
- proto.Spic.AssetProto.Image.deserializeBinaryFromReader = function(msg, reader) {
2957
- while (reader.nextField()) {
2958
- if (reader.isEndGroup()) {
2959
- break;
2960
- }
2961
- var field = reader.getFieldNumber();
2962
- switch (field) {
2963
- default:
2964
- reader.skipField();
2965
- break;
2966
- }
2967
- }
2968
- return msg;
2969
- };
2970
-
2971
-
2972
- /**
2973
- * Serializes the message to binary data (in protobuf wire format).
2974
- * @return {!Uint8Array}
2975
- */
2976
- proto.Spic.AssetProto.Image.prototype.serializeBinary = function() {
2977
- var writer = new jspb.BinaryWriter();
2978
- proto.Spic.AssetProto.Image.serializeBinaryToWriter(this, writer);
2979
- return writer.getResultBuffer();
2980
- };
2981
-
2982
-
2983
- /**
2984
- * Serializes the given message to binary data (in protobuf wire
2985
- * format), writing to the given BinaryWriter.
2986
- * @param {!proto.Spic.AssetProto.Image} message
2987
- * @param {!jspb.BinaryWriter} writer
2988
- * @suppress {unusedLocalVariables} f is only used for nested messages
2989
- */
2990
- proto.Spic.AssetProto.Image.serializeBinaryToWriter = function(message, writer) {
2991
- var f = undefined;
2992
- };
2993
-
2994
-
2995
-
2996
-
2997
-
2998
- if (jspb.Message.GENERATE_TO_OBJECT) {
2999
- /**
3000
- * Creates an object representation of this proto.
3001
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
3002
- * Optional fields that are not set will be set to undefined.
3003
- * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
3004
- * For the list of reserved names please see:
3005
- * net/proto2/compiler/js/internal/generator.cc#kKeyword.
3006
- * @param {boolean=} opt_includeInstance Deprecated. whether to include the
3007
- * JSPB instance for transitional soy proto support:
3008
- * http://goto/soy-param-migration
3009
- * @return {!Object}
3010
- */
3011
- proto.Spic.AssetProto.Image.RetrieveRequest.prototype.toObject = function(opt_includeInstance) {
3012
- return proto.Spic.AssetProto.Image.RetrieveRequest.toObject(opt_includeInstance, this);
3013
- };
3014
-
3015
-
3016
- /**
3017
- * Static version of the {@see toObject} method.
3018
- * @param {boolean|undefined} includeInstance Deprecated. Whether to include
3019
- * the JSPB instance for transitional soy proto support:
3020
- * http://goto/soy-param-migration
3021
- * @param {!proto.Spic.AssetProto.Image.RetrieveRequest} msg The msg instance to transform.
3022
- * @return {!Object}
3023
- * @suppress {unusedLocalVariables} f is only used for nested messages
3024
- */
3025
- proto.Spic.AssetProto.Image.RetrieveRequest.toObject = function(includeInstance, msg) {
3026
- var f, obj = {
3027
- id: jspb.Message.getFieldWithDefault(msg, 1, 0)
3028
- };
3029
-
3030
- if (includeInstance) {
3031
- obj.$jspbMessageInstance = msg;
3032
- }
3033
- return obj;
3034
- };
3035
- }
3036
-
3037
-
3038
- /**
3039
- * Deserializes binary data (in protobuf wire format).
3040
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
3041
- * @return {!proto.Spic.AssetProto.Image.RetrieveRequest}
3042
- */
3043
- proto.Spic.AssetProto.Image.RetrieveRequest.deserializeBinary = function(bytes) {
3044
- var reader = new jspb.BinaryReader(bytes);
3045
- var msg = new proto.Spic.AssetProto.Image.RetrieveRequest;
3046
- return proto.Spic.AssetProto.Image.RetrieveRequest.deserializeBinaryFromReader(msg, reader);
3047
- };
3048
-
3049
-
3050
- /**
3051
- * Deserializes binary data (in protobuf wire format) from the
3052
- * given reader into the given message object.
3053
- * @param {!proto.Spic.AssetProto.Image.RetrieveRequest} msg The message object to deserialize into.
3054
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
3055
- * @return {!proto.Spic.AssetProto.Image.RetrieveRequest}
3056
- */
3057
- proto.Spic.AssetProto.Image.RetrieveRequest.deserializeBinaryFromReader = function(msg, reader) {
3058
- while (reader.nextField()) {
3059
- if (reader.isEndGroup()) {
3060
- break;
3061
- }
3062
- var field = reader.getFieldNumber();
3063
- switch (field) {
3064
- case 1:
3065
- var value = /** @type {number} */ (reader.readInt64());
3066
- msg.setId(value);
3067
- break;
3068
- default:
3069
- reader.skipField();
3070
- break;
3071
- }
3072
- }
3073
- return msg;
3074
- };
3075
-
3076
-
3077
- /**
3078
- * Serializes the message to binary data (in protobuf wire format).
3079
- * @return {!Uint8Array}
3080
- */
3081
- proto.Spic.AssetProto.Image.RetrieveRequest.prototype.serializeBinary = function() {
3082
- var writer = new jspb.BinaryWriter();
3083
- proto.Spic.AssetProto.Image.RetrieveRequest.serializeBinaryToWriter(this, writer);
3084
- return writer.getResultBuffer();
3085
- };
3086
-
3087
-
3088
- /**
3089
- * Serializes the given message to binary data (in protobuf wire
3090
- * format), writing to the given BinaryWriter.
3091
- * @param {!proto.Spic.AssetProto.Image.RetrieveRequest} message
3092
- * @param {!jspb.BinaryWriter} writer
3093
- * @suppress {unusedLocalVariables} f is only used for nested messages
3094
- */
3095
- proto.Spic.AssetProto.Image.RetrieveRequest.serializeBinaryToWriter = function(message, writer) {
3096
- var f = undefined;
3097
- f = message.getId();
3098
- if (f !== 0) {
3099
- writer.writeInt64(
3100
- 1,
3101
- f
3102
- );
3103
- }
3104
- };
3105
-
3106
-
3107
- /**
3108
- * optional int64 id = 1;
3109
- * @return {number}
3110
- */
3111
- proto.Spic.AssetProto.Image.RetrieveRequest.prototype.getId = function() {
3112
- return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 1, 0));
3113
- };
3114
-
3115
-
3116
- /**
3117
- * @param {number} value
3118
- * @return {!proto.Spic.AssetProto.Image.RetrieveRequest} returns this
3119
- */
3120
- proto.Spic.AssetProto.Image.RetrieveRequest.prototype.setId = function(value) {
3121
- return jspb.Message.setProto3IntField(this, 1, value);
3122
- };
3123
-
3124
-
3125
-
3126
-
3127
-
3128
- if (jspb.Message.GENERATE_TO_OBJECT) {
3129
- /**
3130
- * Creates an object representation of this proto.
3131
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
3132
- * Optional fields that are not set will be set to undefined.
3133
- * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
3134
- * For the list of reserved names please see:
3135
- * net/proto2/compiler/js/internal/generator.cc#kKeyword.
3136
- * @param {boolean=} opt_includeInstance Deprecated. whether to include the
3137
- * JSPB instance for transitional soy proto support:
3138
- * http://goto/soy-param-migration
3139
- * @return {!Object}
3140
- */
3141
- proto.Spic.AssetProto.Image.RetrieveReply.prototype.toObject = function(opt_includeInstance) {
3142
- return proto.Spic.AssetProto.Image.RetrieveReply.toObject(opt_includeInstance, this);
3143
- };
3144
-
3145
-
3146
- /**
3147
- * Static version of the {@see toObject} method.
3148
- * @param {boolean|undefined} includeInstance Deprecated. Whether to include
3149
- * the JSPB instance for transitional soy proto support:
3150
- * http://goto/soy-param-migration
3151
- * @param {!proto.Spic.AssetProto.Image.RetrieveReply} msg The msg instance to transform.
3152
- * @return {!Object}
3153
- * @suppress {unusedLocalVariables} f is only used for nested messages
3154
- */
3155
- proto.Spic.AssetProto.Image.RetrieveReply.toObject = function(includeInstance, msg) {
3156
- var f, obj = {
3157
- data: msg.getData_asB64()
3158
- };
3159
-
3160
- if (includeInstance) {
3161
- obj.$jspbMessageInstance = msg;
3162
- }
3163
- return obj;
3164
- };
3165
- }
3166
-
3167
-
3168
- /**
3169
- * Deserializes binary data (in protobuf wire format).
3170
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
3171
- * @return {!proto.Spic.AssetProto.Image.RetrieveReply}
3172
- */
3173
- proto.Spic.AssetProto.Image.RetrieveReply.deserializeBinary = function(bytes) {
3174
- var reader = new jspb.BinaryReader(bytes);
3175
- var msg = new proto.Spic.AssetProto.Image.RetrieveReply;
3176
- return proto.Spic.AssetProto.Image.RetrieveReply.deserializeBinaryFromReader(msg, reader);
3177
- };
3178
-
3179
-
3180
- /**
3181
- * Deserializes binary data (in protobuf wire format) from the
3182
- * given reader into the given message object.
3183
- * @param {!proto.Spic.AssetProto.Image.RetrieveReply} msg The message object to deserialize into.
3184
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
3185
- * @return {!proto.Spic.AssetProto.Image.RetrieveReply}
3186
- */
3187
- proto.Spic.AssetProto.Image.RetrieveReply.deserializeBinaryFromReader = function(msg, reader) {
3188
- while (reader.nextField()) {
3189
- if (reader.isEndGroup()) {
3190
- break;
3191
- }
3192
- var field = reader.getFieldNumber();
3193
- switch (field) {
3194
- case 1:
3195
- var value = /** @type {!Uint8Array} */ (reader.readBytes());
3196
- msg.setData(value);
3197
- break;
3198
- default:
3199
- reader.skipField();
3200
- break;
3201
- }
3202
- }
3203
- return msg;
3204
- };
3205
-
3206
-
3207
- /**
3208
- * Serializes the message to binary data (in protobuf wire format).
3209
- * @return {!Uint8Array}
3210
- */
3211
- proto.Spic.AssetProto.Image.RetrieveReply.prototype.serializeBinary = function() {
3212
- var writer = new jspb.BinaryWriter();
3213
- proto.Spic.AssetProto.Image.RetrieveReply.serializeBinaryToWriter(this, writer);
3214
- return writer.getResultBuffer();
3215
- };
3216
-
3217
-
3218
- /**
3219
- * Serializes the given message to binary data (in protobuf wire
3220
- * format), writing to the given BinaryWriter.
3221
- * @param {!proto.Spic.AssetProto.Image.RetrieveReply} message
3222
- * @param {!jspb.BinaryWriter} writer
3223
- * @suppress {unusedLocalVariables} f is only used for nested messages
3224
- */
3225
- proto.Spic.AssetProto.Image.RetrieveReply.serializeBinaryToWriter = function(message, writer) {
3226
- var f = undefined;
3227
- f = message.getData_asU8();
3228
- if (f.length > 0) {
3229
- writer.writeBytes(
3230
- 1,
3231
- f
3232
- );
3233
- }
3234
- };
3235
-
3236
-
3237
- /**
3238
- * optional bytes data = 1;
3239
- * @return {!(string|Uint8Array)}
3240
- */
3241
- proto.Spic.AssetProto.Image.RetrieveReply.prototype.getData = function() {
3242
- return /** @type {!(string|Uint8Array)} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
3243
- };
3244
-
3245
-
3246
- /**
3247
- * optional bytes data = 1;
3248
- * This is a type-conversion wrapper around `getData()`
3249
- * @return {string}
3250
- */
3251
- proto.Spic.AssetProto.Image.RetrieveReply.prototype.getData_asB64 = function() {
3252
- return /** @type {string} */ (jspb.Message.bytesAsB64(
3253
- this.getData()));
3254
- };
3255
-
3256
-
3257
- /**
3258
- * optional bytes data = 1;
3259
- * Note that Uint8Array is not supported on all browsers.
3260
- * @see http://caniuse.com/Uint8Array
3261
- * This is a type-conversion wrapper around `getData()`
3262
- * @return {!Uint8Array}
3263
- */
3264
- proto.Spic.AssetProto.Image.RetrieveReply.prototype.getData_asU8 = function() {
3265
- return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8(
3266
- this.getData()));
3267
- };
3268
-
3269
-
3270
- /**
3271
- * @param {!(string|Uint8Array)} value
3272
- * @return {!proto.Spic.AssetProto.Image.RetrieveReply} returns this
3273
- */
3274
- proto.Spic.AssetProto.Image.RetrieveReply.prototype.setData = function(value) {
3275
- return jspb.Message.setProto3BytesField(this, 1, value);
3276
- };
3277
-
3278
-
3279
-
3280
-
3281
-
3282
- if (jspb.Message.GENERATE_TO_OBJECT) {
3283
- /**
3284
- * Creates an object representation of this proto.
3285
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
3286
- * Optional fields that are not set will be set to undefined.
3287
- * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
3288
- * For the list of reserved names please see:
3289
- * net/proto2/compiler/js/internal/generator.cc#kKeyword.
3290
- * @param {boolean=} opt_includeInstance Deprecated. whether to include the
3291
- * JSPB instance for transitional soy proto support:
3292
- * http://goto/soy-param-migration
3293
- * @return {!Object}
3294
- */
3295
- proto.Spic.AssetProto.ComponentState.prototype.toObject = function(opt_includeInstance) {
3296
- return proto.Spic.AssetProto.ComponentState.toObject(opt_includeInstance, this);
3297
- };
3298
-
3299
-
3300
- /**
3301
- * Static version of the {@see toObject} method.
3302
- * @param {boolean|undefined} includeInstance Deprecated. Whether to include
3303
- * the JSPB instance for transitional soy proto support:
3304
- * http://goto/soy-param-migration
3305
- * @param {!proto.Spic.AssetProto.ComponentState} msg The msg instance to transform.
3306
- * @return {!Object}
3307
- * @suppress {unusedLocalVariables} f is only used for nested messages
3308
- */
3309
- proto.Spic.AssetProto.ComponentState.toObject = function(includeInstance, msg) {
3310
- var f, obj = {
3311
- id: jspb.Message.getFieldWithDefault(msg, 1, ""),
3312
- componentIdentifier: jspb.Message.getFieldWithDefault(msg, 2, 0),
3313
- componentId: jspb.Message.getFieldWithDefault(msg, 3, ""),
3314
- componentClass: jspb.Message.getFieldWithDefault(msg, 4, ""),
3315
- value: jspb.Message.getFieldWithDefault(msg, 5, ""),
3316
- lastChanged: (f = msg.getLastChanged()) && google_protobuf_timestamp_pb.Timestamp.toObject(includeInstance, f),
3317
- lastUpdated: (f = msg.getLastUpdated()) && google_protobuf_timestamp_pb.Timestamp.toObject(includeInstance, f),
3318
- lastReported: (f = msg.getLastReported()) && google_protobuf_timestamp_pb.Timestamp.toObject(includeInstance, f),
3319
- attributesMap: (f = msg.getAttributesMap()) ? f.toObject(includeInstance, undefined) : [],
3320
- metadataMap: (f = msg.getMetadataMap()) ? f.toObject(includeInstance, undefined) : [],
3321
- deviceType: jspb.Message.getFieldWithDefault(msg, 11, 0)
3322
- };
3323
-
3324
- if (includeInstance) {
3325
- obj.$jspbMessageInstance = msg;
3326
- }
3327
- return obj;
3328
- };
3329
- }
3330
-
3331
-
3332
- /**
3333
- * Deserializes binary data (in protobuf wire format).
3334
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
3335
- * @return {!proto.Spic.AssetProto.ComponentState}
3336
- */
3337
- proto.Spic.AssetProto.ComponentState.deserializeBinary = function(bytes) {
3338
- var reader = new jspb.BinaryReader(bytes);
3339
- var msg = new proto.Spic.AssetProto.ComponentState;
3340
- return proto.Spic.AssetProto.ComponentState.deserializeBinaryFromReader(msg, reader);
3341
- };
3342
-
3343
-
3344
- /**
3345
- * Deserializes binary data (in protobuf wire format) from the
3346
- * given reader into the given message object.
3347
- * @param {!proto.Spic.AssetProto.ComponentState} msg The message object to deserialize into.
3348
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
3349
- * @return {!proto.Spic.AssetProto.ComponentState}
3350
- */
3351
- proto.Spic.AssetProto.ComponentState.deserializeBinaryFromReader = function(msg, reader) {
3352
- while (reader.nextField()) {
3353
- if (reader.isEndGroup()) {
3354
- break;
3355
- }
3356
- var field = reader.getFieldNumber();
3357
- switch (field) {
3358
- case 1:
3359
- var value = /** @type {string} */ (reader.readString());
3360
- msg.setId(value);
3361
- break;
3362
- case 2:
3363
- var value = /** @type {!proto.Spic.ComponentIdentifier} */ (reader.readEnum());
3364
- msg.setComponentIdentifier(value);
3365
- break;
3366
- case 3:
3367
- var value = /** @type {string} */ (reader.readString());
3368
- msg.setComponentId(value);
3369
- break;
3370
- case 4:
3371
- var value = /** @type {string} */ (reader.readString());
3372
- msg.setComponentClass(value);
3373
- break;
3374
- case 5:
3375
- var value = /** @type {string} */ (reader.readString());
3376
- msg.setValue(value);
3377
- break;
3378
- case 6:
3379
- var value = new google_protobuf_timestamp_pb.Timestamp;
3380
- reader.readMessage(value,google_protobuf_timestamp_pb.Timestamp.deserializeBinaryFromReader);
3381
- msg.setLastChanged(value);
3382
- break;
3383
- case 7:
3384
- var value = new google_protobuf_timestamp_pb.Timestamp;
3385
- reader.readMessage(value,google_protobuf_timestamp_pb.Timestamp.deserializeBinaryFromReader);
3386
- msg.setLastUpdated(value);
3387
- break;
3388
- case 8:
3389
- var value = new google_protobuf_timestamp_pb.Timestamp;
3390
- reader.readMessage(value,google_protobuf_timestamp_pb.Timestamp.deserializeBinaryFromReader);
3391
- msg.setLastReported(value);
3392
- break;
3393
- case 9:
3394
- var value = msg.getAttributesMap();
3395
- reader.readMessage(value, function(message, reader) {
3396
- jspb.Map.deserializeBinary(message, reader, jspb.BinaryReader.prototype.readString, jspb.BinaryReader.prototype.readString, null, "", "");
3397
- });
3398
- break;
3399
- case 10:
3400
- var value = msg.getMetadataMap();
3401
- reader.readMessage(value, function(message, reader) {
3402
- jspb.Map.deserializeBinary(message, reader, jspb.BinaryReader.prototype.readString, jspb.BinaryReader.prototype.readString, null, "", "");
3403
- });
3404
- break;
3405
- case 11:
3406
- var value = /** @type {!proto.Spic.AssetProto.DeviceType} */ (reader.readEnum());
3407
- msg.setDeviceType(value);
3408
- break;
3409
- default:
3410
- reader.skipField();
3411
- break;
3412
- }
3413
- }
3414
- return msg;
3415
- };
3416
-
3417
-
3418
- /**
3419
- * Serializes the message to binary data (in protobuf wire format).
3420
- * @return {!Uint8Array}
3421
- */
3422
- proto.Spic.AssetProto.ComponentState.prototype.serializeBinary = function() {
3423
- var writer = new jspb.BinaryWriter();
3424
- proto.Spic.AssetProto.ComponentState.serializeBinaryToWriter(this, writer);
3425
- return writer.getResultBuffer();
3426
- };
3427
-
3428
-
3429
- /**
3430
- * Serializes the given message to binary data (in protobuf wire
3431
- * format), writing to the given BinaryWriter.
3432
- * @param {!proto.Spic.AssetProto.ComponentState} message
3433
- * @param {!jspb.BinaryWriter} writer
3434
- * @suppress {unusedLocalVariables} f is only used for nested messages
3435
- */
3436
- proto.Spic.AssetProto.ComponentState.serializeBinaryToWriter = function(message, writer) {
3437
- var f = undefined;
3438
- f = message.getId();
3439
- if (f.length > 0) {
3440
- writer.writeString(
3441
- 1,
3442
- f
3443
- );
3444
- }
3445
- f = message.getComponentIdentifier();
3446
- if (f !== 0.0) {
3447
- writer.writeEnum(
3448
- 2,
3449
- f
3450
- );
3451
- }
3452
- f = message.getComponentId();
3453
- if (f.length > 0) {
3454
- writer.writeString(
3455
- 3,
3456
- f
3457
- );
3458
- }
3459
- f = message.getComponentClass();
3460
- if (f.length > 0) {
3461
- writer.writeString(
3462
- 4,
3463
- f
3464
- );
3465
- }
3466
- f = message.getValue();
3467
- if (f.length > 0) {
3468
- writer.writeString(
3469
- 5,
3470
- f
3471
- );
3472
- }
3473
- f = message.getLastChanged();
3474
- if (f != null) {
3475
- writer.writeMessage(
3476
- 6,
3477
- f,
3478
- google_protobuf_timestamp_pb.Timestamp.serializeBinaryToWriter
3479
- );
3480
- }
3481
- f = message.getLastUpdated();
3482
- if (f != null) {
3483
- writer.writeMessage(
3484
- 7,
3485
- f,
3486
- google_protobuf_timestamp_pb.Timestamp.serializeBinaryToWriter
3487
- );
3488
- }
3489
- f = message.getLastReported();
3490
- if (f != null) {
3491
- writer.writeMessage(
3492
- 8,
3493
- f,
3494
- google_protobuf_timestamp_pb.Timestamp.serializeBinaryToWriter
3495
- );
3496
- }
3497
- f = message.getAttributesMap(true);
3498
- if (f && f.getLength() > 0) {
3499
- f.serializeBinary(9, writer, jspb.BinaryWriter.prototype.writeString, jspb.BinaryWriter.prototype.writeString);
3500
- }
3501
- f = message.getMetadataMap(true);
3502
- if (f && f.getLength() > 0) {
3503
- f.serializeBinary(10, writer, jspb.BinaryWriter.prototype.writeString, jspb.BinaryWriter.prototype.writeString);
3504
- }
3505
- f = message.getDeviceType();
3506
- if (f !== 0.0) {
3507
- writer.writeEnum(
3508
- 11,
3509
- f
3510
- );
3511
- }
3512
- };
3513
-
3514
-
3515
- /**
3516
- * optional string id = 1;
3517
- * @return {string}
3518
- */
3519
- proto.Spic.AssetProto.ComponentState.prototype.getId = function() {
3520
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
3521
- };
3522
-
3523
-
3524
- /**
3525
- * @param {string} value
3526
- * @return {!proto.Spic.AssetProto.ComponentState} returns this
3527
- */
3528
- proto.Spic.AssetProto.ComponentState.prototype.setId = function(value) {
3529
- return jspb.Message.setProto3StringField(this, 1, value);
3530
- };
3531
-
3532
-
3533
- /**
3534
- * optional ComponentIdentifier component_identifier = 2;
3535
- * @return {!proto.Spic.ComponentIdentifier}
3536
- */
3537
- proto.Spic.AssetProto.ComponentState.prototype.getComponentIdentifier = function() {
3538
- return /** @type {!proto.Spic.ComponentIdentifier} */ (jspb.Message.getFieldWithDefault(this, 2, 0));
3539
- };
3540
-
3541
-
3542
- /**
3543
- * @param {!proto.Spic.ComponentIdentifier} value
3544
- * @return {!proto.Spic.AssetProto.ComponentState} returns this
3545
- */
3546
- proto.Spic.AssetProto.ComponentState.prototype.setComponentIdentifier = function(value) {
3547
- return jspb.Message.setProto3EnumField(this, 2, value);
3548
- };
3549
-
3550
-
3551
- /**
3552
- * optional string component_id = 3;
3553
- * @return {string}
3554
- */
3555
- proto.Spic.AssetProto.ComponentState.prototype.getComponentId = function() {
3556
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
3557
- };
3558
-
3559
-
3560
- /**
3561
- * @param {string} value
3562
- * @return {!proto.Spic.AssetProto.ComponentState} returns this
3563
- */
3564
- proto.Spic.AssetProto.ComponentState.prototype.setComponentId = function(value) {
3565
- return jspb.Message.setProto3StringField(this, 3, value);
3566
- };
3567
-
3568
-
3569
- /**
3570
- * optional string component_class = 4;
3571
- * @return {string}
3572
- */
3573
- proto.Spic.AssetProto.ComponentState.prototype.getComponentClass = function() {
3574
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 4, ""));
3575
- };
3576
-
3577
-
3578
- /**
3579
- * @param {string} value
3580
- * @return {!proto.Spic.AssetProto.ComponentState} returns this
3581
- */
3582
- proto.Spic.AssetProto.ComponentState.prototype.setComponentClass = function(value) {
3583
- return jspb.Message.setProto3StringField(this, 4, value);
3584
- };
3585
-
3586
-
3587
- /**
3588
- * optional string value = 5;
3589
- * @return {string}
3590
- */
3591
- proto.Spic.AssetProto.ComponentState.prototype.getValue = function() {
3592
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 5, ""));
3593
- };
3594
-
3595
-
3596
- /**
3597
- * @param {string} value
3598
- * @return {!proto.Spic.AssetProto.ComponentState} returns this
3599
- */
3600
- proto.Spic.AssetProto.ComponentState.prototype.setValue = function(value) {
3601
- return jspb.Message.setProto3StringField(this, 5, value);
3602
- };
3603
-
3604
-
3605
- /**
3606
- * optional google.protobuf.Timestamp last_changed = 6;
3607
- * @return {?proto.google.protobuf.Timestamp}
3608
- */
3609
- proto.Spic.AssetProto.ComponentState.prototype.getLastChanged = function() {
3610
- return /** @type{?proto.google.protobuf.Timestamp} */ (
3611
- jspb.Message.getWrapperField(this, google_protobuf_timestamp_pb.Timestamp, 6));
3612
- };
3613
-
3614
-
3615
- /**
3616
- * @param {?proto.google.protobuf.Timestamp|undefined} value
3617
- * @return {!proto.Spic.AssetProto.ComponentState} returns this
3618
- */
3619
- proto.Spic.AssetProto.ComponentState.prototype.setLastChanged = function(value) {
3620
- return jspb.Message.setWrapperField(this, 6, value);
3621
- };
3622
-
3623
-
3624
- /**
3625
- * Clears the message field making it undefined.
3626
- * @return {!proto.Spic.AssetProto.ComponentState} returns this
3627
- */
3628
- proto.Spic.AssetProto.ComponentState.prototype.clearLastChanged = function() {
3629
- return this.setLastChanged(undefined);
3630
- };
3631
-
3632
-
3633
- /**
3634
- * Returns whether this field is set.
3635
- * @return {boolean}
3636
- */
3637
- proto.Spic.AssetProto.ComponentState.prototype.hasLastChanged = function() {
3638
- return jspb.Message.getField(this, 6) != null;
3639
- };
3640
-
3641
-
3642
- /**
3643
- * optional google.protobuf.Timestamp last_updated = 7;
3644
- * @return {?proto.google.protobuf.Timestamp}
3645
- */
3646
- proto.Spic.AssetProto.ComponentState.prototype.getLastUpdated = function() {
3647
- return /** @type{?proto.google.protobuf.Timestamp} */ (
3648
- jspb.Message.getWrapperField(this, google_protobuf_timestamp_pb.Timestamp, 7));
3649
- };
3650
-
3651
-
3652
- /**
3653
- * @param {?proto.google.protobuf.Timestamp|undefined} value
3654
- * @return {!proto.Spic.AssetProto.ComponentState} returns this
3655
- */
3656
- proto.Spic.AssetProto.ComponentState.prototype.setLastUpdated = function(value) {
3657
- return jspb.Message.setWrapperField(this, 7, value);
3658
- };
3659
-
3660
-
3661
- /**
3662
- * Clears the message field making it undefined.
3663
- * @return {!proto.Spic.AssetProto.ComponentState} returns this
3664
- */
3665
- proto.Spic.AssetProto.ComponentState.prototype.clearLastUpdated = function() {
3666
- return this.setLastUpdated(undefined);
3667
- };
3668
-
3669
-
3670
- /**
3671
- * Returns whether this field is set.
3672
- * @return {boolean}
3673
- */
3674
- proto.Spic.AssetProto.ComponentState.prototype.hasLastUpdated = function() {
3675
- return jspb.Message.getField(this, 7) != null;
3676
- };
3677
-
3678
-
3679
- /**
3680
- * optional google.protobuf.Timestamp last_reported = 8;
3681
- * @return {?proto.google.protobuf.Timestamp}
3682
- */
3683
- proto.Spic.AssetProto.ComponentState.prototype.getLastReported = function() {
3684
- return /** @type{?proto.google.protobuf.Timestamp} */ (
3685
- jspb.Message.getWrapperField(this, google_protobuf_timestamp_pb.Timestamp, 8));
3686
- };
3687
-
3688
-
3689
- /**
3690
- * @param {?proto.google.protobuf.Timestamp|undefined} value
3691
- * @return {!proto.Spic.AssetProto.ComponentState} returns this
3692
- */
3693
- proto.Spic.AssetProto.ComponentState.prototype.setLastReported = function(value) {
3694
- return jspb.Message.setWrapperField(this, 8, value);
3695
- };
3696
-
3697
-
3698
- /**
3699
- * Clears the message field making it undefined.
3700
- * @return {!proto.Spic.AssetProto.ComponentState} returns this
3701
- */
3702
- proto.Spic.AssetProto.ComponentState.prototype.clearLastReported = function() {
3703
- return this.setLastReported(undefined);
3704
- };
3705
-
3706
-
3707
- /**
3708
- * Returns whether this field is set.
3709
- * @return {boolean}
3710
- */
3711
- proto.Spic.AssetProto.ComponentState.prototype.hasLastReported = function() {
3712
- return jspb.Message.getField(this, 8) != null;
3713
- };
3714
-
3715
-
3716
- /**
3717
- * map<string, string> attributes = 9;
3718
- * @param {boolean=} opt_noLazyCreate Do not create the map if
3719
- * empty, instead returning `undefined`
3720
- * @return {!jspb.Map<string,string>}
3721
- */
3722
- proto.Spic.AssetProto.ComponentState.prototype.getAttributesMap = function(opt_noLazyCreate) {
3723
- return /** @type {!jspb.Map<string,string>} */ (
3724
- jspb.Message.getMapField(this, 9, opt_noLazyCreate,
3725
- null));
3726
- };
3727
-
3728
-
3729
- /**
3730
- * Clears values from the map. The map will be non-null.
3731
- * @return {!proto.Spic.AssetProto.ComponentState} returns this
3732
- */
3733
- proto.Spic.AssetProto.ComponentState.prototype.clearAttributesMap = function() {
3734
- this.getAttributesMap().clear();
3735
- return this;
3736
- };
3737
-
3738
-
3739
- /**
3740
- * map<string, string> metadata = 10;
3741
- * @param {boolean=} opt_noLazyCreate Do not create the map if
3742
- * empty, instead returning `undefined`
3743
- * @return {!jspb.Map<string,string>}
3744
- */
3745
- proto.Spic.AssetProto.ComponentState.prototype.getMetadataMap = function(opt_noLazyCreate) {
3746
- return /** @type {!jspb.Map<string,string>} */ (
3747
- jspb.Message.getMapField(this, 10, opt_noLazyCreate,
3748
- null));
3749
- };
3750
-
3751
-
3752
- /**
3753
- * Clears values from the map. The map will be non-null.
3754
- * @return {!proto.Spic.AssetProto.ComponentState} returns this
3755
- */
3756
- proto.Spic.AssetProto.ComponentState.prototype.clearMetadataMap = function() {
3757
- this.getMetadataMap().clear();
3758
- return this;
3759
- };
3760
-
3761
-
3762
- /**
3763
- * optional DeviceType device_type = 11;
3764
- * @return {!proto.Spic.AssetProto.DeviceType}
3765
- */
3766
- proto.Spic.AssetProto.ComponentState.prototype.getDeviceType = function() {
3767
- return /** @type {!proto.Spic.AssetProto.DeviceType} */ (jspb.Message.getFieldWithDefault(this, 11, 0));
3768
- };
3769
-
3770
-
3771
- /**
3772
- * @param {!proto.Spic.AssetProto.DeviceType} value
3773
- * @return {!proto.Spic.AssetProto.ComponentState} returns this
3774
- */
3775
- proto.Spic.AssetProto.ComponentState.prototype.setDeviceType = function(value) {
3776
- return jspb.Message.setProto3EnumField(this, 11, value);
3777
- };
3778
-
3779
-
3780
-
3781
-
3782
-
3783
- if (jspb.Message.GENERATE_TO_OBJECT) {
3784
- /**
3785
- * Creates an object representation of this proto.
3786
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
3787
- * Optional fields that are not set will be set to undefined.
3788
- * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
3789
- * For the list of reserved names please see:
3790
- * net/proto2/compiler/js/internal/generator.cc#kKeyword.
3791
- * @param {boolean=} opt_includeInstance Deprecated. whether to include the
3792
- * JSPB instance for transitional soy proto support:
3793
- * http://goto/soy-param-migration
3794
- * @return {!Object}
3795
- */
3796
- proto.Spic.AssetProto.StateChangedEvent.prototype.toObject = function(opt_includeInstance) {
3797
- return proto.Spic.AssetProto.StateChangedEvent.toObject(opt_includeInstance, this);
3798
- };
3799
-
3800
-
3801
- /**
3802
- * Static version of the {@see toObject} method.
3803
- * @param {boolean|undefined} includeInstance Deprecated. Whether to include
3804
- * the JSPB instance for transitional soy proto support:
3805
- * http://goto/soy-param-migration
3806
- * @param {!proto.Spic.AssetProto.StateChangedEvent} msg The msg instance to transform.
3807
- * @return {!Object}
3808
- * @suppress {unusedLocalVariables} f is only used for nested messages
3809
- */
3810
- proto.Spic.AssetProto.StateChangedEvent.toObject = function(includeInstance, msg) {
3811
- var f, obj = {
3812
- state: (f = msg.getState()) && proto.Spic.AssetProto.ComponentState.toObject(includeInstance, f),
3813
- onlyMetadataUpdated: jspb.Message.getBooleanFieldWithDefault(msg, 2, false),
3814
- onlyAttributesUpdated: jspb.Message.getBooleanFieldWithDefault(msg, 3, false)
3815
- };
3816
-
3817
- if (includeInstance) {
3818
- obj.$jspbMessageInstance = msg;
3819
- }
3820
- return obj;
3821
- };
3822
- }
3823
-
3824
-
3825
- /**
3826
- * Deserializes binary data (in protobuf wire format).
3827
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
3828
- * @return {!proto.Spic.AssetProto.StateChangedEvent}
3829
- */
3830
- proto.Spic.AssetProto.StateChangedEvent.deserializeBinary = function(bytes) {
3831
- var reader = new jspb.BinaryReader(bytes);
3832
- var msg = new proto.Spic.AssetProto.StateChangedEvent;
3833
- return proto.Spic.AssetProto.StateChangedEvent.deserializeBinaryFromReader(msg, reader);
3834
- };
3835
-
3836
-
3837
- /**
3838
- * Deserializes binary data (in protobuf wire format) from the
3839
- * given reader into the given message object.
3840
- * @param {!proto.Spic.AssetProto.StateChangedEvent} msg The message object to deserialize into.
3841
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
3842
- * @return {!proto.Spic.AssetProto.StateChangedEvent}
3843
- */
3844
- proto.Spic.AssetProto.StateChangedEvent.deserializeBinaryFromReader = function(msg, reader) {
3845
- while (reader.nextField()) {
3846
- if (reader.isEndGroup()) {
3847
- break;
3848
- }
3849
- var field = reader.getFieldNumber();
3850
- switch (field) {
3851
- case 1:
3852
- var value = new proto.Spic.AssetProto.ComponentState;
3853
- reader.readMessage(value,proto.Spic.AssetProto.ComponentState.deserializeBinaryFromReader);
3854
- msg.setState(value);
3855
- break;
3856
- case 2:
3857
- var value = /** @type {boolean} */ (reader.readBool());
3858
- msg.setOnlyMetadataUpdated(value);
3859
- break;
3860
- case 3:
3861
- var value = /** @type {boolean} */ (reader.readBool());
3862
- msg.setOnlyAttributesUpdated(value);
3863
- break;
3864
- default:
3865
- reader.skipField();
3866
- break;
3867
- }
3868
- }
3869
- return msg;
3870
- };
3871
-
3872
-
3873
- /**
3874
- * Serializes the message to binary data (in protobuf wire format).
3875
- * @return {!Uint8Array}
3876
- */
3877
- proto.Spic.AssetProto.StateChangedEvent.prototype.serializeBinary = function() {
3878
- var writer = new jspb.BinaryWriter();
3879
- proto.Spic.AssetProto.StateChangedEvent.serializeBinaryToWriter(this, writer);
3880
- return writer.getResultBuffer();
3881
- };
3882
-
3883
-
3884
- /**
3885
- * Serializes the given message to binary data (in protobuf wire
3886
- * format), writing to the given BinaryWriter.
3887
- * @param {!proto.Spic.AssetProto.StateChangedEvent} message
3888
- * @param {!jspb.BinaryWriter} writer
3889
- * @suppress {unusedLocalVariables} f is only used for nested messages
3890
- */
3891
- proto.Spic.AssetProto.StateChangedEvent.serializeBinaryToWriter = function(message, writer) {
3892
- var f = undefined;
3893
- f = message.getState();
3894
- if (f != null) {
3895
- writer.writeMessage(
3896
- 1,
3897
- f,
3898
- proto.Spic.AssetProto.ComponentState.serializeBinaryToWriter
3899
- );
3900
- }
3901
- f = message.getOnlyMetadataUpdated();
3902
- if (f) {
3903
- writer.writeBool(
3904
- 2,
3905
- f
3906
- );
3907
- }
3908
- f = message.getOnlyAttributesUpdated();
3909
- if (f) {
3910
- writer.writeBool(
3911
- 3,
3912
- f
3913
- );
3914
- }
3915
- };
3916
-
3917
-
3918
- /**
3919
- * optional ComponentState state = 1;
3920
- * @return {?proto.Spic.AssetProto.ComponentState}
3921
- */
3922
- proto.Spic.AssetProto.StateChangedEvent.prototype.getState = function() {
3923
- return /** @type{?proto.Spic.AssetProto.ComponentState} */ (
3924
- jspb.Message.getWrapperField(this, proto.Spic.AssetProto.ComponentState, 1));
3925
- };
3926
-
3927
-
3928
- /**
3929
- * @param {?proto.Spic.AssetProto.ComponentState|undefined} value
3930
- * @return {!proto.Spic.AssetProto.StateChangedEvent} returns this
3931
- */
3932
- proto.Spic.AssetProto.StateChangedEvent.prototype.setState = function(value) {
3933
- return jspb.Message.setWrapperField(this, 1, value);
3934
- };
3935
-
3936
-
3937
- /**
3938
- * Clears the message field making it undefined.
3939
- * @return {!proto.Spic.AssetProto.StateChangedEvent} returns this
3940
- */
3941
- proto.Spic.AssetProto.StateChangedEvent.prototype.clearState = function() {
3942
- return this.setState(undefined);
3943
- };
3944
-
3945
-
3946
- /**
3947
- * Returns whether this field is set.
3948
- * @return {boolean}
3949
- */
3950
- proto.Spic.AssetProto.StateChangedEvent.prototype.hasState = function() {
3951
- return jspb.Message.getField(this, 1) != null;
3952
- };
3953
-
3954
-
3955
- /**
3956
- * optional bool only_metadata_updated = 2;
3957
- * @return {boolean}
3958
- */
3959
- proto.Spic.AssetProto.StateChangedEvent.prototype.getOnlyMetadataUpdated = function() {
3960
- return /** @type {boolean} */ (jspb.Message.getBooleanFieldWithDefault(this, 2, false));
3961
- };
3962
-
3963
-
3964
- /**
3965
- * @param {boolean} value
3966
- * @return {!proto.Spic.AssetProto.StateChangedEvent} returns this
3967
- */
3968
- proto.Spic.AssetProto.StateChangedEvent.prototype.setOnlyMetadataUpdated = function(value) {
3969
- return jspb.Message.setProto3BooleanField(this, 2, value);
3970
- };
3971
-
3972
-
3973
- /**
3974
- * optional bool only_attributes_updated = 3;
3975
- * @return {boolean}
3976
- */
3977
- proto.Spic.AssetProto.StateChangedEvent.prototype.getOnlyAttributesUpdated = function() {
3978
- return /** @type {boolean} */ (jspb.Message.getBooleanFieldWithDefault(this, 3, false));
3979
- };
3980
-
3981
-
3982
- /**
3983
- * @param {boolean} value
3984
- * @return {!proto.Spic.AssetProto.StateChangedEvent} returns this
3985
- */
3986
- proto.Spic.AssetProto.StateChangedEvent.prototype.setOnlyAttributesUpdated = function(value) {
3987
- return jspb.Message.setProto3BooleanField(this, 3, value);
3988
- };
3989
-
3990
-
3991
- /**
3992
- * optional int64 id = 1;
3993
- * @return {number}
3994
- */
3995
- proto.Spic.AssetProto.prototype.getId = function() {
3996
- return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 1, 0));
3997
- };
3998
-
3999
-
4000
- /**
4001
- * @param {number} value
4002
- * @return {!proto.Spic.AssetProto} returns this
4003
- */
4004
- proto.Spic.AssetProto.prototype.setId = function(value) {
4005
- return jspb.Message.setProto3IntField(this, 1, value);
4006
- };
4007
-
4008
-
4009
- /**
4010
- * optional string name = 2;
4011
- * @return {string}
4012
- */
4013
- proto.Spic.AssetProto.prototype.getName = function() {
4014
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
4015
- };
4016
-
4017
-
4018
- /**
4019
- * @param {string} value
4020
- * @return {!proto.Spic.AssetProto} returns this
4021
- */
4022
- proto.Spic.AssetProto.prototype.setName = function(value) {
4023
- return jspb.Message.setProto3StringField(this, 2, value);
4024
- };
4025
-
4026
-
4027
- /**
4028
- * optional int64 location_id = 3;
4029
- * @return {number}
4030
- */
4031
- proto.Spic.AssetProto.prototype.getLocationId = function() {
4032
- return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 3, 0));
4033
- };
4034
-
4035
-
4036
- /**
4037
- * @param {number} value
4038
- * @return {!proto.Spic.AssetProto} returns this
4039
- */
4040
- proto.Spic.AssetProto.prototype.setLocationId = function(value) {
4041
- return jspb.Message.setProto3IntField(this, 3, value);
4042
- };
4043
-
4044
-
4045
- /**
4046
- * optional string uid = 4;
4047
- * @return {string}
4048
- */
4049
- proto.Spic.AssetProto.prototype.getUid = function() {
4050
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 4, ""));
4051
- };
4052
-
4053
-
4054
- /**
4055
- * @param {string} value
4056
- * @return {!proto.Spic.AssetProto} returns this
4057
- */
4058
- proto.Spic.AssetProto.prototype.setUid = function(value) {
4059
- return jspb.Message.setProto3StringField(this, 4, value);
4060
- };
4061
-
4062
-
4063
- /**
4064
- * optional int32 status = 5;
4065
- * @return {number}
4066
- */
4067
- proto.Spic.AssetProto.prototype.getStatus = function() {
4068
- return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 5, 0));
4069
- };
4070
-
4071
-
4072
- /**
4073
- * @param {number} value
4074
- * @return {!proto.Spic.AssetProto} returns this
4075
- */
4076
- proto.Spic.AssetProto.prototype.setStatus = function(value) {
4077
- return jspb.Message.setProto3IntField(this, 5, value);
4078
- };
4079
-
4080
-
4081
- /**
4082
- * optional google.protobuf.Timestamp last_status_update = 7;
4083
- * @return {?proto.google.protobuf.Timestamp}
4084
- */
4085
- proto.Spic.AssetProto.prototype.getLastStatusUpdate = function() {
4086
- return /** @type{?proto.google.protobuf.Timestamp} */ (
4087
- jspb.Message.getWrapperField(this, google_protobuf_timestamp_pb.Timestamp, 7));
4088
- };
4089
-
4090
-
4091
- /**
4092
- * @param {?proto.google.protobuf.Timestamp|undefined} value
4093
- * @return {!proto.Spic.AssetProto} returns this
4094
- */
4095
- proto.Spic.AssetProto.prototype.setLastStatusUpdate = function(value) {
4096
- return jspb.Message.setWrapperField(this, 7, value);
4097
- };
4098
-
4099
-
4100
- /**
4101
- * Clears the message field making it undefined.
4102
- * @return {!proto.Spic.AssetProto} returns this
4103
- */
4104
- proto.Spic.AssetProto.prototype.clearLastStatusUpdate = function() {
4105
- return this.setLastStatusUpdate(undefined);
4106
- };
4107
-
4108
-
4109
- /**
4110
- * Returns whether this field is set.
4111
- * @return {boolean}
4112
- */
4113
- proto.Spic.AssetProto.prototype.hasLastStatusUpdate = function() {
4114
- return jspb.Message.getField(this, 7) != null;
4115
- };
4116
-
4117
-
4118
- /**
4119
- * optional string group_id = 8;
4120
- * @return {string}
4121
- */
4122
- proto.Spic.AssetProto.prototype.getGroupId = function() {
4123
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 8, ""));
4124
- };
4125
-
4126
-
4127
- /**
4128
- * @param {string} value
4129
- * @return {!proto.Spic.AssetProto} returns this
4130
- */
4131
- proto.Spic.AssetProto.prototype.setGroupId = function(value) {
4132
- return jspb.Message.setProto3StringField(this, 8, value);
4133
- };
4134
-
4135
-
4136
- /**
4137
- * optional int32 client_id = 9;
4138
- * @return {number}
4139
- */
4140
- proto.Spic.AssetProto.prototype.getClientId = function() {
4141
- return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 9, 0));
4142
- };
4143
-
4144
-
4145
- /**
4146
- * @param {number} value
4147
- * @return {!proto.Spic.AssetProto} returns this
4148
- */
4149
- proto.Spic.AssetProto.prototype.setClientId = function(value) {
4150
- return jspb.Message.setProto3IntField(this, 9, value);
4151
- };
4152
-
4153
-
4154
- /**
4155
- * optional bool is_maintenance = 10;
4156
- * @return {boolean}
4157
- */
4158
- proto.Spic.AssetProto.prototype.getIsMaintenance = function() {
4159
- return /** @type {boolean} */ (jspb.Message.getBooleanFieldWithDefault(this, 10, false));
4160
- };
4161
-
4162
-
4163
- /**
4164
- * @param {boolean} value
4165
- * @return {!proto.Spic.AssetProto} returns this
4166
- */
4167
- proto.Spic.AssetProto.prototype.setIsMaintenance = function(value) {
4168
- return jspb.Message.setProto3BooleanField(this, 10, value);
4169
- };
4170
-
4171
-
4172
- /**
4173
- * optional string image_blob = 11;
4174
- * @return {string}
4175
- */
4176
- proto.Spic.AssetProto.prototype.getImageBlob = function() {
4177
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 11, ""));
4178
- };
4179
-
4180
-
4181
- /**
4182
- * @param {string} value
4183
- * @return {!proto.Spic.AssetProto} returns this
4184
- */
4185
- proto.Spic.AssetProto.prototype.setImageBlob = function(value) {
4186
- return jspb.Message.setProto3StringField(this, 11, value);
4187
- };
4188
-
4189
-
4190
- /**
4191
- * optional google.protobuf.Timestamp battery_placed = 12;
4192
- * @return {?proto.google.protobuf.Timestamp}
4193
- */
4194
- proto.Spic.AssetProto.prototype.getBatteryPlaced = function() {
4195
- return /** @type{?proto.google.protobuf.Timestamp} */ (
4196
- jspb.Message.getWrapperField(this, google_protobuf_timestamp_pb.Timestamp, 12));
4197
- };
4198
-
4199
-
4200
- /**
4201
- * @param {?proto.google.protobuf.Timestamp|undefined} value
4202
- * @return {!proto.Spic.AssetProto} returns this
4203
- */
4204
- proto.Spic.AssetProto.prototype.setBatteryPlaced = function(value) {
4205
- return jspb.Message.setWrapperField(this, 12, value);
4206
- };
4207
-
4208
-
4209
- /**
4210
- * Clears the message field making it undefined.
4211
- * @return {!proto.Spic.AssetProto} returns this
4212
- */
4213
- proto.Spic.AssetProto.prototype.clearBatteryPlaced = function() {
4214
- return this.setBatteryPlaced(undefined);
4215
- };
4216
-
4217
-
4218
- /**
4219
- * Returns whether this field is set.
4220
- * @return {boolean}
4221
- */
4222
- proto.Spic.AssetProto.prototype.hasBatteryPlaced = function() {
4223
- return jspb.Message.getField(this, 12) != null;
4224
- };
4225
-
4226
-
4227
- /**
4228
- * optional int32 battery_percentage = 13;
4229
- * @return {number}
4230
- */
4231
- proto.Spic.AssetProto.prototype.getBatteryPercentage = function() {
4232
- return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 13, 0));
4233
- };
4234
-
4235
-
4236
- /**
4237
- * @param {number} value
4238
- * @return {!proto.Spic.AssetProto} returns this
4239
- */
4240
- proto.Spic.AssetProto.prototype.setBatteryPercentage = function(value) {
4241
- return jspb.Message.setProto3IntField(this, 13, value);
4242
- };
4243
-
4244
-
4245
- /**
4246
- * optional int64 communication_time = 14;
4247
- * @return {number}
4248
- */
4249
- proto.Spic.AssetProto.prototype.getCommunicationTime = function() {
4250
- return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 14, 0));
4251
- };
4252
-
4253
-
4254
- /**
4255
- * @param {number} value
4256
- * @return {!proto.Spic.AssetProto} returns this
4257
- */
4258
- proto.Spic.AssetProto.prototype.setCommunicationTime = function(value) {
4259
- return jspb.Message.setProto3IntField(this, 14, value);
4260
- };
4261
-
4262
-
4263
- /**
4264
- * optional string last_config_string = 15;
4265
- * @return {string}
4266
- */
4267
- proto.Spic.AssetProto.prototype.getLastConfigString = function() {
4268
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 15, ""));
4269
- };
4270
-
4271
-
4272
- /**
4273
- * @param {string} value
4274
- * @return {!proto.Spic.AssetProto} returns this
4275
- */
4276
- proto.Spic.AssetProto.prototype.setLastConfigString = function(value) {
4277
- return jspb.Message.setProto3StringField(this, 15, value);
4278
- };
4279
-
4280
-
4281
- /**
4282
- * optional google.protobuf.Timestamp last_config_updated = 16;
4283
- * @return {?proto.google.protobuf.Timestamp}
4284
- */
4285
- proto.Spic.AssetProto.prototype.getLastConfigUpdated = function() {
4286
- return /** @type{?proto.google.protobuf.Timestamp} */ (
4287
- jspb.Message.getWrapperField(this, google_protobuf_timestamp_pb.Timestamp, 16));
4288
- };
4289
-
4290
-
4291
- /**
4292
- * @param {?proto.google.protobuf.Timestamp|undefined} value
4293
- * @return {!proto.Spic.AssetProto} returns this
4294
- */
4295
- proto.Spic.AssetProto.prototype.setLastConfigUpdated = function(value) {
4296
- return jspb.Message.setWrapperField(this, 16, value);
4297
- };
4298
-
4299
-
4300
- /**
4301
- * Clears the message field making it undefined.
4302
- * @return {!proto.Spic.AssetProto} returns this
4303
- */
4304
- proto.Spic.AssetProto.prototype.clearLastConfigUpdated = function() {
4305
- return this.setLastConfigUpdated(undefined);
4306
- };
4307
-
4308
-
4309
- /**
4310
- * Returns whether this field is set.
4311
- * @return {boolean}
4312
- */
4313
- proto.Spic.AssetProto.prototype.hasLastConfigUpdated = function() {
4314
- return jspb.Message.getField(this, 16) != null;
4315
- };
4316
-
4317
-
4318
- /**
4319
- * optional AssetType asset_type = 17;
4320
- * @return {!proto.Spic.AssetProto.AssetType}
4321
- */
4322
- proto.Spic.AssetProto.prototype.getAssetType = function() {
4323
- return /** @type {!proto.Spic.AssetProto.AssetType} */ (jspb.Message.getFieldWithDefault(this, 17, 0));
4324
- };
4325
-
4326
-
4327
- /**
4328
- * @param {!proto.Spic.AssetProto.AssetType} value
4329
- * @return {!proto.Spic.AssetProto} returns this
4330
- */
4331
- proto.Spic.AssetProto.prototype.setAssetType = function(value) {
4332
- return jspb.Message.setProto3EnumField(this, 17, value);
4333
- };
4334
-
4335
-
4336
- /**
4337
- * optional BatteryStatus battery_status = 18;
4338
- * @return {!proto.Spic.AssetProto.BatteryStatus}
4339
- */
4340
- proto.Spic.AssetProto.prototype.getBatteryStatus = function() {
4341
- return /** @type {!proto.Spic.AssetProto.BatteryStatus} */ (jspb.Message.getFieldWithDefault(this, 18, 0));
4342
- };
4343
-
4344
-
4345
- /**
4346
- * @param {!proto.Spic.AssetProto.BatteryStatus} value
4347
- * @return {!proto.Spic.AssetProto} returns this
4348
- */
4349
- proto.Spic.AssetProto.prototype.setBatteryStatus = function(value) {
4350
- return jspb.Message.setProto3EnumField(this, 18, value);
4351
- };
4352
-
4353
-
4354
- /**
4355
- * repeated ComponentState states = 19;
4356
- * @return {!Array<!proto.Spic.AssetProto.ComponentState>}
4357
- */
4358
- proto.Spic.AssetProto.prototype.getStatesList = function() {
4359
- return /** @type{!Array<!proto.Spic.AssetProto.ComponentState>} */ (
4360
- jspb.Message.getRepeatedWrapperField(this, proto.Spic.AssetProto.ComponentState, 19));
4361
- };
4362
-
4363
-
4364
- /**
4365
- * @param {!Array<!proto.Spic.AssetProto.ComponentState>} value
4366
- * @return {!proto.Spic.AssetProto} returns this
4367
- */
4368
- proto.Spic.AssetProto.prototype.setStatesList = function(value) {
4369
- return jspb.Message.setRepeatedWrapperField(this, 19, value);
4370
- };
4371
-
4372
-
4373
- /**
4374
- * @param {!proto.Spic.AssetProto.ComponentState=} opt_value
4375
- * @param {number=} opt_index
4376
- * @return {!proto.Spic.AssetProto.ComponentState}
4377
- */
4378
- proto.Spic.AssetProto.prototype.addStates = function(opt_value, opt_index) {
4379
- return jspb.Message.addToRepeatedWrapperField(this, 19, opt_value, proto.Spic.AssetProto.ComponentState, opt_index);
4380
- };
4381
-
4382
-
4383
- /**
4384
- * Clears the list making it empty but non-null.
4385
- * @return {!proto.Spic.AssetProto} returns this
4386
- */
4387
- proto.Spic.AssetProto.prototype.clearStatesList = function() {
4388
- return this.setStatesList([]);
4389
- };
4390
-
4391
-
4392
- /**
4393
- * optional DeviceType device_type = 20;
4394
- * @return {!proto.Spic.AssetProto.DeviceType}
4395
- */
4396
- proto.Spic.AssetProto.prototype.getDeviceType = function() {
4397
- return /** @type {!proto.Spic.AssetProto.DeviceType} */ (jspb.Message.getFieldWithDefault(this, 20, 0));
4398
- };
4399
-
4400
-
4401
- /**
4402
- * @param {!proto.Spic.AssetProto.DeviceType} value
4403
- * @return {!proto.Spic.AssetProto} returns this
4404
- */
4405
- proto.Spic.AssetProto.prototype.setDeviceType = function(value) {
4406
- return jspb.Message.setProto3EnumField(this, 20, value);
4407
- };
4408
-
4409
-
4410
-
4411
-
4412
-
4413
- if (jspb.Message.GENERATE_TO_OBJECT) {
4414
- /**
4415
- * Creates an object representation of this proto.
4416
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
4417
- * Optional fields that are not set will be set to undefined.
4418
- * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
4419
- * For the list of reserved names please see:
4420
- * net/proto2/compiler/js/internal/generator.cc#kKeyword.
4421
- * @param {boolean=} opt_includeInstance Deprecated. whether to include the
4422
- * JSPB instance for transitional soy proto support:
4423
- * http://goto/soy-param-migration
4424
- * @return {!Object}
4425
- */
4426
- proto.Spic.AssetWithLocation.prototype.toObject = function(opt_includeInstance) {
4427
- return proto.Spic.AssetWithLocation.toObject(opt_includeInstance, this);
4428
- };
4429
-
4430
-
4431
- /**
4432
- * Static version of the {@see toObject} method.
4433
- * @param {boolean|undefined} includeInstance Deprecated. Whether to include
4434
- * the JSPB instance for transitional soy proto support:
4435
- * http://goto/soy-param-migration
4436
- * @param {!proto.Spic.AssetWithLocation} msg The msg instance to transform.
4437
- * @return {!Object}
4438
- * @suppress {unusedLocalVariables} f is only used for nested messages
4439
- */
4440
- proto.Spic.AssetWithLocation.toObject = function(includeInstance, msg) {
4441
- var f, obj = {
4442
- asset: (f = msg.getAsset()) && proto.Spic.AssetProto.toObject(includeInstance, f),
4443
- location: (f = msg.getLocation()) && platform_location_pb.LocationProto.toObject(includeInstance, f),
4444
- openingRange: jspb.Message.getFieldWithDefault(msg, 3, 0)
4445
- };
4446
-
4447
- if (includeInstance) {
4448
- obj.$jspbMessageInstance = msg;
4449
- }
4450
- return obj;
4451
- };
4452
- }
4453
-
4454
-
4455
- /**
4456
- * Deserializes binary data (in protobuf wire format).
4457
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
4458
- * @return {!proto.Spic.AssetWithLocation}
4459
- */
4460
- proto.Spic.AssetWithLocation.deserializeBinary = function(bytes) {
4461
- var reader = new jspb.BinaryReader(bytes);
4462
- var msg = new proto.Spic.AssetWithLocation;
4463
- return proto.Spic.AssetWithLocation.deserializeBinaryFromReader(msg, reader);
4464
- };
4465
-
4466
-
4467
- /**
4468
- * Deserializes binary data (in protobuf wire format) from the
4469
- * given reader into the given message object.
4470
- * @param {!proto.Spic.AssetWithLocation} msg The message object to deserialize into.
4471
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
4472
- * @return {!proto.Spic.AssetWithLocation}
4473
- */
4474
- proto.Spic.AssetWithLocation.deserializeBinaryFromReader = function(msg, reader) {
4475
- while (reader.nextField()) {
4476
- if (reader.isEndGroup()) {
4477
- break;
4478
- }
4479
- var field = reader.getFieldNumber();
4480
- switch (field) {
4481
- case 1:
4482
- var value = new proto.Spic.AssetProto;
4483
- reader.readMessage(value,proto.Spic.AssetProto.deserializeBinaryFromReader);
4484
- msg.setAsset(value);
4485
- break;
4486
- case 2:
4487
- var value = new platform_location_pb.LocationProto;
4488
- reader.readMessage(value,platform_location_pb.LocationProto.deserializeBinaryFromReader);
4489
- msg.setLocation(value);
4490
- break;
4491
- case 3:
4492
- var value = /** @type {number} */ (reader.readInt32());
4493
- msg.setOpeningRange(value);
4494
- break;
4495
- default:
4496
- reader.skipField();
4497
- break;
4498
- }
4499
- }
4500
- return msg;
4501
- };
4502
-
4503
-
4504
- /**
4505
- * Serializes the message to binary data (in protobuf wire format).
4506
- * @return {!Uint8Array}
4507
- */
4508
- proto.Spic.AssetWithLocation.prototype.serializeBinary = function() {
4509
- var writer = new jspb.BinaryWriter();
4510
- proto.Spic.AssetWithLocation.serializeBinaryToWriter(this, writer);
4511
- return writer.getResultBuffer();
4512
- };
4513
-
4514
-
4515
- /**
4516
- * Serializes the given message to binary data (in protobuf wire
4517
- * format), writing to the given BinaryWriter.
4518
- * @param {!proto.Spic.AssetWithLocation} message
4519
- * @param {!jspb.BinaryWriter} writer
4520
- * @suppress {unusedLocalVariables} f is only used for nested messages
4521
- */
4522
- proto.Spic.AssetWithLocation.serializeBinaryToWriter = function(message, writer) {
4523
- var f = undefined;
4524
- f = message.getAsset();
4525
- if (f != null) {
4526
- writer.writeMessage(
4527
- 1,
4528
- f,
4529
- proto.Spic.AssetProto.serializeBinaryToWriter
4530
- );
4531
- }
4532
- f = message.getLocation();
4533
- if (f != null) {
4534
- writer.writeMessage(
4535
- 2,
4536
- f,
4537
- platform_location_pb.LocationProto.serializeBinaryToWriter
4538
- );
4539
- }
4540
- f = message.getOpeningRange();
4541
- if (f !== 0) {
4542
- writer.writeInt32(
4543
- 3,
4544
- f
4545
- );
4546
- }
4547
- };
4548
-
4549
-
4550
- /**
4551
- * optional AssetProto asset = 1;
4552
- * @return {?proto.Spic.AssetProto}
4553
- */
4554
- proto.Spic.AssetWithLocation.prototype.getAsset = function() {
4555
- return /** @type{?proto.Spic.AssetProto} */ (
4556
- jspb.Message.getWrapperField(this, proto.Spic.AssetProto, 1));
4557
- };
4558
-
4559
-
4560
- /**
4561
- * @param {?proto.Spic.AssetProto|undefined} value
4562
- * @return {!proto.Spic.AssetWithLocation} returns this
4563
- */
4564
- proto.Spic.AssetWithLocation.prototype.setAsset = function(value) {
4565
- return jspb.Message.setWrapperField(this, 1, value);
4566
- };
4567
-
4568
-
4569
- /**
4570
- * Clears the message field making it undefined.
4571
- * @return {!proto.Spic.AssetWithLocation} returns this
4572
- */
4573
- proto.Spic.AssetWithLocation.prototype.clearAsset = function() {
4574
- return this.setAsset(undefined);
4575
- };
4576
-
4577
-
4578
- /**
4579
- * Returns whether this field is set.
4580
- * @return {boolean}
4581
- */
4582
- proto.Spic.AssetWithLocation.prototype.hasAsset = function() {
4583
- return jspb.Message.getField(this, 1) != null;
4584
- };
4585
-
4586
-
4587
- /**
4588
- * optional Platform.LocationProto location = 2;
4589
- * @return {?proto.Platform.LocationProto}
4590
- */
4591
- proto.Spic.AssetWithLocation.prototype.getLocation = function() {
4592
- return /** @type{?proto.Platform.LocationProto} */ (
4593
- jspb.Message.getWrapperField(this, platform_location_pb.LocationProto, 2));
4594
- };
4595
-
4596
-
4597
- /**
4598
- * @param {?proto.Platform.LocationProto|undefined} value
4599
- * @return {!proto.Spic.AssetWithLocation} returns this
4600
- */
4601
- proto.Spic.AssetWithLocation.prototype.setLocation = function(value) {
4602
- return jspb.Message.setWrapperField(this, 2, value);
4603
- };
4604
-
4605
-
4606
- /**
4607
- * Clears the message field making it undefined.
4608
- * @return {!proto.Spic.AssetWithLocation} returns this
4609
- */
4610
- proto.Spic.AssetWithLocation.prototype.clearLocation = function() {
4611
- return this.setLocation(undefined);
4612
- };
4613
-
4614
-
4615
- /**
4616
- * Returns whether this field is set.
4617
- * @return {boolean}
4618
- */
4619
- proto.Spic.AssetWithLocation.prototype.hasLocation = function() {
4620
- return jspb.Message.getField(this, 2) != null;
4621
- };
4622
-
4623
-
4624
- /**
4625
- * optional int32 opening_range = 3;
4626
- * @return {number}
4627
- */
4628
- proto.Spic.AssetWithLocation.prototype.getOpeningRange = function() {
4629
- return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 3, 0));
4630
- };
4631
-
4632
-
4633
- /**
4634
- * @param {number} value
4635
- * @return {!proto.Spic.AssetWithLocation} returns this
4636
- */
4637
- proto.Spic.AssetWithLocation.prototype.setOpeningRange = function(value) {
4638
- return jspb.Message.setProto3IntField(this, 3, value);
4639
- };
4640
-
4641
-
4642
-
4643
-
4644
-
4645
- if (jspb.Message.GENERATE_TO_OBJECT) {
4646
- /**
4647
- * Creates an object representation of this proto.
4648
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
4649
- * Optional fields that are not set will be set to undefined.
4650
- * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
4651
- * For the list of reserved names please see:
4652
- * net/proto2/compiler/js/internal/generator.cc#kKeyword.
4653
- * @param {boolean=} opt_includeInstance Deprecated. whether to include the
4654
- * JSPB instance for transitional soy proto support:
4655
- * http://goto/soy-param-migration
4656
- * @return {!Object}
4657
- */
4658
- proto.Spic.AssetWithLocationAndDistance.prototype.toObject = function(opt_includeInstance) {
4659
- return proto.Spic.AssetWithLocationAndDistance.toObject(opt_includeInstance, this);
4660
- };
4661
-
4662
-
4663
- /**
4664
- * Static version of the {@see toObject} method.
4665
- * @param {boolean|undefined} includeInstance Deprecated. Whether to include
4666
- * the JSPB instance for transitional soy proto support:
4667
- * http://goto/soy-param-migration
4668
- * @param {!proto.Spic.AssetWithLocationAndDistance} msg The msg instance to transform.
4669
- * @return {!Object}
4670
- * @suppress {unusedLocalVariables} f is only used for nested messages
4671
- */
4672
- proto.Spic.AssetWithLocationAndDistance.toObject = function(includeInstance, msg) {
4673
- var f, obj = {
4674
- asset: (f = msg.getAsset()) && proto.Spic.AssetProto.toObject(includeInstance, f),
4675
- location: (f = msg.getLocation()) && platform_location_pb.LocationProto.toObject(includeInstance, f),
4676
- openingRange: jspb.Message.getFieldWithDefault(msg, 3, 0),
4677
- distance: jspb.Message.getFieldWithDefault(msg, 4, 0)
4678
- };
4679
-
4680
- if (includeInstance) {
4681
- obj.$jspbMessageInstance = msg;
4682
- }
4683
- return obj;
4684
- };
4685
- }
4686
-
4687
-
4688
- /**
4689
- * Deserializes binary data (in protobuf wire format).
4690
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
4691
- * @return {!proto.Spic.AssetWithLocationAndDistance}
4692
- */
4693
- proto.Spic.AssetWithLocationAndDistance.deserializeBinary = function(bytes) {
4694
- var reader = new jspb.BinaryReader(bytes);
4695
- var msg = new proto.Spic.AssetWithLocationAndDistance;
4696
- return proto.Spic.AssetWithLocationAndDistance.deserializeBinaryFromReader(msg, reader);
4697
- };
4698
-
4699
-
4700
- /**
4701
- * Deserializes binary data (in protobuf wire format) from the
4702
- * given reader into the given message object.
4703
- * @param {!proto.Spic.AssetWithLocationAndDistance} msg The message object to deserialize into.
4704
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
4705
- * @return {!proto.Spic.AssetWithLocationAndDistance}
4706
- */
4707
- proto.Spic.AssetWithLocationAndDistance.deserializeBinaryFromReader = function(msg, reader) {
4708
- while (reader.nextField()) {
4709
- if (reader.isEndGroup()) {
4710
- break;
4711
- }
4712
- var field = reader.getFieldNumber();
4713
- switch (field) {
4714
- case 1:
4715
- var value = new proto.Spic.AssetProto;
4716
- reader.readMessage(value,proto.Spic.AssetProto.deserializeBinaryFromReader);
4717
- msg.setAsset(value);
4718
- break;
4719
- case 2:
4720
- var value = new platform_location_pb.LocationProto;
4721
- reader.readMessage(value,platform_location_pb.LocationProto.deserializeBinaryFromReader);
4722
- msg.setLocation(value);
4723
- break;
4724
- case 3:
4725
- var value = /** @type {number} */ (reader.readInt32());
4726
- msg.setOpeningRange(value);
4727
- break;
4728
- case 4:
4729
- var value = /** @type {number} */ (reader.readInt32());
4730
- msg.setDistance(value);
4731
- break;
4732
- default:
4733
- reader.skipField();
4734
- break;
4735
- }
4736
- }
4737
- return msg;
4738
- };
4739
-
4740
-
4741
- /**
4742
- * Serializes the message to binary data (in protobuf wire format).
4743
- * @return {!Uint8Array}
4744
- */
4745
- proto.Spic.AssetWithLocationAndDistance.prototype.serializeBinary = function() {
4746
- var writer = new jspb.BinaryWriter();
4747
- proto.Spic.AssetWithLocationAndDistance.serializeBinaryToWriter(this, writer);
4748
- return writer.getResultBuffer();
4749
- };
4750
-
4751
-
4752
- /**
4753
- * Serializes the given message to binary data (in protobuf wire
4754
- * format), writing to the given BinaryWriter.
4755
- * @param {!proto.Spic.AssetWithLocationAndDistance} message
4756
- * @param {!jspb.BinaryWriter} writer
4757
- * @suppress {unusedLocalVariables} f is only used for nested messages
4758
- */
4759
- proto.Spic.AssetWithLocationAndDistance.serializeBinaryToWriter = function(message, writer) {
4760
- var f = undefined;
4761
- f = message.getAsset();
4762
- if (f != null) {
4763
- writer.writeMessage(
4764
- 1,
4765
- f,
4766
- proto.Spic.AssetProto.serializeBinaryToWriter
4767
- );
4768
- }
4769
- f = message.getLocation();
4770
- if (f != null) {
4771
- writer.writeMessage(
4772
- 2,
4773
- f,
4774
- platform_location_pb.LocationProto.serializeBinaryToWriter
4775
- );
4776
- }
4777
- f = message.getOpeningRange();
4778
- if (f !== 0) {
4779
- writer.writeInt32(
4780
- 3,
4781
- f
4782
- );
4783
- }
4784
- f = message.getDistance();
4785
- if (f !== 0) {
4786
- writer.writeInt32(
4787
- 4,
4788
- f
4789
- );
4790
- }
4791
- };
4792
-
4793
-
4794
- /**
4795
- * optional AssetProto asset = 1;
4796
- * @return {?proto.Spic.AssetProto}
4797
- */
4798
- proto.Spic.AssetWithLocationAndDistance.prototype.getAsset = function() {
4799
- return /** @type{?proto.Spic.AssetProto} */ (
4800
- jspb.Message.getWrapperField(this, proto.Spic.AssetProto, 1));
4801
- };
4802
-
4803
-
4804
- /**
4805
- * @param {?proto.Spic.AssetProto|undefined} value
4806
- * @return {!proto.Spic.AssetWithLocationAndDistance} returns this
4807
- */
4808
- proto.Spic.AssetWithLocationAndDistance.prototype.setAsset = function(value) {
4809
- return jspb.Message.setWrapperField(this, 1, value);
4810
- };
4811
-
4812
-
4813
- /**
4814
- * Clears the message field making it undefined.
4815
- * @return {!proto.Spic.AssetWithLocationAndDistance} returns this
4816
- */
4817
- proto.Spic.AssetWithLocationAndDistance.prototype.clearAsset = function() {
4818
- return this.setAsset(undefined);
4819
- };
4820
-
4821
-
4822
- /**
4823
- * Returns whether this field is set.
4824
- * @return {boolean}
4825
- */
4826
- proto.Spic.AssetWithLocationAndDistance.prototype.hasAsset = function() {
4827
- return jspb.Message.getField(this, 1) != null;
4828
- };
4829
-
4830
-
4831
- /**
4832
- * optional Platform.LocationProto location = 2;
4833
- * @return {?proto.Platform.LocationProto}
4834
- */
4835
- proto.Spic.AssetWithLocationAndDistance.prototype.getLocation = function() {
4836
- return /** @type{?proto.Platform.LocationProto} */ (
4837
- jspb.Message.getWrapperField(this, platform_location_pb.LocationProto, 2));
4838
- };
4839
-
4840
-
4841
- /**
4842
- * @param {?proto.Platform.LocationProto|undefined} value
4843
- * @return {!proto.Spic.AssetWithLocationAndDistance} returns this
4844
- */
4845
- proto.Spic.AssetWithLocationAndDistance.prototype.setLocation = function(value) {
4846
- return jspb.Message.setWrapperField(this, 2, value);
4847
- };
4848
-
4849
-
4850
- /**
4851
- * Clears the message field making it undefined.
4852
- * @return {!proto.Spic.AssetWithLocationAndDistance} returns this
4853
- */
4854
- proto.Spic.AssetWithLocationAndDistance.prototype.clearLocation = function() {
4855
- return this.setLocation(undefined);
4856
- };
4857
-
4858
-
4859
- /**
4860
- * Returns whether this field is set.
4861
- * @return {boolean}
4862
- */
4863
- proto.Spic.AssetWithLocationAndDistance.prototype.hasLocation = function() {
4864
- return jspb.Message.getField(this, 2) != null;
4865
- };
4866
-
4867
-
4868
- /**
4869
- * optional int32 opening_range = 3;
4870
- * @return {number}
4871
- */
4872
- proto.Spic.AssetWithLocationAndDistance.prototype.getOpeningRange = function() {
4873
- return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 3, 0));
4874
- };
4875
-
4876
-
4877
- /**
4878
- * @param {number} value
4879
- * @return {!proto.Spic.AssetWithLocationAndDistance} returns this
4880
- */
4881
- proto.Spic.AssetWithLocationAndDistance.prototype.setOpeningRange = function(value) {
4882
- return jspb.Message.setProto3IntField(this, 3, value);
4883
- };
4884
-
4885
-
4886
- /**
4887
- * optional int32 distance = 4;
4888
- * @return {number}
4889
- */
4890
- proto.Spic.AssetWithLocationAndDistance.prototype.getDistance = function() {
4891
- return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 4, 0));
4892
- };
4893
-
4894
-
4895
- /**
4896
- * @param {number} value
4897
- * @return {!proto.Spic.AssetWithLocationAndDistance} returns this
4898
- */
4899
- proto.Spic.AssetWithLocationAndDistance.prototype.setDistance = function(value) {
4900
- return jspb.Message.setProto3IntField(this, 4, value);
4901
- };
4902
-
4903
-
4904
- /**
4905
- * @enum {number}
4906
- */
4907
- proto.Spic.ComponentIdentifier = {
4908
- ENCLOSURE_TEMPERATURE: 0,
4909
- ENCLOSURE_HUMIDITY: 1,
4910
- ENCLOSURE_TILT: 2,
4911
- DEVICE_UID: 3,
4912
- COMMUNICATION_PACKET_NUMBER: 4,
4913
- MAINBOARD_FIRMWARE_CRC: 5,
4914
- MAINBOARD_BATTERY_VOLTAGE: 6,
4915
- LTE_COMMUNICATION_TIME: 7,
4916
- LTE_SIGNAL_STRENGTH: 8,
4917
- LTE_NETWORK_STRING: 9,
4918
- LTE_ICCID: 10,
4919
- LTE_IMEI: 11,
4920
- NTC_CRITICAL_TEMPERATURE_ALARM: 12,
4921
- NTC_HIGH_TEMPERATURE_ALARM: 13,
4922
- CABINET_MAIN_DOOR: 14,
4923
- CABINET_MAIN_DOOR_HANDLE: 15,
4924
- CABINET_MAIN_DOOR_LOCK: 16,
4925
- EXT_ALARM_1: 31,
4926
- EXT_ALARM_2: 32,
4927
- EXT_ALARM_3: 33,
4928
- MANHOLE_COVER: 40,
4929
- MANHOLE_CLOSURE_OPEN: 41,
4930
- MANHOLE_COVER_SENSOR: 42,
4931
- HEARTBEAT_TIMEOUT: 50,
4932
- MAINBOARD_BATTERY_PERCENTAGE: 51
4933
- };
4934
-
4935
- goog.object.extend(exports, proto.Spic);