@kenji71089/evaluation 0.0.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 (209) hide show
  1. package/.release-please-manifest.json +3 -0
  2. package/README.md +9 -0
  3. package/eslint.config.mjs +27 -0
  4. package/lib/clauseEvaluator.d.ts +22 -0
  5. package/lib/clauseEvaluator.js +299 -0
  6. package/lib/clauseEvaluator.mjs +214 -0
  7. package/lib/dependencyEvaluator.d.ts +6 -0
  8. package/lib/dependencyEvaluator.js +46 -0
  9. package/lib/dependencyEvaluator.mjs +19 -0
  10. package/lib/errors.d.ts +9 -0
  11. package/lib/errors.js +15 -0
  12. package/lib/errors.mjs +12 -0
  13. package/lib/evaluation.d.ts +25 -0
  14. package/lib/evaluation.js +503 -0
  15. package/lib/evaluation.mjs +328 -0
  16. package/lib/google/api/annotations_pb.d.ts +8 -0
  17. package/lib/google/api/annotations_pb.js +40 -0
  18. package/lib/google/api/annotations_pb.mjs +54 -0
  19. package/lib/google/api/annotations_pb_service.d.ts +3 -0
  20. package/lib/google/api/annotations_pb_service.js +3 -0
  21. package/lib/google/api/annotations_pb_service.mjs +3 -0
  22. package/lib/google/api/http_pb.d.ts +132 -0
  23. package/lib/google/api/http_pb.js +860 -0
  24. package/lib/google/api/http_pb.mjs +982 -0
  25. package/lib/google/api/http_pb_service.d.ts +3 -0
  26. package/lib/google/api/http_pb_service.js +3 -0
  27. package/lib/google/api/http_pb_service.mjs +3 -0
  28. package/lib/google/rpc/code_pb.d.ts +26 -0
  29. package/lib/google/rpc/code_pb.js +44 -0
  30. package/lib/google/rpc/code_pb.mjs +48 -0
  31. package/lib/google/rpc/code_pb_service.d.ts +3 -0
  32. package/lib/google/rpc/code_pb_service.js +3 -0
  33. package/lib/google/rpc/code_pb_service.mjs +3 -0
  34. package/lib/google/rpc/error_details_pb.d.ts +322 -0
  35. package/lib/google/rpc/error_details_pb.js +2220 -0
  36. package/lib/google/rpc/error_details_pb.mjs +2499 -0
  37. package/lib/google/rpc/error_details_pb_service.d.ts +3 -0
  38. package/lib/google/rpc/error_details_pb_service.js +3 -0
  39. package/lib/google/rpc/error_details_pb_service.mjs +3 -0
  40. package/lib/google/rpc/status_pb.d.ts +36 -0
  41. package/lib/google/rpc/status_pb.js +235 -0
  42. package/lib/google/rpc/status_pb.mjs +268 -0
  43. package/lib/google/rpc/status_pb_service.d.ts +3 -0
  44. package/lib/google/rpc/status_pb_service.js +3 -0
  45. package/lib/google/rpc/status_pb_service.mjs +3 -0
  46. package/lib/index.d.ts +20 -0
  47. package/lib/index.js +199 -0
  48. package/lib/index.mjs +46 -0
  49. package/lib/modelFactory.d.ts +64 -0
  50. package/lib/modelFactory.js +206 -0
  51. package/lib/modelFactory.mjs +176 -0
  52. package/lib/proto/event/client/event_pb.d.ts +761 -0
  53. package/lib/proto/event/client/event_pb.js +5195 -0
  54. package/lib/proto/event/client/event_pb.mjs +5865 -0
  55. package/lib/proto/event/client/event_pb_service.d.ts +3 -0
  56. package/lib/proto/event/client/event_pb_service.js +3 -0
  57. package/lib/proto/event/client/event_pb_service.mjs +3 -0
  58. package/lib/proto/event/domain/event_pb.d.ts +4518 -0
  59. package/lib/proto/event/domain/event_pb.js +10834 -0
  60. package/lib/proto/event/domain/event_pb.mjs +33315 -0
  61. package/lib/proto/event/domain/event_pb_service.d.ts +3 -0
  62. package/lib/proto/event/domain/event_pb_service.js +3 -0
  63. package/lib/proto/event/domain/event_pb_service.mjs +3 -0
  64. package/lib/proto/event/domain/localized_message_pb.d.ts +29 -0
  65. package/lib/proto/event/domain/localized_message_pb.js +183 -0
  66. package/lib/proto/event/domain/localized_message_pb.mjs +206 -0
  67. package/lib/proto/event/domain/localized_message_pb_service.d.ts +3 -0
  68. package/lib/proto/event/domain/localized_message_pb_service.js +3 -0
  69. package/lib/proto/event/domain/localized_message_pb_service.mjs +3 -0
  70. package/lib/proto/event/service/feature_pb.d.ts +44 -0
  71. package/lib/proto/event/service/feature_pb.js +277 -0
  72. package/lib/proto/event/service/feature_pb.mjs +319 -0
  73. package/lib/proto/event/service/feature_pb_service.d.ts +3 -0
  74. package/lib/proto/event/service/feature_pb_service.js +3 -0
  75. package/lib/proto/event/service/feature_pb_service.mjs +3 -0
  76. package/lib/proto/event/service/segment_pb.d.ts +51 -0
  77. package/lib/proto/event/service/segment_pb.js +324 -0
  78. package/lib/proto/event/service/segment_pb.mjs +375 -0
  79. package/lib/proto/event/service/segment_pb_service.d.ts +3 -0
  80. package/lib/proto/event/service/segment_pb_service.js +3 -0
  81. package/lib/proto/event/service/segment_pb_service.mjs +3 -0
  82. package/lib/proto/event/service/user_pb.d.ts +49 -0
  83. package/lib/proto/event/service/user_pb.js +315 -0
  84. package/lib/proto/event/service/user_pb.mjs +362 -0
  85. package/lib/proto/event/service/user_pb_service.d.ts +3 -0
  86. package/lib/proto/event/service/user_pb_service.js +3 -0
  87. package/lib/proto/event/service/user_pb_service.mjs +3 -0
  88. package/lib/proto/feature/clause_pb.d.ts +57 -0
  89. package/lib/proto/feature/clause_pb.js +277 -0
  90. package/lib/proto/feature/clause_pb.mjs +312 -0
  91. package/lib/proto/feature/clause_pb_service.d.ts +3 -0
  92. package/lib/proto/feature/clause_pb_service.js +3 -0
  93. package/lib/proto/feature/clause_pb_service.mjs +3 -0
  94. package/lib/proto/feature/command_pb.d.ts +1213 -0
  95. package/lib/proto/feature/command_pb.js +8260 -0
  96. package/lib/proto/feature/command_pb.mjs +9275 -0
  97. package/lib/proto/feature/command_pb_service.d.ts +3 -0
  98. package/lib/proto/feature/command_pb_service.js +3 -0
  99. package/lib/proto/feature/command_pb_service.mjs +3 -0
  100. package/lib/proto/feature/evaluation_pb.d.ts +111 -0
  101. package/lib/proto/feature/evaluation_pb.js +685 -0
  102. package/lib/proto/feature/evaluation_pb.mjs +793 -0
  103. package/lib/proto/feature/evaluation_pb_service.d.ts +3 -0
  104. package/lib/proto/feature/evaluation_pb_service.js +3 -0
  105. package/lib/proto/feature/evaluation_pb_service.mjs +3 -0
  106. package/lib/proto/feature/feature_last_used_info_pb.d.ts +45 -0
  107. package/lib/proto/feature/feature_last_used_info_pb.js +283 -0
  108. package/lib/proto/feature/feature_last_used_info_pb.mjs +326 -0
  109. package/lib/proto/feature/feature_last_used_info_pb_service.d.ts +3 -0
  110. package/lib/proto/feature/feature_last_used_info_pb_service.js +3 -0
  111. package/lib/proto/feature/feature_last_used_info_pb_service.mjs +3 -0
  112. package/lib/proto/feature/feature_pb.d.ts +192 -0
  113. package/lib/proto/feature/feature_pb.js +1210 -0
  114. package/lib/proto/feature/feature_pb.mjs +1413 -0
  115. package/lib/proto/feature/feature_pb_service.d.ts +3 -0
  116. package/lib/proto/feature/feature_pb_service.js +3 -0
  117. package/lib/proto/feature/feature_pb_service.mjs +3 -0
  118. package/lib/proto/feature/flag_trigger_pb.d.ts +84 -0
  119. package/lib/proto/feature/flag_trigger_pb.js +452 -0
  120. package/lib/proto/feature/flag_trigger_pb.mjs +525 -0
  121. package/lib/proto/feature/flag_trigger_pb_service.d.ts +3 -0
  122. package/lib/proto/feature/flag_trigger_pb_service.js +3 -0
  123. package/lib/proto/feature/flag_trigger_pb_service.mjs +3 -0
  124. package/lib/proto/feature/prerequisite_pb.d.ts +29 -0
  125. package/lib/proto/feature/prerequisite_pb.js +183 -0
  126. package/lib/proto/feature/prerequisite_pb.mjs +206 -0
  127. package/lib/proto/feature/prerequisite_pb_service.d.ts +3 -0
  128. package/lib/proto/feature/prerequisite_pb_service.js +3 -0
  129. package/lib/proto/feature/prerequisite_pb_service.mjs +3 -0
  130. package/lib/proto/feature/reason_pb.d.ts +40 -0
  131. package/lib/proto/feature/reason_pb.js +196 -0
  132. package/lib/proto/feature/reason_pb.mjs +219 -0
  133. package/lib/proto/feature/reason_pb_service.d.ts +3 -0
  134. package/lib/proto/feature/reason_pb_service.js +3 -0
  135. package/lib/proto/feature/reason_pb_service.mjs +3 -0
  136. package/lib/proto/feature/rule_pb.d.ts +39 -0
  137. package/lib/proto/feature/rule_pb.js +254 -0
  138. package/lib/proto/feature/rule_pb.mjs +291 -0
  139. package/lib/proto/feature/rule_pb_service.d.ts +3 -0
  140. package/lib/proto/feature/rule_pb_service.js +3 -0
  141. package/lib/proto/feature/rule_pb_service.mjs +3 -0
  142. package/lib/proto/feature/segment_pb.d.ts +161 -0
  143. package/lib/proto/feature/segment_pb.js +974 -0
  144. package/lib/proto/feature/segment_pb.mjs +1127 -0
  145. package/lib/proto/feature/segment_pb_service.d.ts +3 -0
  146. package/lib/proto/feature/segment_pb_service.js +3 -0
  147. package/lib/proto/feature/segment_pb_service.mjs +3 -0
  148. package/lib/proto/feature/service_pb.d.ts +2158 -0
  149. package/lib/proto/feature/service_pb.js +5363 -0
  150. package/lib/proto/feature/service_pb.mjs +16348 -0
  151. package/lib/proto/feature/service_pb_service.d.ts +747 -0
  152. package/lib/proto/feature/service_pb_service.js +1424 -0
  153. package/lib/proto/feature/service_pb_service.mjs +1501 -0
  154. package/lib/proto/feature/strategy_pb.d.ts +110 -0
  155. package/lib/proto/feature/strategy_pb.js +712 -0
  156. package/lib/proto/feature/strategy_pb.mjs +803 -0
  157. package/lib/proto/feature/strategy_pb_service.d.ts +3 -0
  158. package/lib/proto/feature/strategy_pb_service.js +3 -0
  159. package/lib/proto/feature/strategy_pb_service.mjs +3 -0
  160. package/lib/proto/feature/target_pb.d.ts +31 -0
  161. package/lib/proto/feature/target_pb.js +207 -0
  162. package/lib/proto/feature/target_pb.mjs +232 -0
  163. package/lib/proto/feature/target_pb_service.d.ts +3 -0
  164. package/lib/proto/feature/target_pb_service.js +3 -0
  165. package/lib/proto/feature/target_pb_service.mjs +3 -0
  166. package/lib/proto/feature/variation_pb.d.ts +37 -0
  167. package/lib/proto/feature/variation_pb.js +233 -0
  168. package/lib/proto/feature/variation_pb.mjs +266 -0
  169. package/lib/proto/feature/variation_pb_service.d.ts +3 -0
  170. package/lib/proto/feature/variation_pb_service.js +3 -0
  171. package/lib/proto/feature/variation_pb_service.mjs +3 -0
  172. package/lib/proto/gateway/service_pb.d.ts +772 -0
  173. package/lib/proto/gateway/service_pb.js +5249 -0
  174. package/lib/proto/gateway/service_pb.mjs +6001 -0
  175. package/lib/proto/gateway/service_pb_service.d.ts +253 -0
  176. package/lib/proto/gateway/service_pb_service.js +436 -0
  177. package/lib/proto/gateway/service_pb_service.mjs +461 -0
  178. package/lib/proto/user/user_pb.d.ts +58 -0
  179. package/lib/proto/user/user_pb.js +410 -0
  180. package/lib/proto/user/user_pb.mjs +460 -0
  181. package/lib/proto/user/user_pb_service.d.ts +3 -0
  182. package/lib/proto/user/user_pb_service.js +3 -0
  183. package/lib/proto/user/user_pb_service.mjs +3 -0
  184. package/lib/protoc-gen-openapiv2/options/annotations_pb.d.ts +16 -0
  185. package/lib/protoc-gen-openapiv2/options/annotations_pb.js +100 -0
  186. package/lib/protoc-gen-openapiv2/options/annotations_pb.mjs +158 -0
  187. package/lib/protoc-gen-openapiv2/options/annotations_pb_service.d.ts +3 -0
  188. package/lib/protoc-gen-openapiv2/options/annotations_pb_service.js +3 -0
  189. package/lib/protoc-gen-openapiv2/options/annotations_pb_service.mjs +3 -0
  190. package/lib/protoc-gen-openapiv2/options/openapiv2_pb.d.ts +834 -0
  191. package/lib/protoc-gen-openapiv2/options/openapiv2_pb.js +5456 -0
  192. package/lib/protoc-gen-openapiv2/options/openapiv2_pb.mjs +6256 -0
  193. package/lib/protoc-gen-openapiv2/options/openapiv2_pb_service.d.ts +3 -0
  194. package/lib/protoc-gen-openapiv2/options/openapiv2_pb_service.js +3 -0
  195. package/lib/protoc-gen-openapiv2/options/openapiv2_pb_service.mjs +3 -0
  196. package/lib/ruleEvaluator.d.ts +13 -0
  197. package/lib/ruleEvaluator.js +80 -0
  198. package/lib/ruleEvaluator.mjs +41 -0
  199. package/lib/segmentEvaluator.d.ts +7 -0
  200. package/lib/segmentEvaluator.js +74 -0
  201. package/lib/segmentEvaluator.mjs +34 -0
  202. package/lib/strategyEvaluator.d.ts +10 -0
  203. package/lib/strategyEvaluator.js +135 -0
  204. package/lib/strategyEvaluator.mjs +83 -0
  205. package/lib/userEvaluation.d.ts +8 -0
  206. package/lib/userEvaluation.js +70 -0
  207. package/lib/userEvaluation.mjs +60 -0
  208. package/package.json +46 -0
  209. package/release-please-config.json +22 -0
