protobuf-platform 1.0.16 → 1.0.18

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.
@@ -42,8 +42,8 @@ message ConfigDataResponse {
42
42
  }
43
43
  message ErrorRequest {
44
44
  string error_key = 1;
45
- string error_code = 2;
46
- string http_code = 3;
45
+ int32 error_code = 2;
46
+ int32 http_code = 3;
47
47
  optional string description = 4;
48
48
  }
49
49
  message ErrorStatusResponse {
@@ -1462,8 +1462,8 @@ proto.config.ErrorRequest.prototype.toObject = function(opt_includeInstance) {
1462
1462
  proto.config.ErrorRequest.toObject = function(includeInstance, msg) {
1463
1463
  var f, obj = {
1464
1464
  errorKey: jspb.Message.getFieldWithDefault(msg, 1, ""),
1465
- errorCode: jspb.Message.getFieldWithDefault(msg, 2, ""),
1466
- httpCode: jspb.Message.getFieldWithDefault(msg, 3, ""),
1465
+ errorCode: jspb.Message.getFieldWithDefault(msg, 2, 0),
1466
+ httpCode: jspb.Message.getFieldWithDefault(msg, 3, 0),
1467
1467
  description: jspb.Message.getFieldWithDefault(msg, 4, "")
1468
1468
  };
1469
1469
 
@@ -1506,11 +1506,11 @@ proto.config.ErrorRequest.deserializeBinaryFromReader = function(msg, reader) {
1506
1506
  msg.setErrorKey(value);
1507
1507
  break;
1508
1508
  case 2:
1509
- var value = /** @type {string} */ (reader.readString());
1509
+ var value = /** @type {number} */ (reader.readInt32());
1510
1510
  msg.setErrorCode(value);
1511
1511
  break;
1512
1512
  case 3:
1513
- var value = /** @type {string} */ (reader.readString());
1513
+ var value = /** @type {number} */ (reader.readInt32());
1514
1514
  msg.setHttpCode(value);
1515
1515
  break;
1516
1516
  case 4:
@@ -1554,15 +1554,15 @@ proto.config.ErrorRequest.serializeBinaryToWriter = function(message, writer) {
1554
1554
  );
1555
1555
  }
1556
1556
  f = message.getErrorCode();
1557
- if (f.length > 0) {
1558
- writer.writeString(
1557
+ if (f !== 0) {
1558
+ writer.writeInt32(
1559
1559
  2,
1560
1560
  f
1561
1561
  );
1562
1562
  }
1563
1563
  f = message.getHttpCode();
1564
- if (f.length > 0) {
1565
- writer.writeString(
1564
+ if (f !== 0) {
1565
+ writer.writeInt32(
1566
1566
  3,
1567
1567
  f
1568
1568
  );
@@ -1596,38 +1596,38 @@ proto.config.ErrorRequest.prototype.setErrorKey = function(value) {
1596
1596
 
1597
1597
 
1598
1598
  /**
1599
- * optional string error_code = 2;
1600
- * @return {string}
1599
+ * optional int32 error_code = 2;
1600
+ * @return {number}
1601
1601
  */
1602
1602
  proto.config.ErrorRequest.prototype.getErrorCode = function() {
1603
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
1603
+ return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 2, 0));
1604
1604
  };
1605
1605
 
1606
1606
 
1607
1607
  /**
1608
- * @param {string} value
1608
+ * @param {number} value
1609
1609
  * @return {!proto.config.ErrorRequest} returns this
1610
1610
  */
1611
1611
  proto.config.ErrorRequest.prototype.setErrorCode = function(value) {
1612
- return jspb.Message.setProto3StringField(this, 2, value);
1612
+ return jspb.Message.setProto3IntField(this, 2, value);
1613
1613
  };
1614
1614
 
1615
1615
 
1616
1616
  /**
1617
- * optional string http_code = 3;
1618
- * @return {string}
1617
+ * optional int32 http_code = 3;
1618
+ * @return {number}
1619
1619
  */
1620
1620
  proto.config.ErrorRequest.prototype.getHttpCode = function() {
1621
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
1621
+ return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 3, 0));
1622
1622
  };
1623
1623
 
1624
1624
 
1625
1625
  /**
1626
- * @param {string} value
1626
+ * @param {number} value
1627
1627
  * @return {!proto.config.ErrorRequest} returns this
1628
1628
  */
1629
1629
  proto.config.ErrorRequest.prototype.setHttpCode = function(value) {
1630
- return jspb.Message.setProto3StringField(this, 3, value);
1630
+ return jspb.Message.setProto3IntField(this, 3, value);
1631
1631
  };
1632
1632
 
1633
1633
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "protobuf-platform",
3
- "version": "1.0.16",
3
+ "version": "1.0.18",
4
4
  "description": "Protobuf structures",
5
5
  "main": "index.js",
6
6
  "scripts": {
package/user/user.proto CHANGED
@@ -29,6 +29,7 @@ message LoggedInResponse {
29
29
  string public_id = 2;
30
30
  string currency = 3;
31
31
  string country = 4;
32
+ string role = 5;
32
33
  }
33
34
  message LoginRequest {
34
35
  string email = 1;
package/user/user_pb.js CHANGED
@@ -882,7 +882,8 @@ proto.user.LoggedInResponse.toObject = function(includeInstance, msg) {
882
882
  id: jspb.Message.getFieldWithDefault(msg, 1, 0),
883
883
  publicId: jspb.Message.getFieldWithDefault(msg, 2, ""),
884
884
  currency: jspb.Message.getFieldWithDefault(msg, 3, ""),
885
- country: jspb.Message.getFieldWithDefault(msg, 4, "")
885
+ country: jspb.Message.getFieldWithDefault(msg, 4, ""),
886
+ role: jspb.Message.getFieldWithDefault(msg, 5, "")
886
887
  };
887
888
 
888
889
  if (includeInstance) {
@@ -935,6 +936,10 @@ proto.user.LoggedInResponse.deserializeBinaryFromReader = function(msg, reader)
935
936
  var value = /** @type {string} */ (reader.readString());
936
937
  msg.setCountry(value);
937
938
  break;
939
+ case 5:
940
+ var value = /** @type {string} */ (reader.readString());
941
+ msg.setRole(value);
942
+ break;
938
943
  default:
939
944
  reader.skipField();
940
945
  break;
@@ -992,6 +997,13 @@ proto.user.LoggedInResponse.serializeBinaryToWriter = function(message, writer)
992
997
  f
993
998
  );
994
999
  }
1000
+ f = message.getRole();
1001
+ if (f.length > 0) {
1002
+ writer.writeString(
1003
+ 5,
1004
+ f
1005
+ );
1006
+ }
995
1007
  };
996
1008
 
997
1009
 
@@ -1067,6 +1079,24 @@ proto.user.LoggedInResponse.prototype.setCountry = function(value) {
1067
1079
  };
1068
1080
 
1069
1081
 
1082
+ /**
1083
+ * optional string role = 5;
1084
+ * @return {string}
1085
+ */
1086
+ proto.user.LoggedInResponse.prototype.getRole = function() {
1087
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 5, ""));
1088
+ };
1089
+
1090
+
1091
+ /**
1092
+ * @param {string} value
1093
+ * @return {!proto.user.LoggedInResponse} returns this
1094
+ */
1095
+ proto.user.LoggedInResponse.prototype.setRole = function(value) {
1096
+ return jspb.Message.setProto3StringField(this, 5, value);
1097
+ };
1098
+
1099
+
1070
1100
 
1071
1101
 
1072
1102