@@ -0,0 +1,1210 @@
1
+ "use strict";
2
+
3
+ // source: proto/feature/feature.proto
4
+ /**
5
+ * @fileoverview
6
+ * @enhanceable
7
+ * @suppress {missingRequire} reports error on implicit type usages.
8
+ * @suppress {messageConventions} JS Compiler reports an error if a variable or
9
+ * field starts with 'MSG_' and isn't a translatable message.
10
+ * @public
11
+ */
12
+ // GENERATED CODE -- DO NOT EDIT!
13
+
14
+ // @ts-nocheck
15
+
16
+ var jspb = require('google-protobuf');
17
+ var goog = jspb;
18
+ var global = typeof globalThis !== 'undefined' && globalThis || typeof window !== 'undefined' && window || typeof global !== 'undefined' && global || typeof self !== 'undefined' && self || function () {
19
+ return this;
20
+ }.call(null) || Function('return this')();
21
+ var proto_feature_rule_pb = require('../../proto/feature/rule_pb.js');
22
+ goog.object.extend(proto, proto_feature_rule_pb);
23
+ var proto_feature_target_pb = require('../../proto/feature/target_pb.js');
24
+ goog.object.extend(proto, proto_feature_target_pb);
25
+ var proto_feature_variation_pb = require('../../proto/feature/variation_pb.js');
26
+ goog.object.extend(proto, proto_feature_variation_pb);
27
+ var proto_feature_strategy_pb = require('../../proto/feature/strategy_pb.js');
28
+ goog.object.extend(proto, proto_feature_strategy_pb);
29
+ var proto_feature_feature_last_used_info_pb = require('../../proto/feature/feature_last_used_info_pb.js');
30
+ goog.object.extend(proto, proto_feature_feature_last_used_info_pb);
31
+ var proto_feature_prerequisite_pb = require('../../proto/feature/prerequisite_pb.js');
32
+ goog.object.extend(proto, proto_feature_prerequisite_pb);
33
+ goog.exportSymbol('proto.bucketeer.feature.Feature', null, global);
34
+ goog.exportSymbol('proto.bucketeer.feature.Feature.VariationType', null, global);
35
+ goog.exportSymbol('proto.bucketeer.feature.Features', null, global);
36
+ goog.exportSymbol('proto.bucketeer.feature.Tag', null, global);
37
+ /**
38
+ * Generated by JsPbCodeGenerator.
39
+ * @param {Array=} opt_data Optional initial data array, typically from a
40
+ * server response, or constructed directly in Javascript. The array is used
41
+ * in place and becomes part of the constructed object. It is not cloned.
42
+ * If no data is provided, the constructed object will be empty, but still
43
+ * valid.
44
+ * @extends {jspb.Message}
45
+ * @constructor
46
+ */
47
+ proto.bucketeer.feature.Feature = function (opt_data) {
48
+ jspb.Message.initialize(this, opt_data, 0, -1, proto.bucketeer.feature.Feature.repeatedFields_, null);
49
+ };
50
+ goog.inherits(proto.bucketeer.feature.Feature, jspb.Message);
51
+ if (goog.DEBUG && !COMPILED) {
52
+ /**
53
+ * @public
54
+ * @override
55
+ */
56
+ proto.bucketeer.feature.Feature.displayName = 'proto.bucketeer.feature.Feature';
57
+ }
58
+ /**
59
+ * Generated by JsPbCodeGenerator.
60
+ * @param {Array=} opt_data Optional initial data array, typically from a
61
+ * server response, or constructed directly in Javascript. The array is used
62
+ * in place and becomes part of the constructed object. It is not cloned.
63
+ * If no data is provided, the constructed object will be empty, but still
64
+ * valid.
65
+ * @extends {jspb.Message}
66
+ * @constructor
67
+ */
68
+ proto.bucketeer.feature.Features = function (opt_data) {
69
+ jspb.Message.initialize(this, opt_data, 0, -1, proto.bucketeer.feature.Features.repeatedFields_, null);
70
+ };
71
+ goog.inherits(proto.bucketeer.feature.Features, jspb.Message);
72
+ if (goog.DEBUG && !COMPILED) {
73
+ /**
74
+ * @public
75
+ * @override
76
+ */
77
+ proto.bucketeer.feature.Features.displayName = 'proto.bucketeer.feature.Features';
78
+ }
79
+ /**
80
+ * Generated by JsPbCodeGenerator.
81
+ * @param {Array=} opt_data Optional initial data array, typically from a
82
+ * server response, or constructed directly in Javascript. The array is used
83
+ * in place and becomes part of the constructed object. It is not cloned.
84
+ * If no data is provided, the constructed object will be empty, but still
85
+ * valid.
86
+ * @extends {jspb.Message}
87
+ * @constructor
88
+ */
89
+ proto.bucketeer.feature.Tag = function (opt_data) {
90
+ jspb.Message.initialize(this, opt_data, 0, -1, null, null);
91
+ };
92
+ goog.inherits(proto.bucketeer.feature.Tag, jspb.Message);
93
+ if (goog.DEBUG && !COMPILED) {
94
+ /**
95
+ * @public
96
+ * @override
97
+ */
98
+ proto.bucketeer.feature.Tag.displayName = 'proto.bucketeer.feature.Tag';
99
+ }
100
+
101
+ /**
102
+ * List of repeated fields within this message type.
103
+ * @private {!Array<number>}
104
+ * @const
105
+ */
106
+ proto.bucketeer.feature.Feature.repeatedFields_ = [11, 12, 13, 16, 21];
107
+ if (jspb.Message.GENERATE_TO_OBJECT) {
108
+ /**
109
+ * Creates an object representation of this proto.
110
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
111
+ * Optional fields that are not set will be set to undefined.
112
+ * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
113
+ * For the list of reserved names please see:
114
+ * net/proto2/compiler/js/internal/generator.cc#kKeyword.
115
+ * @param {boolean=} opt_includeInstance Deprecated. whether to include the
116
+ * JSPB instance for transitional soy proto support:
117
+ * http://goto/soy-param-migration
118
+ * @return {!Object}
119
+ */
120
+ proto.bucketeer.feature.Feature.prototype.toObject = function (opt_includeInstance) {
121
+ return proto.bucketeer.feature.Feature.toObject(opt_includeInstance, this);
122
+ };
123
+
124
+ /**
125
+ * Static version of the {@see toObject} method.
126
+ * @param {boolean|undefined} includeInstance Deprecated. Whether to include
127
+ * the JSPB instance for transitional soy proto support:
128
+ * http://goto/soy-param-migration
129
+ * @param {!proto.bucketeer.feature.Feature} msg The msg instance to transform.
130
+ * @return {!Object}
131
+ * @suppress {unusedLocalVariables} f is only used for nested messages
132
+ */
133
+ proto.bucketeer.feature.Feature.toObject = function (includeInstance, msg) {
134
+ var f,
135
+ obj = {
136
+ id: jspb.Message.getFieldWithDefault(msg, 1, ""),
137
+ name: jspb.Message.getFieldWithDefault(msg, 2, ""),
138
+ description: jspb.Message.getFieldWithDefault(msg, 3, ""),
139
+ enabled: jspb.Message.getBooleanFieldWithDefault(msg, 4, false),
140
+ deleted: jspb.Message.getBooleanFieldWithDefault(msg, 5, false),
141
+ evaluationUndelayable: jspb.Message.getBooleanFieldWithDefault(msg, 6, false),
142
+ ttl: jspb.Message.getFieldWithDefault(msg, 7, 0),
143
+ version: jspb.Message.getFieldWithDefault(msg, 8, 0),
144
+ createdAt: jspb.Message.getFieldWithDefault(msg, 9, 0),
145
+ updatedAt: jspb.Message.getFieldWithDefault(msg, 10, 0),
146
+ variationsList: jspb.Message.toObjectList(msg.getVariationsList(), proto_feature_variation_pb.Variation.toObject, includeInstance),
147
+ targetsList: jspb.Message.toObjectList(msg.getTargetsList(), proto_feature_target_pb.Target.toObject, includeInstance),
148
+ rulesList: jspb.Message.toObjectList(msg.getRulesList(), proto_feature_rule_pb.Rule.toObject, includeInstance),
149
+ defaultStrategy: (f = msg.getDefaultStrategy()) && proto_feature_strategy_pb.Strategy.toObject(includeInstance, f),
150
+ offVariation: jspb.Message.getFieldWithDefault(msg, 15, ""),
151
+ tagsList: (f = jspb.Message.getRepeatedField(msg, 16)) == null ? undefined : f,
152
+ lastUsedInfo: (f = msg.getLastUsedInfo()) && proto_feature_feature_last_used_info_pb.FeatureLastUsedInfo.toObject(includeInstance, f),
153
+ maintainer: jspb.Message.getFieldWithDefault(msg, 18, ""),
154
+ variationType: jspb.Message.getFieldWithDefault(msg, 19, 0),
155
+ archived: jspb.Message.getBooleanFieldWithDefault(msg, 20, false),
156
+ prerequisitesList: jspb.Message.toObjectList(msg.getPrerequisitesList(), proto_feature_prerequisite_pb.Prerequisite.toObject, includeInstance),
157
+ samplingSeed: jspb.Message.getFieldWithDefault(msg, 22, "")
158
+ };
159
+ if (includeInstance) {
160
+ obj.$jspbMessageInstance = msg;
161
+ }
162
+ return obj;
163
+ };
164
+ }
165
+
166
+ /**
167
+ * Deserializes binary data (in protobuf wire format).
168
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
169
+ * @return {!proto.bucketeer.feature.Feature}
170
+ */
171
+ proto.bucketeer.feature.Feature.deserializeBinary = function (bytes) {
172
+ var reader = new jspb.BinaryReader(bytes);
173
+ var msg = new proto.bucketeer.feature.Feature();
174
+ return proto.bucketeer.feature.Feature.deserializeBinaryFromReader(msg, reader);
175
+ };
176
+
177
+ /**
178
+ * Deserializes binary data (in protobuf wire format) from the
179
+ * given reader into the given message object.
180
+ * @param {!proto.bucketeer.feature.Feature} msg The message object to deserialize into.
181
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
182
+ * @return {!proto.bucketeer.feature.Feature}
183
+ */
184
+ proto.bucketeer.feature.Feature.deserializeBinaryFromReader = function (msg, reader) {
185
+ while (reader.nextField()) {
186
+ if (reader.isEndGroup()) {
187
+ break;
188
+ }
189
+ var field = reader.getFieldNumber();
190
+ switch (field) {
191
+ case 1:
192
+ var value = /** @type {string} */reader.readString();
193
+ msg.setId(value);
194
+ break;
195
+ case 2:
196
+ var value = /** @type {string} */reader.readString();
197
+ msg.setName(value);
198
+ break;
199
+ case 3:
200
+ var value = /** @type {string} */reader.readString();
201
+ msg.setDescription(value);
202
+ break;
203
+ case 4:
204
+ var value = /** @type {boolean} */reader.readBool();
205
+ msg.setEnabled(value);
206
+ break;
207
+ case 5:
208
+ var value = /** @type {boolean} */reader.readBool();
209
+ msg.setDeleted(value);
210
+ break;
211
+ case 6:
212
+ var value = /** @type {boolean} */reader.readBool();
213
+ msg.setEvaluationUndelayable(value);
214
+ break;
215
+ case 7:
216
+ var value = /** @type {number} */reader.readInt32();
217
+ msg.setTtl(value);
218
+ break;
219
+ case 8:
220
+ var value = /** @type {number} */reader.readInt32();
221
+ msg.setVersion(value);
222
+ break;
223
+ case 9:
224
+ var value = /** @type {number} */reader.readInt64();
225
+ msg.setCreatedAt(value);
226
+ break;
227
+ case 10:
228
+ var value = /** @type {number} */reader.readInt64();
229
+ msg.setUpdatedAt(value);
230
+ break;
231
+ case 11:
232
+ var value = new proto_feature_variation_pb.Variation();
233
+ reader.readMessage(value, proto_feature_variation_pb.Variation.deserializeBinaryFromReader);
234
+ msg.addVariations(value);
235
+ break;
236
+ case 12:
237
+ var value = new proto_feature_target_pb.Target();
238
+ reader.readMessage(value, proto_feature_target_pb.Target.deserializeBinaryFromReader);
239
+ msg.addTargets(value);
240
+ break;
241
+ case 13:
242
+ var value = new proto_feature_rule_pb.Rule();
243
+ reader.readMessage(value, proto_feature_rule_pb.Rule.deserializeBinaryFromReader);
244
+ msg.addRules(value);
245
+ break;
246
+ case 14:
247
+ var value = new proto_feature_strategy_pb.Strategy();
248
+ reader.readMessage(value, proto_feature_strategy_pb.Strategy.deserializeBinaryFromReader);
249
+ msg.setDefaultStrategy(value);
250
+ break;
251
+ case 15:
252
+ var value = /** @type {string} */reader.readString();
253
+ msg.setOffVariation(value);
254
+ break;
255
+ case 16:
256
+ var value = /** @type {string} */reader.readString();
257
+ msg.addTags(value);
258
+ break;
259
+ case 17:
260
+ var value = new proto_feature_feature_last_used_info_pb.FeatureLastUsedInfo();
261
+ reader.readMessage(value, proto_feature_feature_last_used_info_pb.FeatureLastUsedInfo.deserializeBinaryFromReader);
262
+ msg.setLastUsedInfo(value);
263
+ break;
264
+ case 18:
265
+ var value = /** @type {string} */reader.readString();
266
+ msg.setMaintainer(value);
267
+ break;
268
+ case 19:
269
+ var value = /** @type {!proto.bucketeer.feature.Feature.VariationType} */reader.readEnum();
270
+ msg.setVariationType(value);
271
+ break;
272
+ case 20:
273
+ var value = /** @type {boolean} */reader.readBool();
274
+ msg.setArchived(value);
275
+ break;
276
+ case 21:
277
+ var value = new proto_feature_prerequisite_pb.Prerequisite();
278
+ reader.readMessage(value, proto_feature_prerequisite_pb.Prerequisite.deserializeBinaryFromReader);
279
+ msg.addPrerequisites(value);
280
+ break;
281
+ case 22:
282
+ var value = /** @type {string} */reader.readString();
283
+ msg.setSamplingSeed(value);
284
+ break;
285
+ default:
286
+ reader.skipField();
287
+ break;
288
+ }
289
+ }
290
+ return msg;
291
+ };
292
+
293
+ /**
294
+ * Serializes the message to binary data (in protobuf wire format).
295
+ * @return {!Uint8Array}
296
+ */
297
+ proto.bucketeer.feature.Feature.prototype.serializeBinary = function () {
298
+ var writer = new jspb.BinaryWriter();
299
+ proto.bucketeer.feature.Feature.serializeBinaryToWriter(this, writer);
300
+ return writer.getResultBuffer();
301
+ };
302
+
303
+ /**
304
+ * Serializes the given message to binary data (in protobuf wire
305
+ * format), writing to the given BinaryWriter.
306
+ * @param {!proto.bucketeer.feature.Feature} message
307
+ * @param {!jspb.BinaryWriter} writer
308
+ * @suppress {unusedLocalVariables} f is only used for nested messages
309
+ */
310
+ proto.bucketeer.feature.Feature.serializeBinaryToWriter = function (message, writer) {
311
+ var f = undefined;
312
+ f = message.getId();
313
+ if (f.length > 0) {
314
+ writer.writeString(1, f);
315
+ }
316
+ f = message.getName();
317
+ if (f.length > 0) {
318
+ writer.writeString(2, f);
319
+ }
320
+ f = message.getDescription();
321
+ if (f.length > 0) {
322
+ writer.writeString(3, f);
323
+ }
324
+ f = message.getEnabled();
325
+ if (f) {
326
+ writer.writeBool(4, f);
327
+ }
328
+ f = message.getDeleted();
329
+ if (f) {
330
+ writer.writeBool(5, f);
331
+ }
332
+ f = message.getEvaluationUndelayable();
333
+ if (f) {
334
+ writer.writeBool(6, f);
335
+ }
336
+ f = message.getTtl();
337
+ if (f !== 0) {
338
+ writer.writeInt32(7, f);
339
+ }
340
+ f = message.getVersion();
341
+ if (f !== 0) {
342
+ writer.writeInt32(8, f);
343
+ }
344
+ f = message.getCreatedAt();
345
+ if (f !== 0) {
346
+ writer.writeInt64(9, f);
347
+ }
348
+ f = message.getUpdatedAt();
349
+ if (f !== 0) {
350
+ writer.writeInt64(10, f);
351
+ }
352
+ f = message.getVariationsList();
353
+ if (f.length > 0) {
354
+ writer.writeRepeatedMessage(11, f, proto_feature_variation_pb.Variation.serializeBinaryToWriter);
355
+ }
356
+ f = message.getTargetsList();
357
+ if (f.length > 0) {
358
+ writer.writeRepeatedMessage(12, f, proto_feature_target_pb.Target.serializeBinaryToWriter);
359
+ }
360
+ f = message.getRulesList();
361
+ if (f.length > 0) {
362
+ writer.writeRepeatedMessage(13, f, proto_feature_rule_pb.Rule.serializeBinaryToWriter);
363
+ }
364
+ f = message.getDefaultStrategy();
365
+ if (f != null) {
366
+ writer.writeMessage(14, f, proto_feature_strategy_pb.Strategy.serializeBinaryToWriter);
367
+ }
368
+ f = message.getOffVariation();
369
+ if (f.length > 0) {
370
+ writer.writeString(15, f);
371
+ }
372
+ f = message.getTagsList();
373
+ if (f.length > 0) {
374
+ writer.writeRepeatedString(16, f);
375
+ }
376
+ f = message.getLastUsedInfo();
377
+ if (f != null) {
378
+ writer.writeMessage(17, f, proto_feature_feature_last_used_info_pb.FeatureLastUsedInfo.serializeBinaryToWriter);
379
+ }
380
+ f = message.getMaintainer();
381
+ if (f.length > 0) {
382
+ writer.writeString(18, f);
383
+ }
384
+ f = message.getVariationType();
385
+ if (f !== 0.0) {
386
+ writer.writeEnum(19, f);
387
+ }
388
+ f = message.getArchived();
389
+ if (f) {
390
+ writer.writeBool(20, f);
391
+ }
392
+ f = message.getPrerequisitesList();
393
+ if (f.length > 0) {
394
+ writer.writeRepeatedMessage(21, f, proto_feature_prerequisite_pb.Prerequisite.serializeBinaryToWriter);
395
+ }
396
+ f = message.getSamplingSeed();
397
+ if (f.length > 0) {
398
+ writer.writeString(22, f);
399
+ }
400
+ };
401
+
402
+ /**
403
+ * @enum {number}
404
+ */
405
+ proto.bucketeer.feature.Feature.VariationType = {
406
+ STRING: 0,
407
+ BOOLEAN: 1,
408
+ NUMBER: 2,
409
+ JSON: 3
410
+ };
411
+
412
+ /**
413
+ * optional string id = 1;
414
+ * @return {string}
415
+ */
416
+ proto.bucketeer.feature.Feature.prototype.getId = function () {
417
+ return /** @type {string} */jspb.Message.getFieldWithDefault(this, 1, "");
418
+ };
419
+
420
+ /**
421
+ * @param {string} value
422
+ * @return {!proto.bucketeer.feature.Feature} returns this
423
+ */
424
+ proto.bucketeer.feature.Feature.prototype.setId = function (value) {
425
+ return jspb.Message.setProto3StringField(this, 1, value);
426
+ };
427
+
428
+ /**
429
+ * optional string name = 2;
430
+ * @return {string}
431
+ */
432
+ proto.bucketeer.feature.Feature.prototype.getName = function () {
433
+ return /** @type {string} */jspb.Message.getFieldWithDefault(this, 2, "");
434
+ };
435
+
436
+ /**
437
+ * @param {string} value
438
+ * @return {!proto.bucketeer.feature.Feature} returns this
439
+ */
440
+ proto.bucketeer.feature.Feature.prototype.setName = function (value) {
441
+ return jspb.Message.setProto3StringField(this, 2, value);
442
+ };
443
+
444
+ /**
445
+ * optional string description = 3;
446
+ * @return {string}
447
+ */
448
+ proto.bucketeer.feature.Feature.prototype.getDescription = function () {
449
+ return /** @type {string} */jspb.Message.getFieldWithDefault(this, 3, "");
450
+ };
451
+
452
+ /**
453
+ * @param {string} value
454
+ * @return {!proto.bucketeer.feature.Feature} returns this
455
+ */
456
+ proto.bucketeer.feature.Feature.prototype.setDescription = function (value) {
457
+ return jspb.Message.setProto3StringField(this, 3, value);
458
+ };
459
+
460
+ /**
461
+ * optional bool enabled = 4;
462
+ * @return {boolean}
463
+ */
464
+ proto.bucketeer.feature.Feature.prototype.getEnabled = function () {
465
+ return /** @type {boolean} */jspb.Message.getBooleanFieldWithDefault(this, 4, false);
466
+ };
467
+
468
+ /**
469
+ * @param {boolean} value
470
+ * @return {!proto.bucketeer.feature.Feature} returns this
471
+ */
472
+ proto.bucketeer.feature.Feature.prototype.setEnabled = function (value) {
473
+ return jspb.Message.setProto3BooleanField(this, 4, value);
474
+ };
475
+
476
+ /**
477
+ * optional bool deleted = 5;
478
+ * @return {boolean}
479
+ */
480
+ proto.bucketeer.feature.Feature.prototype.getDeleted = function () {
481
+ return /** @type {boolean} */jspb.Message.getBooleanFieldWithDefault(this, 5, false);
482
+ };
483
+
484
+ /**
485
+ * @param {boolean} value
486
+ * @return {!proto.bucketeer.feature.Feature} returns this
487
+ */
488
+ proto.bucketeer.feature.Feature.prototype.setDeleted = function (value) {
489
+ return jspb.Message.setProto3BooleanField(this, 5, value);
490
+ };
491
+
492
+ /**
493
+ * optional bool evaluation_undelayable = 6;
494
+ * @return {boolean}
495
+ */
496
+ proto.bucketeer.feature.Feature.prototype.getEvaluationUndelayable = function () {
497
+ return /** @type {boolean} */jspb.Message.getBooleanFieldWithDefault(this, 6, false);
498
+ };
499
+
500
+ /**
501
+ * @param {boolean} value
502
+ * @return {!proto.bucketeer.feature.Feature} returns this
503
+ */
504
+ proto.bucketeer.feature.Feature.prototype.setEvaluationUndelayable = function (value) {
505
+ return jspb.Message.setProto3BooleanField(this, 6, value);
506
+ };
507
+
508
+ /**
509
+ * optional int32 ttl = 7;
510
+ * @return {number}
511
+ */
512
+ proto.bucketeer.feature.Feature.prototype.getTtl = function () {
513
+ return /** @type {number} */jspb.Message.getFieldWithDefault(this, 7, 0);
514
+ };
515
+
516
+ /**
517
+ * @param {number} value
518
+ * @return {!proto.bucketeer.feature.Feature} returns this
519
+ */
520
+ proto.bucketeer.feature.Feature.prototype.setTtl = function (value) {
521
+ return jspb.Message.setProto3IntField(this, 7, value);
522
+ };
523
+
524
+ /**
525
+ * optional int32 version = 8;
526
+ * @return {number}
527
+ */
528
+ proto.bucketeer.feature.Feature.prototype.getVersion = function () {
529
+ return /** @type {number} */jspb.Message.getFieldWithDefault(this, 8, 0);
530
+ };
531
+
532
+ /**
533
+ * @param {number} value
534
+ * @return {!proto.bucketeer.feature.Feature} returns this
535
+ */
536
+ proto.bucketeer.feature.Feature.prototype.setVersion = function (value) {
537
+ return jspb.Message.setProto3IntField(this, 8, value);
538
+ };
539
+
540
+ /**
541
+ * optional int64 created_at = 9;
542
+ * @return {number}
543
+ */
544
+ proto.bucketeer.feature.Feature.prototype.getCreatedAt = function () {
545
+ return /** @type {number} */jspb.Message.getFieldWithDefault(this, 9, 0);
546
+ };
547
+
548
+ /**
549
+ * @param {number} value
550
+ * @return {!proto.bucketeer.feature.Feature} returns this
551
+ */
552
+ proto.bucketeer.feature.Feature.prototype.setCreatedAt = function (value) {
553
+ return jspb.Message.setProto3IntField(this, 9, value);
554
+ };
555
+
556
+ /**
557
+ * optional int64 updated_at = 10;
558
+ * @return {number}
559
+ */
560
+ proto.bucketeer.feature.Feature.prototype.getUpdatedAt = function () {
561
+ return /** @type {number} */jspb.Message.getFieldWithDefault(this, 10, 0);
562
+ };
563
+
564
+ /**
565
+ * @param {number} value
566
+ * @return {!proto.bucketeer.feature.Feature} returns this
567
+ */
568
+ proto.bucketeer.feature.Feature.prototype.setUpdatedAt = function (value) {
569
+ return jspb.Message.setProto3IntField(this, 10, value);
570
+ };
571
+
572
+ /**
573
+ * repeated Variation variations = 11;
574
+ * @return {!Array<!proto.bucketeer.feature.Variation>}
575
+ */
576
+ proto.bucketeer.feature.Feature.prototype.getVariationsList = function () {
577
+ return /** @type{!Array<!proto.bucketeer.feature.Variation>} */jspb.Message.getRepeatedWrapperField(this, proto_feature_variation_pb.Variation, 11);
578
+ };
579
+
580
+ /**
581
+ * @param {!Array<!proto.bucketeer.feature.Variation>} value
582
+ * @return {!proto.bucketeer.feature.Feature} returns this
583
+ */
584
+ proto.bucketeer.feature.Feature.prototype.setVariationsList = function (value) {
585
+ return jspb.Message.setRepeatedWrapperField(this, 11, value);
586
+ };
587
+
588
+ /**
589
+ * @param {!proto.bucketeer.feature.Variation=} opt_value
590
+ * @param {number=} opt_index
591
+ * @return {!proto.bucketeer.feature.Variation}
592
+ */
593
+ proto.bucketeer.feature.Feature.prototype.addVariations = function (opt_value, opt_index) {
594
+ return jspb.Message.addToRepeatedWrapperField(this, 11, opt_value, proto.bucketeer.feature.Variation, opt_index);
595
+ };
596
+
597
+ /**
598
+ * Clears the list making it empty but non-null.
599
+ * @return {!proto.bucketeer.feature.Feature} returns this
600
+ */
601
+ proto.bucketeer.feature.Feature.prototype.clearVariationsList = function () {
602
+ return this.setVariationsList([]);
603
+ };
604
+
605
+ /**
606
+ * repeated Target targets = 12;
607
+ * @return {!Array<!proto.bucketeer.feature.Target>}
608
+ */
609
+ proto.bucketeer.feature.Feature.prototype.getTargetsList = function () {
610
+ return /** @type{!Array<!proto.bucketeer.feature.Target>} */jspb.Message.getRepeatedWrapperField(this, proto_feature_target_pb.Target, 12);
611
+ };
612
+
613
+ /**
614
+ * @param {!Array<!proto.bucketeer.feature.Target>} value
615
+ * @return {!proto.bucketeer.feature.Feature} returns this
616
+ */
617
+ proto.bucketeer.feature.Feature.prototype.setTargetsList = function (value) {
618
+ return jspb.Message.setRepeatedWrapperField(this, 12, value);
619
+ };
620
+
621
+ /**
622
+ * @param {!proto.bucketeer.feature.Target=} opt_value
623
+ * @param {number=} opt_index
624
+ * @return {!proto.bucketeer.feature.Target}
625
+ */
626
+ proto.bucketeer.feature.Feature.prototype.addTargets = function (opt_value, opt_index) {
627
+ return jspb.Message.addToRepeatedWrapperField(this, 12, opt_value, proto.bucketeer.feature.Target, opt_index);
628
+ };
629
+
630
+ /**
631
+ * Clears the list making it empty but non-null.
632
+ * @return {!proto.bucketeer.feature.Feature} returns this
633
+ */
634
+ proto.bucketeer.feature.Feature.prototype.clearTargetsList = function () {
635
+ return this.setTargetsList([]);
636
+ };
637
+
638
+ /**
639
+ * repeated Rule rules = 13;
640
+ * @return {!Array<!proto.bucketeer.feature.Rule>}
641
+ */
642
+ proto.bucketeer.feature.Feature.prototype.getRulesList = function () {
643
+ return /** @type{!Array<!proto.bucketeer.feature.Rule>} */jspb.Message.getRepeatedWrapperField(this, proto_feature_rule_pb.Rule, 13);
644
+ };
645
+
646
+ /**
647
+ * @param {!Array<!proto.bucketeer.feature.Rule>} value
648
+ * @return {!proto.bucketeer.feature.Feature} returns this
649
+ */
650
+ proto.bucketeer.feature.Feature.prototype.setRulesList = function (value) {
651
+ return jspb.Message.setRepeatedWrapperField(this, 13, value);
652
+ };
653
+
654
+ /**
655
+ * @param {!proto.bucketeer.feature.Rule=} opt_value
656
+ * @param {number=} opt_index
657
+ * @return {!proto.bucketeer.feature.Rule}
658
+ */
659
+ proto.bucketeer.feature.Feature.prototype.addRules = function (opt_value, opt_index) {
660
+ return jspb.Message.addToRepeatedWrapperField(this, 13, opt_value, proto.bucketeer.feature.Rule, opt_index);
661
+ };
662
+
663
+ /**
664
+ * Clears the list making it empty but non-null.
665
+ * @return {!proto.bucketeer.feature.Feature} returns this
666
+ */
667
+ proto.bucketeer.feature.Feature.prototype.clearRulesList = function () {
668
+ return this.setRulesList([]);
669
+ };
670
+
671
+ /**
672
+ * optional Strategy default_strategy = 14;
673
+ * @return {?proto.bucketeer.feature.Strategy}
674
+ */
675
+ proto.bucketeer.feature.Feature.prototype.getDefaultStrategy = function () {
676
+ return /** @type{?proto.bucketeer.feature.Strategy} */jspb.Message.getWrapperField(this, proto_feature_strategy_pb.Strategy, 14);
677
+ };
678
+
679
+ /**
680
+ * @param {?proto.bucketeer.feature.Strategy|undefined} value
681
+ * @return {!proto.bucketeer.feature.Feature} returns this
682
+ */
683
+ proto.bucketeer.feature.Feature.prototype.setDefaultStrategy = function (value) {
684
+ return jspb.Message.setWrapperField(this, 14, value);
685
+ };
686
+
687
+ /**
688
+ * Clears the message field making it undefined.
689
+ * @return {!proto.bucketeer.feature.Feature} returns this
690
+ */
691
+ proto.bucketeer.feature.Feature.prototype.clearDefaultStrategy = function () {
692
+ return this.setDefaultStrategy(undefined);
693
+ };
694
+
695
+ /**
696
+ * Returns whether this field is set.
697
+ * @return {boolean}
698
+ */
699
+ proto.bucketeer.feature.Feature.prototype.hasDefaultStrategy = function () {
700
+ return jspb.Message.getField(this, 14) != null;
701
+ };
702
+
703
+ /**
704
+ * optional string off_variation = 15;
705
+ * @return {string}
706
+ */
707
+ proto.bucketeer.feature.Feature.prototype.getOffVariation = function () {
708
+ return /** @type {string} */jspb.Message.getFieldWithDefault(this, 15, "");
709
+ };
710
+
711
+ /**
712
+ * @param {string} value
713
+ * @return {!proto.bucketeer.feature.Feature} returns this
714
+ */
715
+ proto.bucketeer.feature.Feature.prototype.setOffVariation = function (value) {
716
+ return jspb.Message.setProto3StringField(this, 15, value);
717
+ };
718
+
719
+ /**
720
+ * repeated string tags = 16;
721
+ * @return {!Array<string>}
722
+ */
723
+ proto.bucketeer.feature.Feature.prototype.getTagsList = function () {
724
+ return /** @type {!Array<string>} */jspb.Message.getRepeatedField(this, 16);
725
+ };
726
+
727
+ /**
728
+ * @param {!Array<string>} value
729
+ * @return {!proto.bucketeer.feature.Feature} returns this
730
+ */
731
+ proto.bucketeer.feature.Feature.prototype.setTagsList = function (value) {
732
+ return jspb.Message.setField(this, 16, value || []);
733
+ };
734
+
735
+ /**
736
+ * @param {string} value
737
+ * @param {number=} opt_index
738
+ * @return {!proto.bucketeer.feature.Feature} returns this
739
+ */
740
+ proto.bucketeer.feature.Feature.prototype.addTags = function (value, opt_index) {
741
+ return jspb.Message.addToRepeatedField(this, 16, value, opt_index);
742
+ };
743
+
744
+ /**
745
+ * Clears the list making it empty but non-null.
746
+ * @return {!proto.bucketeer.feature.Feature} returns this
747
+ */
748
+ proto.bucketeer.feature.Feature.prototype.clearTagsList = function () {
749
+ return this.setTagsList([]);
750
+ };
751
+
752
+ /**
753
+ * optional FeatureLastUsedInfo last_used_info = 17;
754
+ * @return {?proto.bucketeer.feature.FeatureLastUsedInfo}
755
+ */
756
+ proto.bucketeer.feature.Feature.prototype.getLastUsedInfo = function () {
757
+ return /** @type{?proto.bucketeer.feature.FeatureLastUsedInfo} */jspb.Message.getWrapperField(this, proto_feature_feature_last_used_info_pb.FeatureLastUsedInfo, 17);
758
+ };
759
+
760
+ /**
761
+ * @param {?proto.bucketeer.feature.FeatureLastUsedInfo|undefined} value
762
+ * @return {!proto.bucketeer.feature.Feature} returns this
763
+ */
764
+ proto.bucketeer.feature.Feature.prototype.setLastUsedInfo = function (value) {
765
+ return jspb.Message.setWrapperField(this, 17, value);
766
+ };
767
+
768
+ /**
769
+ * Clears the message field making it undefined.
770
+ * @return {!proto.bucketeer.feature.Feature} returns this
771
+ */
772
+ proto.bucketeer.feature.Feature.prototype.clearLastUsedInfo = function () {
773
+ return this.setLastUsedInfo(undefined);
774
+ };
775
+
776
+ /**
777
+ * Returns whether this field is set.
778
+ * @return {boolean}
779
+ */
780
+ proto.bucketeer.feature.Feature.prototype.hasLastUsedInfo = function () {
781
+ return jspb.Message.getField(this, 17) != null;
782
+ };
783
+
784
+ /**
785
+ * optional string maintainer = 18;
786
+ * @return {string}
787
+ */
788
+ proto.bucketeer.feature.Feature.prototype.getMaintainer = function () {
789
+ return /** @type {string} */jspb.Message.getFieldWithDefault(this, 18, "");
790
+ };
791
+
792
+ /**
793
+ * @param {string} value
794
+ * @return {!proto.bucketeer.feature.Feature} returns this
795
+ */
796
+ proto.bucketeer.feature.Feature.prototype.setMaintainer = function (value) {
797
+ return jspb.Message.setProto3StringField(this, 18, value);
798
+ };
799
+
800
+ /**
801
+ * optional VariationType variation_type = 19;
802
+ * @return {!proto.bucketeer.feature.Feature.VariationType}
803
+ */
804
+ proto.bucketeer.feature.Feature.prototype.getVariationType = function () {
805
+ return /** @type {!proto.bucketeer.feature.Feature.VariationType} */jspb.Message.getFieldWithDefault(this, 19, 0);
806
+ };
807
+
808
+ /**
809
+ * @param {!proto.bucketeer.feature.Feature.VariationType} value
810
+ * @return {!proto.bucketeer.feature.Feature} returns this
811
+ */
812
+ proto.bucketeer.feature.Feature.prototype.setVariationType = function (value) {
813
+ return jspb.Message.setProto3EnumField(this, 19, value);
814
+ };
815
+
816
+ /**
817
+ * optional bool archived = 20;
818
+ * @return {boolean}
819
+ */
820
+ proto.bucketeer.feature.Feature.prototype.getArchived = function () {
821
+ return /** @type {boolean} */jspb.Message.getBooleanFieldWithDefault(this, 20, false);
822
+ };
823
+
824
+ /**
825
+ * @param {boolean} value
826
+ * @return {!proto.bucketeer.feature.Feature} returns this
827
+ */
828
+ proto.bucketeer.feature.Feature.prototype.setArchived = function (value) {
829
+ return jspb.Message.setProto3BooleanField(this, 20, value);
830
+ };
831
+
832
+ /**
833
+ * repeated Prerequisite prerequisites = 21;
834
+ * @return {!Array<!proto.bucketeer.feature.Prerequisite>}
835
+ */
836
+ proto.bucketeer.feature.Feature.prototype.getPrerequisitesList = function () {
837
+ return /** @type{!Array<!proto.bucketeer.feature.Prerequisite>} */jspb.Message.getRepeatedWrapperField(this, proto_feature_prerequisite_pb.Prerequisite, 21);
838
+ };
839
+
840
+ /**
841
+ * @param {!Array<!proto.bucketeer.feature.Prerequisite>} value
842
+ * @return {!proto.bucketeer.feature.Feature} returns this
843
+ */
844
+ proto.bucketeer.feature.Feature.prototype.setPrerequisitesList = function (value) {
845
+ return jspb.Message.setRepeatedWrapperField(this, 21, value);
846
+ };
847
+
848
+ /**
849
+ * @param {!proto.bucketeer.feature.Prerequisite=} opt_value
850
+ * @param {number=} opt_index
851
+ * @return {!proto.bucketeer.feature.Prerequisite}
852
+ */
853
+ proto.bucketeer.feature.Feature.prototype.addPrerequisites = function (opt_value, opt_index) {
854
+ return jspb.Message.addToRepeatedWrapperField(this, 21, opt_value, proto.bucketeer.feature.Prerequisite, opt_index);
855
+ };
856
+
857
+ /**
858
+ * Clears the list making it empty but non-null.
859
+ * @return {!proto.bucketeer.feature.Feature} returns this
860
+ */
861
+ proto.bucketeer.feature.Feature.prototype.clearPrerequisitesList = function () {
862
+ return this.setPrerequisitesList([]);
863
+ };
864
+
865
+ /**
866
+ * optional string sampling_seed = 22;
867
+ * @return {string}
868
+ */
869
+ proto.bucketeer.feature.Feature.prototype.getSamplingSeed = function () {
870
+ return /** @type {string} */jspb.Message.getFieldWithDefault(this, 22, "");
871
+ };
872
+
873
+ /**
874
+ * @param {string} value
875
+ * @return {!proto.bucketeer.feature.Feature} returns this
876
+ */
877
+ proto.bucketeer.feature.Feature.prototype.setSamplingSeed = function (value) {
878
+ return jspb.Message.setProto3StringField(this, 22, value);
879
+ };
880
+
881
+ /**
882
+ * List of repeated fields within this message type.
883
+ * @private {!Array<number>}
884
+ * @const
885
+ */
886
+ proto.bucketeer.feature.Features.repeatedFields_ = [1];
887
+ if (jspb.Message.GENERATE_TO_OBJECT) {
888
+ /**
889
+ * Creates an object representation of this proto.
890
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
891
+ * Optional fields that are not set will be set to undefined.
892
+ * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
893
+ * For the list of reserved names please see:
894
+ * net/proto2/compiler/js/internal/generator.cc#kKeyword.
895
+ * @param {boolean=} opt_includeInstance Deprecated. whether to include the
896
+ * JSPB instance for transitional soy proto support:
897
+ * http://goto/soy-param-migration
898
+ * @return {!Object}
899
+ */
900
+ proto.bucketeer.feature.Features.prototype.toObject = function (opt_includeInstance) {
901
+ return proto.bucketeer.feature.Features.toObject(opt_includeInstance, this);
902
+ };
903
+
904
+ /**
905
+ * Static version of the {@see toObject} method.
906
+ * @param {boolean|undefined} includeInstance Deprecated. Whether to include
907
+ * the JSPB instance for transitional soy proto support:
908
+ * http://goto/soy-param-migration
909
+ * @param {!proto.bucketeer.feature.Features} msg The msg instance to transform.
910
+ * @return {!Object}
911
+ * @suppress {unusedLocalVariables} f is only used for nested messages
912
+ */
913
+ proto.bucketeer.feature.Features.toObject = function (includeInstance, msg) {
914
+ var f,
915
+ obj = {
916
+ featuresList: jspb.Message.toObjectList(msg.getFeaturesList(), proto.bucketeer.feature.Feature.toObject, includeInstance),
917
+ id: jspb.Message.getFieldWithDefault(msg, 2, "")
918
+ };
919
+ if (includeInstance) {
920
+ obj.$jspbMessageInstance = msg;
921
+ }
922
+ return obj;
923
+ };
924
+ }
925
+
926
+ /**
927
+ * Deserializes binary data (in protobuf wire format).
928
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
929
+ * @return {!proto.bucketeer.feature.Features}
930
+ */
931
+ proto.bucketeer.feature.Features.deserializeBinary = function (bytes) {
932
+ var reader = new jspb.BinaryReader(bytes);
933
+ var msg = new proto.bucketeer.feature.Features();
934
+ return proto.bucketeer.feature.Features.deserializeBinaryFromReader(msg, reader);
935
+ };
936
+
937
+ /**
938
+ * Deserializes binary data (in protobuf wire format) from the
939
+ * given reader into the given message object.
940
+ * @param {!proto.bucketeer.feature.Features} msg The message object to deserialize into.
941
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
942
+ * @return {!proto.bucketeer.feature.Features}
943
+ */
944
+ proto.bucketeer.feature.Features.deserializeBinaryFromReader = function (msg, reader) {
945
+ while (reader.nextField()) {
946
+ if (reader.isEndGroup()) {
947
+ break;
948
+ }
949
+ var field = reader.getFieldNumber();
950
+ switch (field) {
951
+ case 1:
952
+ var value = new proto.bucketeer.feature.Feature();
953
+ reader.readMessage(value, proto.bucketeer.feature.Feature.deserializeBinaryFromReader);
954
+ msg.addFeatures(value);
955
+ break;
956
+ case 2:
957
+ var value = /** @type {string} */reader.readString();
958
+ msg.setId(value);
959
+ break;
960
+ default:
961
+ reader.skipField();
962
+ break;
963
+ }
964
+ }
965
+ return msg;
966
+ };
967
+
968
+ /**
969
+ * Serializes the message to binary data (in protobuf wire format).
970
+ * @return {!Uint8Array}
971
+ */
972
+ proto.bucketeer.feature.Features.prototype.serializeBinary = function () {
973
+ var writer = new jspb.BinaryWriter();
974
+ proto.bucketeer.feature.Features.serializeBinaryToWriter(this, writer);
975
+ return writer.getResultBuffer();
976
+ };
977
+
978
+ /**
979
+ * Serializes the given message to binary data (in protobuf wire
980
+ * format), writing to the given BinaryWriter.
981
+ * @param {!proto.bucketeer.feature.Features} message
982
+ * @param {!jspb.BinaryWriter} writer
983
+ * @suppress {unusedLocalVariables} f is only used for nested messages
984
+ */
985
+ proto.bucketeer.feature.Features.serializeBinaryToWriter = function (message, writer) {
986
+ var f = undefined;
987
+ f = message.getFeaturesList();
988
+ if (f.length > 0) {
989
+ writer.writeRepeatedMessage(1, f, proto.bucketeer.feature.Feature.serializeBinaryToWriter);
990
+ }
991
+ f = message.getId();
992
+ if (f.length > 0) {
993
+ writer.writeString(2, f);
994
+ }
995
+ };
996
+
997
+ /**
998
+ * repeated Feature features = 1;
999
+ * @return {!Array<!proto.bucketeer.feature.Feature>}
1000
+ */
1001
+ proto.bucketeer.feature.Features.prototype.getFeaturesList = function () {
1002
+ return /** @type{!Array<!proto.bucketeer.feature.Feature>} */jspb.Message.getRepeatedWrapperField(this, proto.bucketeer.feature.Feature, 1);
1003
+ };
1004
+
1005
+ /**
1006
+ * @param {!Array<!proto.bucketeer.feature.Feature>} value
1007
+ * @return {!proto.bucketeer.feature.Features} returns this
1008
+ */
1009
+ proto.bucketeer.feature.Features.prototype.setFeaturesList = function (value) {
1010
+ return jspb.Message.setRepeatedWrapperField(this, 1, value);
1011
+ };
1012
+
1013
+ /**
1014
+ * @param {!proto.bucketeer.feature.Feature=} opt_value
1015
+ * @param {number=} opt_index
1016
+ * @return {!proto.bucketeer.feature.Feature}
1017
+ */
1018
+ proto.bucketeer.feature.Features.prototype.addFeatures = function (opt_value, opt_index) {
1019
+ return jspb.Message.addToRepeatedWrapperField(this, 1, opt_value, proto.bucketeer.feature.Feature, opt_index);
1020
+ };
1021
+
1022
+ /**
1023
+ * Clears the list making it empty but non-null.
1024
+ * @return {!proto.bucketeer.feature.Features} returns this
1025
+ */
1026
+ proto.bucketeer.feature.Features.prototype.clearFeaturesList = function () {
1027
+ return this.setFeaturesList([]);
1028
+ };
1029
+
1030
+ /**
1031
+ * optional string id = 2;
1032
+ * @return {string}
1033
+ */
1034
+ proto.bucketeer.feature.Features.prototype.getId = function () {
1035
+ return /** @type {string} */jspb.Message.getFieldWithDefault(this, 2, "");
1036
+ };
1037
+
1038
+ /**
1039
+ * @param {string} value
1040
+ * @return {!proto.bucketeer.feature.Features} returns this
1041
+ */
1042
+ proto.bucketeer.feature.Features.prototype.setId = function (value) {
1043
+ return jspb.Message.setProto3StringField(this, 2, value);
1044
+ };
1045
+ if (jspb.Message.GENERATE_TO_OBJECT) {
1046
+ /**
1047
+ * Creates an object representation of this proto.
1048
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
1049
+ * Optional fields that are not set will be set to undefined.
1050
+ * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
1051
+ * For the list of reserved names please see:
1052
+ * net/proto2/compiler/js/internal/generator.cc#kKeyword.
1053
+ * @param {boolean=} opt_includeInstance Deprecated. whether to include the
1054
+ * JSPB instance for transitional soy proto support:
1055
+ * http://goto/soy-param-migration
1056
+ * @return {!Object}
1057
+ */
1058
+ proto.bucketeer.feature.Tag.prototype.toObject = function (opt_includeInstance) {
1059
+ return proto.bucketeer.feature.Tag.toObject(opt_includeInstance, this);
1060
+ };
1061
+
1062
+ /**
1063
+ * Static version of the {@see toObject} method.
1064
+ * @param {boolean|undefined} includeInstance Deprecated. Whether to include
1065
+ * the JSPB instance for transitional soy proto support:
1066
+ * http://goto/soy-param-migration
1067
+ * @param {!proto.bucketeer.feature.Tag} msg The msg instance to transform.
1068
+ * @return {!Object}
1069
+ * @suppress {unusedLocalVariables} f is only used for nested messages
1070
+ */
1071
+ proto.bucketeer.feature.Tag.toObject = function (includeInstance, msg) {
1072
+ var f,
1073
+ obj = {
1074
+ id: jspb.Message.getFieldWithDefault(msg, 1, ""),
1075
+ createdAt: jspb.Message.getFieldWithDefault(msg, 2, 0),
1076
+ updatedAt: jspb.Message.getFieldWithDefault(msg, 3, 0)
1077
+ };
1078
+ if (includeInstance) {
1079
+ obj.$jspbMessageInstance = msg;
1080
+ }
1081
+ return obj;
1082
+ };
1083
+ }
1084
+
1085
+ /**
1086
+ * Deserializes binary data (in protobuf wire format).
1087
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
1088
+ * @return {!proto.bucketeer.feature.Tag}
1089
+ */
1090
+ proto.bucketeer.feature.Tag.deserializeBinary = function (bytes) {
1091
+ var reader = new jspb.BinaryReader(bytes);
1092
+ var msg = new proto.bucketeer.feature.Tag();
1093
+ return proto.bucketeer.feature.Tag.deserializeBinaryFromReader(msg, reader);
1094
+ };
1095
+
1096
+ /**
1097
+ * Deserializes binary data (in protobuf wire format) from the
1098
+ * given reader into the given message object.
1099
+ * @param {!proto.bucketeer.feature.Tag} msg The message object to deserialize into.
1100
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
1101
+ * @return {!proto.bucketeer.feature.Tag}
1102
+ */
1103
+ proto.bucketeer.feature.Tag.deserializeBinaryFromReader = function (msg, reader) {
1104
+ while (reader.nextField()) {
1105
+ if (reader.isEndGroup()) {
1106
+ break;
1107
+ }
1108
+ var field = reader.getFieldNumber();
1109
+ switch (field) {
1110
+ case 1:
1111
+ var value = /** @type {string} */reader.readString();
1112
+ msg.setId(value);
1113
+ break;
1114
+ case 2:
1115
+ var value = /** @type {number} */reader.readInt64();
1116
+ msg.setCreatedAt(value);
1117
+ break;
1118
+ case 3:
1119
+ var value = /** @type {number} */reader.readInt64();
1120
+ msg.setUpdatedAt(value);
1121
+ break;
1122
+ default:
1123
+ reader.skipField();
1124
+ break;
1125
+ }
1126
+ }
1127
+ return msg;
1128
+ };
1129
+
1130
+ /**
1131
+ * Serializes the message to binary data (in protobuf wire format).
1132
+ * @return {!Uint8Array}
1133
+ */
1134
+ proto.bucketeer.feature.Tag.prototype.serializeBinary = function () {
1135
+ var writer = new jspb.BinaryWriter();
1136
+ proto.bucketeer.feature.Tag.serializeBinaryToWriter(this, writer);
1137
+ return writer.getResultBuffer();
1138
+ };
1139
+
1140
+ /**
1141
+ * Serializes the given message to binary data (in protobuf wire
1142
+ * format), writing to the given BinaryWriter.
1143
+ * @param {!proto.bucketeer.feature.Tag} message
1144
+ * @param {!jspb.BinaryWriter} writer
1145
+ * @suppress {unusedLocalVariables} f is only used for nested messages
1146
+ */
1147
+ proto.bucketeer.feature.Tag.serializeBinaryToWriter = function (message, writer) {
1148
+ var f = undefined;
1149
+ f = message.getId();
1150
+ if (f.length > 0) {
1151
+ writer.writeString(1, f);
1152
+ }
1153
+ f = message.getCreatedAt();
1154
+ if (f !== 0) {
1155
+ writer.writeInt64(2, f);
1156
+ }
1157
+ f = message.getUpdatedAt();
1158
+ if (f !== 0) {
1159
+ writer.writeInt64(3, f);
1160
+ }
1161
+ };
1162
+
1163
+ /**
1164
+ * optional string id = 1;
1165
+ * @return {string}
1166
+ */
1167
+ proto.bucketeer.feature.Tag.prototype.getId = function () {
1168
+ return /** @type {string} */jspb.Message.getFieldWithDefault(this, 1, "");
1169
+ };
1170
+
1171
+ /**
1172
+ * @param {string} value
1173
+ * @return {!proto.bucketeer.feature.Tag} returns this
1174
+ */
1175
+ proto.bucketeer.feature.Tag.prototype.setId = function (value) {
1176
+ return jspb.Message.setProto3StringField(this, 1, value);
1177
+ };
1178
+
1179
+ /**
1180
+ * optional int64 created_at = 2;
1181
+ * @return {number}
1182
+ */
1183
+ proto.bucketeer.feature.Tag.prototype.getCreatedAt = function () {
1184
+ return /** @type {number} */jspb.Message.getFieldWithDefault(this, 2, 0);
1185
+ };
1186
+
1187
+ /**
1188
+ * @param {number} value
1189
+ * @return {!proto.bucketeer.feature.Tag} returns this
1190
+ */
1191
+ proto.bucketeer.feature.Tag.prototype.setCreatedAt = function (value) {
1192
+ return jspb.Message.setProto3IntField(this, 2, value);
1193
+ };
1194
+
1195
+ /**
1196
+ * optional int64 updated_at = 3;
1197
+ * @return {number}
1198
+ */
1199
+ proto.bucketeer.feature.Tag.prototype.getUpdatedAt = function () {
1200
+ return /** @type {number} */jspb.Message.getFieldWithDefault(this, 3, 0);
1201
+ };
1202
+
1203
+ /**
1204
+ * @param {number} value
1205
+ * @return {!proto.bucketeer.feature.Tag} returns this
1206
+ */
1207
+ proto.bucketeer.feature.Tag.prototype.setUpdatedAt = function (value) {
1208
+ return jspb.Message.setProto3IntField(this, 3, value);
1209
+ };
1210
+ goog.object.extend(exports, proto.bucketeer.feature);