@dashevo/dapi-grpc 5.0.0-rc.7 → 5.0.0-rc.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build.rs +8 -3
- package/clients/drive/v0/nodejs/drive_pbjs.js +1026 -15
- package/clients/platform/v0/nodejs/platform_pbjs.js +1026 -15
- package/clients/platform/v0/nodejs/platform_protoc.js +1144 -21
- package/clients/platform/v0/web/platform_pb.d.ts +146 -3
- package/clients/platform/v0/web/platform_pb.js +1144 -21
- package/package.json +2 -2
- package/protos/platform/v0/platform.proto +33 -4
- package/test/unit/nonunique-proof.spec.js +64 -20
- package/tests/nonunique_identity_lookup_wire.rs +56 -0
|
@@ -54196,6 +54196,7 @@ $root.org = (function() {
|
|
|
54196
54196
|
* @memberof org.dash.platform.dapi.v0
|
|
54197
54197
|
* @interface IGetIdentityByNonUniquePublicKeyHashRequest
|
|
54198
54198
|
* @property {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.IGetIdentityByNonUniquePublicKeyHashRequestV0|null} [v0] GetIdentityByNonUniquePublicKeyHashRequest v0
|
|
54199
|
+
* @property {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.IGetIdentityByNonUniquePublicKeyHashRequestV1|null} [v1] GetIdentityByNonUniquePublicKeyHashRequest v1
|
|
54199
54200
|
*/
|
|
54200
54201
|
|
|
54201
54202
|
/**
|
|
@@ -54221,17 +54222,25 @@ $root.org = (function() {
|
|
|
54221
54222
|
*/
|
|
54222
54223
|
GetIdentityByNonUniquePublicKeyHashRequest.prototype.v0 = null;
|
|
54223
54224
|
|
|
54225
|
+
/**
|
|
54226
|
+
* GetIdentityByNonUniquePublicKeyHashRequest v1.
|
|
54227
|
+
* @member {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.IGetIdentityByNonUniquePublicKeyHashRequestV1|null|undefined} v1
|
|
54228
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest
|
|
54229
|
+
* @instance
|
|
54230
|
+
*/
|
|
54231
|
+
GetIdentityByNonUniquePublicKeyHashRequest.prototype.v1 = null;
|
|
54232
|
+
|
|
54224
54233
|
// OneOf field names bound to virtual getters and setters
|
|
54225
54234
|
var $oneOfFields;
|
|
54226
54235
|
|
|
54227
54236
|
/**
|
|
54228
54237
|
* GetIdentityByNonUniquePublicKeyHashRequest version.
|
|
54229
|
-
* @member {"v0"|undefined} version
|
|
54238
|
+
* @member {"v0"|"v1"|undefined} version
|
|
54230
54239
|
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest
|
|
54231
54240
|
* @instance
|
|
54232
54241
|
*/
|
|
54233
54242
|
Object.defineProperty(GetIdentityByNonUniquePublicKeyHashRequest.prototype, "version", {
|
|
54234
|
-
get: $util.oneOfGetter($oneOfFields = ["v0"]),
|
|
54243
|
+
get: $util.oneOfGetter($oneOfFields = ["v0", "v1"]),
|
|
54235
54244
|
set: $util.oneOfSetter($oneOfFields)
|
|
54236
54245
|
});
|
|
54237
54246
|
|
|
@@ -54261,6 +54270,8 @@ $root.org = (function() {
|
|
|
54261
54270
|
writer = $Writer.create();
|
|
54262
54271
|
if (message.v0 != null && Object.hasOwnProperty.call(message, "v0"))
|
|
54263
54272
|
$root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.GetIdentityByNonUniquePublicKeyHashRequestV0.encode(message.v0, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim();
|
|
54273
|
+
if (message.v1 != null && Object.hasOwnProperty.call(message, "v1"))
|
|
54274
|
+
$root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.GetIdentityByNonUniquePublicKeyHashRequestV1.encode(message.v1, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim();
|
|
54264
54275
|
return writer;
|
|
54265
54276
|
};
|
|
54266
54277
|
|
|
@@ -54298,6 +54309,9 @@ $root.org = (function() {
|
|
|
54298
54309
|
case 1:
|
|
54299
54310
|
message.v0 = $root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.GetIdentityByNonUniquePublicKeyHashRequestV0.decode(reader, reader.uint32());
|
|
54300
54311
|
break;
|
|
54312
|
+
case 2:
|
|
54313
|
+
message.v1 = $root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.GetIdentityByNonUniquePublicKeyHashRequestV1.decode(reader, reader.uint32());
|
|
54314
|
+
break;
|
|
54301
54315
|
default:
|
|
54302
54316
|
reader.skipType(tag & 7);
|
|
54303
54317
|
break;
|
|
@@ -54342,6 +54356,16 @@ $root.org = (function() {
|
|
|
54342
54356
|
return "v0." + error;
|
|
54343
54357
|
}
|
|
54344
54358
|
}
|
|
54359
|
+
if (message.v1 != null && message.hasOwnProperty("v1")) {
|
|
54360
|
+
if (properties.version === 1)
|
|
54361
|
+
return "version: multiple values";
|
|
54362
|
+
properties.version = 1;
|
|
54363
|
+
{
|
|
54364
|
+
var error = $root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.GetIdentityByNonUniquePublicKeyHashRequestV1.verify(message.v1);
|
|
54365
|
+
if (error)
|
|
54366
|
+
return "v1." + error;
|
|
54367
|
+
}
|
|
54368
|
+
}
|
|
54345
54369
|
return null;
|
|
54346
54370
|
};
|
|
54347
54371
|
|
|
@@ -54362,6 +54386,11 @@ $root.org = (function() {
|
|
|
54362
54386
|
throw TypeError(".org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.v0: object expected");
|
|
54363
54387
|
message.v0 = $root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.GetIdentityByNonUniquePublicKeyHashRequestV0.fromObject(object.v0);
|
|
54364
54388
|
}
|
|
54389
|
+
if (object.v1 != null) {
|
|
54390
|
+
if (typeof object.v1 !== "object")
|
|
54391
|
+
throw TypeError(".org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.v1: object expected");
|
|
54392
|
+
message.v1 = $root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.GetIdentityByNonUniquePublicKeyHashRequestV1.fromObject(object.v1);
|
|
54393
|
+
}
|
|
54365
54394
|
return message;
|
|
54366
54395
|
};
|
|
54367
54396
|
|
|
@@ -54383,6 +54412,11 @@ $root.org = (function() {
|
|
|
54383
54412
|
if (options.oneofs)
|
|
54384
54413
|
object.version = "v0";
|
|
54385
54414
|
}
|
|
54415
|
+
if (message.v1 != null && message.hasOwnProperty("v1")) {
|
|
54416
|
+
object.v1 = $root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.GetIdentityByNonUniquePublicKeyHashRequestV1.toObject(message.v1, options);
|
|
54417
|
+
if (options.oneofs)
|
|
54418
|
+
object.version = "v1";
|
|
54419
|
+
}
|
|
54386
54420
|
return object;
|
|
54387
54421
|
};
|
|
54388
54422
|
|
|
@@ -54647,6 +54681,256 @@ $root.org = (function() {
|
|
|
54647
54681
|
return GetIdentityByNonUniquePublicKeyHashRequestV0;
|
|
54648
54682
|
})();
|
|
54649
54683
|
|
|
54684
|
+
GetIdentityByNonUniquePublicKeyHashRequest.GetIdentityByNonUniquePublicKeyHashRequestV1 = (function() {
|
|
54685
|
+
|
|
54686
|
+
/**
|
|
54687
|
+
* Properties of a GetIdentityByNonUniquePublicKeyHashRequestV1.
|
|
54688
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest
|
|
54689
|
+
* @interface IGetIdentityByNonUniquePublicKeyHashRequestV1
|
|
54690
|
+
* @property {Uint8Array|null} [publicKeyHash] GetIdentityByNonUniquePublicKeyHashRequestV1 publicKeyHash
|
|
54691
|
+
* @property {Uint8Array|null} [startAfter] GetIdentityByNonUniquePublicKeyHashRequestV1 startAfter
|
|
54692
|
+
* @property {boolean|null} [prove] GetIdentityByNonUniquePublicKeyHashRequestV1 prove
|
|
54693
|
+
*/
|
|
54694
|
+
|
|
54695
|
+
/**
|
|
54696
|
+
* Constructs a new GetIdentityByNonUniquePublicKeyHashRequestV1.
|
|
54697
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest
|
|
54698
|
+
* @classdesc Represents a GetIdentityByNonUniquePublicKeyHashRequestV1.
|
|
54699
|
+
* @implements IGetIdentityByNonUniquePublicKeyHashRequestV1
|
|
54700
|
+
* @constructor
|
|
54701
|
+
* @param {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.IGetIdentityByNonUniquePublicKeyHashRequestV1=} [properties] Properties to set
|
|
54702
|
+
*/
|
|
54703
|
+
function GetIdentityByNonUniquePublicKeyHashRequestV1(properties) {
|
|
54704
|
+
if (properties)
|
|
54705
|
+
for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
|
|
54706
|
+
if (properties[keys[i]] != null)
|
|
54707
|
+
this[keys[i]] = properties[keys[i]];
|
|
54708
|
+
}
|
|
54709
|
+
|
|
54710
|
+
/**
|
|
54711
|
+
* GetIdentityByNonUniquePublicKeyHashRequestV1 publicKeyHash.
|
|
54712
|
+
* @member {Uint8Array} publicKeyHash
|
|
54713
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.GetIdentityByNonUniquePublicKeyHashRequestV1
|
|
54714
|
+
* @instance
|
|
54715
|
+
*/
|
|
54716
|
+
GetIdentityByNonUniquePublicKeyHashRequestV1.prototype.publicKeyHash = $util.newBuffer([]);
|
|
54717
|
+
|
|
54718
|
+
/**
|
|
54719
|
+
* GetIdentityByNonUniquePublicKeyHashRequestV1 startAfter.
|
|
54720
|
+
* @member {Uint8Array} startAfter
|
|
54721
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.GetIdentityByNonUniquePublicKeyHashRequestV1
|
|
54722
|
+
* @instance
|
|
54723
|
+
*/
|
|
54724
|
+
GetIdentityByNonUniquePublicKeyHashRequestV1.prototype.startAfter = $util.newBuffer([]);
|
|
54725
|
+
|
|
54726
|
+
/**
|
|
54727
|
+
* GetIdentityByNonUniquePublicKeyHashRequestV1 prove.
|
|
54728
|
+
* @member {boolean} prove
|
|
54729
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.GetIdentityByNonUniquePublicKeyHashRequestV1
|
|
54730
|
+
* @instance
|
|
54731
|
+
*/
|
|
54732
|
+
GetIdentityByNonUniquePublicKeyHashRequestV1.prototype.prove = false;
|
|
54733
|
+
|
|
54734
|
+
/**
|
|
54735
|
+
* Creates a new GetIdentityByNonUniquePublicKeyHashRequestV1 instance using the specified properties.
|
|
54736
|
+
* @function create
|
|
54737
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.GetIdentityByNonUniquePublicKeyHashRequestV1
|
|
54738
|
+
* @static
|
|
54739
|
+
* @param {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.IGetIdentityByNonUniquePublicKeyHashRequestV1=} [properties] Properties to set
|
|
54740
|
+
* @returns {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.GetIdentityByNonUniquePublicKeyHashRequestV1} GetIdentityByNonUniquePublicKeyHashRequestV1 instance
|
|
54741
|
+
*/
|
|
54742
|
+
GetIdentityByNonUniquePublicKeyHashRequestV1.create = function create(properties) {
|
|
54743
|
+
return new GetIdentityByNonUniquePublicKeyHashRequestV1(properties);
|
|
54744
|
+
};
|
|
54745
|
+
|
|
54746
|
+
/**
|
|
54747
|
+
* Encodes the specified GetIdentityByNonUniquePublicKeyHashRequestV1 message. Does not implicitly {@link org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.GetIdentityByNonUniquePublicKeyHashRequestV1.verify|verify} messages.
|
|
54748
|
+
* @function encode
|
|
54749
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.GetIdentityByNonUniquePublicKeyHashRequestV1
|
|
54750
|
+
* @static
|
|
54751
|
+
* @param {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.IGetIdentityByNonUniquePublicKeyHashRequestV1} message GetIdentityByNonUniquePublicKeyHashRequestV1 message or plain object to encode
|
|
54752
|
+
* @param {$protobuf.Writer} [writer] Writer to encode to
|
|
54753
|
+
* @returns {$protobuf.Writer} Writer
|
|
54754
|
+
*/
|
|
54755
|
+
GetIdentityByNonUniquePublicKeyHashRequestV1.encode = function encode(message, writer) {
|
|
54756
|
+
if (!writer)
|
|
54757
|
+
writer = $Writer.create();
|
|
54758
|
+
if (message.publicKeyHash != null && Object.hasOwnProperty.call(message, "publicKeyHash"))
|
|
54759
|
+
writer.uint32(/* id 1, wireType 2 =*/10).bytes(message.publicKeyHash);
|
|
54760
|
+
if (message.startAfter != null && Object.hasOwnProperty.call(message, "startAfter"))
|
|
54761
|
+
writer.uint32(/* id 2, wireType 2 =*/18).bytes(message.startAfter);
|
|
54762
|
+
if (message.prove != null && Object.hasOwnProperty.call(message, "prove"))
|
|
54763
|
+
writer.uint32(/* id 3, wireType 0 =*/24).bool(message.prove);
|
|
54764
|
+
return writer;
|
|
54765
|
+
};
|
|
54766
|
+
|
|
54767
|
+
/**
|
|
54768
|
+
* Encodes the specified GetIdentityByNonUniquePublicKeyHashRequestV1 message, length delimited. Does not implicitly {@link org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.GetIdentityByNonUniquePublicKeyHashRequestV1.verify|verify} messages.
|
|
54769
|
+
* @function encodeDelimited
|
|
54770
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.GetIdentityByNonUniquePublicKeyHashRequestV1
|
|
54771
|
+
* @static
|
|
54772
|
+
* @param {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.IGetIdentityByNonUniquePublicKeyHashRequestV1} message GetIdentityByNonUniquePublicKeyHashRequestV1 message or plain object to encode
|
|
54773
|
+
* @param {$protobuf.Writer} [writer] Writer to encode to
|
|
54774
|
+
* @returns {$protobuf.Writer} Writer
|
|
54775
|
+
*/
|
|
54776
|
+
GetIdentityByNonUniquePublicKeyHashRequestV1.encodeDelimited = function encodeDelimited(message, writer) {
|
|
54777
|
+
return this.encode(message, writer).ldelim();
|
|
54778
|
+
};
|
|
54779
|
+
|
|
54780
|
+
/**
|
|
54781
|
+
* Decodes a GetIdentityByNonUniquePublicKeyHashRequestV1 message from the specified reader or buffer.
|
|
54782
|
+
* @function decode
|
|
54783
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.GetIdentityByNonUniquePublicKeyHashRequestV1
|
|
54784
|
+
* @static
|
|
54785
|
+
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
|
|
54786
|
+
* @param {number} [length] Message length if known beforehand
|
|
54787
|
+
* @returns {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.GetIdentityByNonUniquePublicKeyHashRequestV1} GetIdentityByNonUniquePublicKeyHashRequestV1
|
|
54788
|
+
* @throws {Error} If the payload is not a reader or valid buffer
|
|
54789
|
+
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
|
54790
|
+
*/
|
|
54791
|
+
GetIdentityByNonUniquePublicKeyHashRequestV1.decode = function decode(reader, length) {
|
|
54792
|
+
if (!(reader instanceof $Reader))
|
|
54793
|
+
reader = $Reader.create(reader);
|
|
54794
|
+
var end = length === undefined ? reader.len : reader.pos + length, message = new $root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.GetIdentityByNonUniquePublicKeyHashRequestV1();
|
|
54795
|
+
while (reader.pos < end) {
|
|
54796
|
+
var tag = reader.uint32();
|
|
54797
|
+
switch (tag >>> 3) {
|
|
54798
|
+
case 1:
|
|
54799
|
+
message.publicKeyHash = reader.bytes();
|
|
54800
|
+
break;
|
|
54801
|
+
case 2:
|
|
54802
|
+
message.startAfter = reader.bytes();
|
|
54803
|
+
break;
|
|
54804
|
+
case 3:
|
|
54805
|
+
message.prove = reader.bool();
|
|
54806
|
+
break;
|
|
54807
|
+
default:
|
|
54808
|
+
reader.skipType(tag & 7);
|
|
54809
|
+
break;
|
|
54810
|
+
}
|
|
54811
|
+
}
|
|
54812
|
+
return message;
|
|
54813
|
+
};
|
|
54814
|
+
|
|
54815
|
+
/**
|
|
54816
|
+
* Decodes a GetIdentityByNonUniquePublicKeyHashRequestV1 message from the specified reader or buffer, length delimited.
|
|
54817
|
+
* @function decodeDelimited
|
|
54818
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.GetIdentityByNonUniquePublicKeyHashRequestV1
|
|
54819
|
+
* @static
|
|
54820
|
+
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
|
|
54821
|
+
* @returns {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.GetIdentityByNonUniquePublicKeyHashRequestV1} GetIdentityByNonUniquePublicKeyHashRequestV1
|
|
54822
|
+
* @throws {Error} If the payload is not a reader or valid buffer
|
|
54823
|
+
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
|
54824
|
+
*/
|
|
54825
|
+
GetIdentityByNonUniquePublicKeyHashRequestV1.decodeDelimited = function decodeDelimited(reader) {
|
|
54826
|
+
if (!(reader instanceof $Reader))
|
|
54827
|
+
reader = new $Reader(reader);
|
|
54828
|
+
return this.decode(reader, reader.uint32());
|
|
54829
|
+
};
|
|
54830
|
+
|
|
54831
|
+
/**
|
|
54832
|
+
* Verifies a GetIdentityByNonUniquePublicKeyHashRequestV1 message.
|
|
54833
|
+
* @function verify
|
|
54834
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.GetIdentityByNonUniquePublicKeyHashRequestV1
|
|
54835
|
+
* @static
|
|
54836
|
+
* @param {Object.<string,*>} message Plain object to verify
|
|
54837
|
+
* @returns {string|null} `null` if valid, otherwise the reason why it is not
|
|
54838
|
+
*/
|
|
54839
|
+
GetIdentityByNonUniquePublicKeyHashRequestV1.verify = function verify(message) {
|
|
54840
|
+
if (typeof message !== "object" || message === null)
|
|
54841
|
+
return "object expected";
|
|
54842
|
+
if (message.publicKeyHash != null && message.hasOwnProperty("publicKeyHash"))
|
|
54843
|
+
if (!(message.publicKeyHash && typeof message.publicKeyHash.length === "number" || $util.isString(message.publicKeyHash)))
|
|
54844
|
+
return "publicKeyHash: buffer expected";
|
|
54845
|
+
if (message.startAfter != null && message.hasOwnProperty("startAfter"))
|
|
54846
|
+
if (!(message.startAfter && typeof message.startAfter.length === "number" || $util.isString(message.startAfter)))
|
|
54847
|
+
return "startAfter: buffer expected";
|
|
54848
|
+
if (message.prove != null && message.hasOwnProperty("prove"))
|
|
54849
|
+
if (typeof message.prove !== "boolean")
|
|
54850
|
+
return "prove: boolean expected";
|
|
54851
|
+
return null;
|
|
54852
|
+
};
|
|
54853
|
+
|
|
54854
|
+
/**
|
|
54855
|
+
* Creates a GetIdentityByNonUniquePublicKeyHashRequestV1 message from a plain object. Also converts values to their respective internal types.
|
|
54856
|
+
* @function fromObject
|
|
54857
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.GetIdentityByNonUniquePublicKeyHashRequestV1
|
|
54858
|
+
* @static
|
|
54859
|
+
* @param {Object.<string,*>} object Plain object
|
|
54860
|
+
* @returns {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.GetIdentityByNonUniquePublicKeyHashRequestV1} GetIdentityByNonUniquePublicKeyHashRequestV1
|
|
54861
|
+
*/
|
|
54862
|
+
GetIdentityByNonUniquePublicKeyHashRequestV1.fromObject = function fromObject(object) {
|
|
54863
|
+
if (object instanceof $root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.GetIdentityByNonUniquePublicKeyHashRequestV1)
|
|
54864
|
+
return object;
|
|
54865
|
+
var message = new $root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.GetIdentityByNonUniquePublicKeyHashRequestV1();
|
|
54866
|
+
if (object.publicKeyHash != null)
|
|
54867
|
+
if (typeof object.publicKeyHash === "string")
|
|
54868
|
+
$util.base64.decode(object.publicKeyHash, message.publicKeyHash = $util.newBuffer($util.base64.length(object.publicKeyHash)), 0);
|
|
54869
|
+
else if (object.publicKeyHash.length >= 0)
|
|
54870
|
+
message.publicKeyHash = object.publicKeyHash;
|
|
54871
|
+
if (object.startAfter != null)
|
|
54872
|
+
if (typeof object.startAfter === "string")
|
|
54873
|
+
$util.base64.decode(object.startAfter, message.startAfter = $util.newBuffer($util.base64.length(object.startAfter)), 0);
|
|
54874
|
+
else if (object.startAfter.length >= 0)
|
|
54875
|
+
message.startAfter = object.startAfter;
|
|
54876
|
+
if (object.prove != null)
|
|
54877
|
+
message.prove = Boolean(object.prove);
|
|
54878
|
+
return message;
|
|
54879
|
+
};
|
|
54880
|
+
|
|
54881
|
+
/**
|
|
54882
|
+
* Creates a plain object from a GetIdentityByNonUniquePublicKeyHashRequestV1 message. Also converts values to other types if specified.
|
|
54883
|
+
* @function toObject
|
|
54884
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.GetIdentityByNonUniquePublicKeyHashRequestV1
|
|
54885
|
+
* @static
|
|
54886
|
+
* @param {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.GetIdentityByNonUniquePublicKeyHashRequestV1} message GetIdentityByNonUniquePublicKeyHashRequestV1
|
|
54887
|
+
* @param {$protobuf.IConversionOptions} [options] Conversion options
|
|
54888
|
+
* @returns {Object.<string,*>} Plain object
|
|
54889
|
+
*/
|
|
54890
|
+
GetIdentityByNonUniquePublicKeyHashRequestV1.toObject = function toObject(message, options) {
|
|
54891
|
+
if (!options)
|
|
54892
|
+
options = {};
|
|
54893
|
+
var object = {};
|
|
54894
|
+
if (options.defaults) {
|
|
54895
|
+
if (options.bytes === String)
|
|
54896
|
+
object.publicKeyHash = "";
|
|
54897
|
+
else {
|
|
54898
|
+
object.publicKeyHash = [];
|
|
54899
|
+
if (options.bytes !== Array)
|
|
54900
|
+
object.publicKeyHash = $util.newBuffer(object.publicKeyHash);
|
|
54901
|
+
}
|
|
54902
|
+
if (options.bytes === String)
|
|
54903
|
+
object.startAfter = "";
|
|
54904
|
+
else {
|
|
54905
|
+
object.startAfter = [];
|
|
54906
|
+
if (options.bytes !== Array)
|
|
54907
|
+
object.startAfter = $util.newBuffer(object.startAfter);
|
|
54908
|
+
}
|
|
54909
|
+
object.prove = false;
|
|
54910
|
+
}
|
|
54911
|
+
if (message.publicKeyHash != null && message.hasOwnProperty("publicKeyHash"))
|
|
54912
|
+
object.publicKeyHash = options.bytes === String ? $util.base64.encode(message.publicKeyHash, 0, message.publicKeyHash.length) : options.bytes === Array ? Array.prototype.slice.call(message.publicKeyHash) : message.publicKeyHash;
|
|
54913
|
+
if (message.startAfter != null && message.hasOwnProperty("startAfter"))
|
|
54914
|
+
object.startAfter = options.bytes === String ? $util.base64.encode(message.startAfter, 0, message.startAfter.length) : options.bytes === Array ? Array.prototype.slice.call(message.startAfter) : message.startAfter;
|
|
54915
|
+
if (message.prove != null && message.hasOwnProperty("prove"))
|
|
54916
|
+
object.prove = message.prove;
|
|
54917
|
+
return object;
|
|
54918
|
+
};
|
|
54919
|
+
|
|
54920
|
+
/**
|
|
54921
|
+
* Converts this GetIdentityByNonUniquePublicKeyHashRequestV1 to JSON.
|
|
54922
|
+
* @function toJSON
|
|
54923
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashRequest.GetIdentityByNonUniquePublicKeyHashRequestV1
|
|
54924
|
+
* @instance
|
|
54925
|
+
* @returns {Object.<string,*>} JSON object
|
|
54926
|
+
*/
|
|
54927
|
+
GetIdentityByNonUniquePublicKeyHashRequestV1.prototype.toJSON = function toJSON() {
|
|
54928
|
+
return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
|
|
54929
|
+
};
|
|
54930
|
+
|
|
54931
|
+
return GetIdentityByNonUniquePublicKeyHashRequestV1;
|
|
54932
|
+
})();
|
|
54933
|
+
|
|
54650
54934
|
return GetIdentityByNonUniquePublicKeyHashRequest;
|
|
54651
54935
|
})();
|
|
54652
54936
|
|
|
@@ -54657,6 +54941,7 @@ $root.org = (function() {
|
|
|
54657
54941
|
* @memberof org.dash.platform.dapi.v0
|
|
54658
54942
|
* @interface IGetIdentityByNonUniquePublicKeyHashResponse
|
|
54659
54943
|
* @property {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.IGetIdentityByNonUniquePublicKeyHashResponseV0|null} [v0] GetIdentityByNonUniquePublicKeyHashResponse v0
|
|
54944
|
+
* @property {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.IGetIdentityByNonUniquePublicKeyHashResponseV1|null} [v1] GetIdentityByNonUniquePublicKeyHashResponse v1
|
|
54660
54945
|
*/
|
|
54661
54946
|
|
|
54662
54947
|
/**
|
|
@@ -54682,17 +54967,25 @@ $root.org = (function() {
|
|
|
54682
54967
|
*/
|
|
54683
54968
|
GetIdentityByNonUniquePublicKeyHashResponse.prototype.v0 = null;
|
|
54684
54969
|
|
|
54970
|
+
/**
|
|
54971
|
+
* GetIdentityByNonUniquePublicKeyHashResponse v1.
|
|
54972
|
+
* @member {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.IGetIdentityByNonUniquePublicKeyHashResponseV1|null|undefined} v1
|
|
54973
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse
|
|
54974
|
+
* @instance
|
|
54975
|
+
*/
|
|
54976
|
+
GetIdentityByNonUniquePublicKeyHashResponse.prototype.v1 = null;
|
|
54977
|
+
|
|
54685
54978
|
// OneOf field names bound to virtual getters and setters
|
|
54686
54979
|
var $oneOfFields;
|
|
54687
54980
|
|
|
54688
54981
|
/**
|
|
54689
54982
|
* GetIdentityByNonUniquePublicKeyHashResponse version.
|
|
54690
|
-
* @member {"v0"|undefined} version
|
|
54983
|
+
* @member {"v0"|"v1"|undefined} version
|
|
54691
54984
|
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse
|
|
54692
54985
|
* @instance
|
|
54693
54986
|
*/
|
|
54694
54987
|
Object.defineProperty(GetIdentityByNonUniquePublicKeyHashResponse.prototype, "version", {
|
|
54695
|
-
get: $util.oneOfGetter($oneOfFields = ["v0"]),
|
|
54988
|
+
get: $util.oneOfGetter($oneOfFields = ["v0", "v1"]),
|
|
54696
54989
|
set: $util.oneOfSetter($oneOfFields)
|
|
54697
54990
|
});
|
|
54698
54991
|
|
|
@@ -54722,6 +55015,8 @@ $root.org = (function() {
|
|
|
54722
55015
|
writer = $Writer.create();
|
|
54723
55016
|
if (message.v0 != null && Object.hasOwnProperty.call(message, "v0"))
|
|
54724
55017
|
$root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.encode(message.v0, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim();
|
|
55018
|
+
if (message.v1 != null && Object.hasOwnProperty.call(message, "v1"))
|
|
55019
|
+
$root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.encode(message.v1, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim();
|
|
54725
55020
|
return writer;
|
|
54726
55021
|
};
|
|
54727
55022
|
|
|
@@ -54759,6 +55054,9 @@ $root.org = (function() {
|
|
|
54759
55054
|
case 1:
|
|
54760
55055
|
message.v0 = $root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.decode(reader, reader.uint32());
|
|
54761
55056
|
break;
|
|
55057
|
+
case 2:
|
|
55058
|
+
message.v1 = $root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.decode(reader, reader.uint32());
|
|
55059
|
+
break;
|
|
54762
55060
|
default:
|
|
54763
55061
|
reader.skipType(tag & 7);
|
|
54764
55062
|
break;
|
|
@@ -54803,6 +55101,16 @@ $root.org = (function() {
|
|
|
54803
55101
|
return "v0." + error;
|
|
54804
55102
|
}
|
|
54805
55103
|
}
|
|
55104
|
+
if (message.v1 != null && message.hasOwnProperty("v1")) {
|
|
55105
|
+
if (properties.version === 1)
|
|
55106
|
+
return "version: multiple values";
|
|
55107
|
+
properties.version = 1;
|
|
55108
|
+
{
|
|
55109
|
+
var error = $root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.verify(message.v1);
|
|
55110
|
+
if (error)
|
|
55111
|
+
return "v1." + error;
|
|
55112
|
+
}
|
|
55113
|
+
}
|
|
54806
55114
|
return null;
|
|
54807
55115
|
};
|
|
54808
55116
|
|
|
@@ -54823,6 +55131,11 @@ $root.org = (function() {
|
|
|
54823
55131
|
throw TypeError(".org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.v0: object expected");
|
|
54824
55132
|
message.v0 = $root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.fromObject(object.v0);
|
|
54825
55133
|
}
|
|
55134
|
+
if (object.v1 != null) {
|
|
55135
|
+
if (typeof object.v1 !== "object")
|
|
55136
|
+
throw TypeError(".org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.v1: object expected");
|
|
55137
|
+
message.v1 = $root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.fromObject(object.v1);
|
|
55138
|
+
}
|
|
54826
55139
|
return message;
|
|
54827
55140
|
};
|
|
54828
55141
|
|
|
@@ -54844,6 +55157,11 @@ $root.org = (function() {
|
|
|
54844
55157
|
if (options.oneofs)
|
|
54845
55158
|
object.version = "v0";
|
|
54846
55159
|
}
|
|
55160
|
+
if (message.v1 != null && message.hasOwnProperty("v1")) {
|
|
55161
|
+
object.v1 = $root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.toObject(message.v1, options);
|
|
55162
|
+
if (options.oneofs)
|
|
55163
|
+
object.version = "v1";
|
|
55164
|
+
}
|
|
54847
55165
|
return object;
|
|
54848
55166
|
};
|
|
54849
55167
|
|
|
@@ -54865,7 +55183,7 @@ $root.org = (function() {
|
|
|
54865
55183
|
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse
|
|
54866
55184
|
* @interface IGetIdentityByNonUniquePublicKeyHashResponseV0
|
|
54867
55185
|
* @property {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.IIdentityResponse|null} [identity] GetIdentityByNonUniquePublicKeyHashResponseV0 identity
|
|
54868
|
-
* @property {org.dash.platform.dapi.v0.
|
|
55186
|
+
* @property {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.IIdentityProvedResponse|null} [proof] GetIdentityByNonUniquePublicKeyHashResponseV0 proof
|
|
54869
55187
|
* @property {org.dash.platform.dapi.v0.IResponseMetadata|null} [metadata] GetIdentityByNonUniquePublicKeyHashResponseV0 metadata
|
|
54870
55188
|
*/
|
|
54871
55189
|
|
|
@@ -54894,7 +55212,7 @@ $root.org = (function() {
|
|
|
54894
55212
|
|
|
54895
55213
|
/**
|
|
54896
55214
|
* GetIdentityByNonUniquePublicKeyHashResponseV0 proof.
|
|
54897
|
-
* @member {org.dash.platform.dapi.v0.
|
|
55215
|
+
* @member {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.IIdentityProvedResponse|null|undefined} proof
|
|
54898
55216
|
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0
|
|
54899
55217
|
* @instance
|
|
54900
55218
|
*/
|
|
@@ -54948,10 +55266,10 @@ $root.org = (function() {
|
|
|
54948
55266
|
writer = $Writer.create();
|
|
54949
55267
|
if (message.identity != null && Object.hasOwnProperty.call(message, "identity"))
|
|
54950
55268
|
$root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.IdentityResponse.encode(message.identity, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim();
|
|
55269
|
+
if (message.proof != null && Object.hasOwnProperty.call(message, "proof"))
|
|
55270
|
+
$root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.IdentityProvedResponse.encode(message.proof, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim();
|
|
54951
55271
|
if (message.metadata != null && Object.hasOwnProperty.call(message, "metadata"))
|
|
54952
55272
|
$root.org.dash.platform.dapi.v0.ResponseMetadata.encode(message.metadata, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim();
|
|
54953
|
-
if (message.proof != null && Object.hasOwnProperty.call(message, "proof"))
|
|
54954
|
-
$root.org.dash.platform.dapi.v0.Proof.encode(message.proof, writer.uint32(/* id 4, wireType 2 =*/34).fork()).ldelim();
|
|
54955
55273
|
return writer;
|
|
54956
55274
|
};
|
|
54957
55275
|
|
|
@@ -54989,8 +55307,8 @@ $root.org = (function() {
|
|
|
54989
55307
|
case 1:
|
|
54990
55308
|
message.identity = $root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.IdentityResponse.decode(reader, reader.uint32());
|
|
54991
55309
|
break;
|
|
54992
|
-
case
|
|
54993
|
-
message.proof = $root.org.dash.platform.dapi.v0.
|
|
55310
|
+
case 2:
|
|
55311
|
+
message.proof = $root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.IdentityProvedResponse.decode(reader, reader.uint32());
|
|
54994
55312
|
break;
|
|
54995
55313
|
case 3:
|
|
54996
55314
|
message.metadata = $root.org.dash.platform.dapi.v0.ResponseMetadata.decode(reader, reader.uint32());
|
|
@@ -55044,7 +55362,7 @@ $root.org = (function() {
|
|
|
55044
55362
|
return "result: multiple values";
|
|
55045
55363
|
properties.result = 1;
|
|
55046
55364
|
{
|
|
55047
|
-
var error = $root.org.dash.platform.dapi.v0.
|
|
55365
|
+
var error = $root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.IdentityProvedResponse.verify(message.proof);
|
|
55048
55366
|
if (error)
|
|
55049
55367
|
return "proof." + error;
|
|
55050
55368
|
}
|
|
@@ -55077,7 +55395,7 @@ $root.org = (function() {
|
|
|
55077
55395
|
if (object.proof != null) {
|
|
55078
55396
|
if (typeof object.proof !== "object")
|
|
55079
55397
|
throw TypeError(".org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.proof: object expected");
|
|
55080
|
-
message.proof = $root.org.dash.platform.dapi.v0.
|
|
55398
|
+
message.proof = $root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.IdentityProvedResponse.fromObject(object.proof);
|
|
55081
55399
|
}
|
|
55082
55400
|
if (object.metadata != null) {
|
|
55083
55401
|
if (typeof object.metadata !== "object")
|
|
@@ -55107,13 +55425,13 @@ $root.org = (function() {
|
|
|
55107
55425
|
if (options.oneofs)
|
|
55108
55426
|
object.result = "identity";
|
|
55109
55427
|
}
|
|
55110
|
-
if (message.metadata != null && message.hasOwnProperty("metadata"))
|
|
55111
|
-
object.metadata = $root.org.dash.platform.dapi.v0.ResponseMetadata.toObject(message.metadata, options);
|
|
55112
55428
|
if (message.proof != null && message.hasOwnProperty("proof")) {
|
|
55113
|
-
object.proof = $root.org.dash.platform.dapi.v0.
|
|
55429
|
+
object.proof = $root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.IdentityProvedResponse.toObject(message.proof, options);
|
|
55114
55430
|
if (options.oneofs)
|
|
55115
55431
|
object.result = "proof";
|
|
55116
55432
|
}
|
|
55433
|
+
if (message.metadata != null && message.hasOwnProperty("metadata"))
|
|
55434
|
+
object.metadata = $root.org.dash.platform.dapi.v0.ResponseMetadata.toObject(message.metadata, options);
|
|
55117
55435
|
return object;
|
|
55118
55436
|
};
|
|
55119
55437
|
|
|
@@ -55324,9 +55642,702 @@ $root.org = (function() {
|
|
|
55324
55642
|
return IdentityResponse;
|
|
55325
55643
|
})();
|
|
55326
55644
|
|
|
55645
|
+
GetIdentityByNonUniquePublicKeyHashResponseV0.IdentityProvedResponse = (function() {
|
|
55646
|
+
|
|
55647
|
+
/**
|
|
55648
|
+
* Properties of an IdentityProvedResponse.
|
|
55649
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0
|
|
55650
|
+
* @interface IIdentityProvedResponse
|
|
55651
|
+
* @property {org.dash.platform.dapi.v0.IProof|null} [grovedbIdentityPublicKeyHashProof] IdentityProvedResponse grovedbIdentityPublicKeyHashProof
|
|
55652
|
+
* @property {Uint8Array|null} [identityProofBytes] IdentityProvedResponse identityProofBytes
|
|
55653
|
+
*/
|
|
55654
|
+
|
|
55655
|
+
/**
|
|
55656
|
+
* Constructs a new IdentityProvedResponse.
|
|
55657
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0
|
|
55658
|
+
* @classdesc Represents an IdentityProvedResponse.
|
|
55659
|
+
* @implements IIdentityProvedResponse
|
|
55660
|
+
* @constructor
|
|
55661
|
+
* @param {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.IIdentityProvedResponse=} [properties] Properties to set
|
|
55662
|
+
*/
|
|
55663
|
+
function IdentityProvedResponse(properties) {
|
|
55664
|
+
if (properties)
|
|
55665
|
+
for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
|
|
55666
|
+
if (properties[keys[i]] != null)
|
|
55667
|
+
this[keys[i]] = properties[keys[i]];
|
|
55668
|
+
}
|
|
55669
|
+
|
|
55670
|
+
/**
|
|
55671
|
+
* IdentityProvedResponse grovedbIdentityPublicKeyHashProof.
|
|
55672
|
+
* @member {org.dash.platform.dapi.v0.IProof|null|undefined} grovedbIdentityPublicKeyHashProof
|
|
55673
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.IdentityProvedResponse
|
|
55674
|
+
* @instance
|
|
55675
|
+
*/
|
|
55676
|
+
IdentityProvedResponse.prototype.grovedbIdentityPublicKeyHashProof = null;
|
|
55677
|
+
|
|
55678
|
+
/**
|
|
55679
|
+
* IdentityProvedResponse identityProofBytes.
|
|
55680
|
+
* @member {Uint8Array} identityProofBytes
|
|
55681
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.IdentityProvedResponse
|
|
55682
|
+
* @instance
|
|
55683
|
+
*/
|
|
55684
|
+
IdentityProvedResponse.prototype.identityProofBytes = $util.newBuffer([]);
|
|
55685
|
+
|
|
55686
|
+
/**
|
|
55687
|
+
* Creates a new IdentityProvedResponse instance using the specified properties.
|
|
55688
|
+
* @function create
|
|
55689
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.IdentityProvedResponse
|
|
55690
|
+
* @static
|
|
55691
|
+
* @param {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.IIdentityProvedResponse=} [properties] Properties to set
|
|
55692
|
+
* @returns {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.IdentityProvedResponse} IdentityProvedResponse instance
|
|
55693
|
+
*/
|
|
55694
|
+
IdentityProvedResponse.create = function create(properties) {
|
|
55695
|
+
return new IdentityProvedResponse(properties);
|
|
55696
|
+
};
|
|
55697
|
+
|
|
55698
|
+
/**
|
|
55699
|
+
* Encodes the specified IdentityProvedResponse message. Does not implicitly {@link org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.IdentityProvedResponse.verify|verify} messages.
|
|
55700
|
+
* @function encode
|
|
55701
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.IdentityProvedResponse
|
|
55702
|
+
* @static
|
|
55703
|
+
* @param {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.IIdentityProvedResponse} message IdentityProvedResponse message or plain object to encode
|
|
55704
|
+
* @param {$protobuf.Writer} [writer] Writer to encode to
|
|
55705
|
+
* @returns {$protobuf.Writer} Writer
|
|
55706
|
+
*/
|
|
55707
|
+
IdentityProvedResponse.encode = function encode(message, writer) {
|
|
55708
|
+
if (!writer)
|
|
55709
|
+
writer = $Writer.create();
|
|
55710
|
+
if (message.grovedbIdentityPublicKeyHashProof != null && Object.hasOwnProperty.call(message, "grovedbIdentityPublicKeyHashProof"))
|
|
55711
|
+
$root.org.dash.platform.dapi.v0.Proof.encode(message.grovedbIdentityPublicKeyHashProof, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim();
|
|
55712
|
+
if (message.identityProofBytes != null && Object.hasOwnProperty.call(message, "identityProofBytes"))
|
|
55713
|
+
writer.uint32(/* id 2, wireType 2 =*/18).bytes(message.identityProofBytes);
|
|
55714
|
+
return writer;
|
|
55715
|
+
};
|
|
55716
|
+
|
|
55717
|
+
/**
|
|
55718
|
+
* Encodes the specified IdentityProvedResponse message, length delimited. Does not implicitly {@link org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.IdentityProvedResponse.verify|verify} messages.
|
|
55719
|
+
* @function encodeDelimited
|
|
55720
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.IdentityProvedResponse
|
|
55721
|
+
* @static
|
|
55722
|
+
* @param {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.IIdentityProvedResponse} message IdentityProvedResponse message or plain object to encode
|
|
55723
|
+
* @param {$protobuf.Writer} [writer] Writer to encode to
|
|
55724
|
+
* @returns {$protobuf.Writer} Writer
|
|
55725
|
+
*/
|
|
55726
|
+
IdentityProvedResponse.encodeDelimited = function encodeDelimited(message, writer) {
|
|
55727
|
+
return this.encode(message, writer).ldelim();
|
|
55728
|
+
};
|
|
55729
|
+
|
|
55730
|
+
/**
|
|
55731
|
+
* Decodes an IdentityProvedResponse message from the specified reader or buffer.
|
|
55732
|
+
* @function decode
|
|
55733
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.IdentityProvedResponse
|
|
55734
|
+
* @static
|
|
55735
|
+
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
|
|
55736
|
+
* @param {number} [length] Message length if known beforehand
|
|
55737
|
+
* @returns {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.IdentityProvedResponse} IdentityProvedResponse
|
|
55738
|
+
* @throws {Error} If the payload is not a reader or valid buffer
|
|
55739
|
+
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
|
55740
|
+
*/
|
|
55741
|
+
IdentityProvedResponse.decode = function decode(reader, length) {
|
|
55742
|
+
if (!(reader instanceof $Reader))
|
|
55743
|
+
reader = $Reader.create(reader);
|
|
55744
|
+
var end = length === undefined ? reader.len : reader.pos + length, message = new $root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.IdentityProvedResponse();
|
|
55745
|
+
while (reader.pos < end) {
|
|
55746
|
+
var tag = reader.uint32();
|
|
55747
|
+
switch (tag >>> 3) {
|
|
55748
|
+
case 1:
|
|
55749
|
+
message.grovedbIdentityPublicKeyHashProof = $root.org.dash.platform.dapi.v0.Proof.decode(reader, reader.uint32());
|
|
55750
|
+
break;
|
|
55751
|
+
case 2:
|
|
55752
|
+
message.identityProofBytes = reader.bytes();
|
|
55753
|
+
break;
|
|
55754
|
+
default:
|
|
55755
|
+
reader.skipType(tag & 7);
|
|
55756
|
+
break;
|
|
55757
|
+
}
|
|
55758
|
+
}
|
|
55759
|
+
return message;
|
|
55760
|
+
};
|
|
55761
|
+
|
|
55762
|
+
/**
|
|
55763
|
+
* Decodes an IdentityProvedResponse message from the specified reader or buffer, length delimited.
|
|
55764
|
+
* @function decodeDelimited
|
|
55765
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.IdentityProvedResponse
|
|
55766
|
+
* @static
|
|
55767
|
+
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
|
|
55768
|
+
* @returns {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.IdentityProvedResponse} IdentityProvedResponse
|
|
55769
|
+
* @throws {Error} If the payload is not a reader or valid buffer
|
|
55770
|
+
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
|
55771
|
+
*/
|
|
55772
|
+
IdentityProvedResponse.decodeDelimited = function decodeDelimited(reader) {
|
|
55773
|
+
if (!(reader instanceof $Reader))
|
|
55774
|
+
reader = new $Reader(reader);
|
|
55775
|
+
return this.decode(reader, reader.uint32());
|
|
55776
|
+
};
|
|
55777
|
+
|
|
55778
|
+
/**
|
|
55779
|
+
* Verifies an IdentityProvedResponse message.
|
|
55780
|
+
* @function verify
|
|
55781
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.IdentityProvedResponse
|
|
55782
|
+
* @static
|
|
55783
|
+
* @param {Object.<string,*>} message Plain object to verify
|
|
55784
|
+
* @returns {string|null} `null` if valid, otherwise the reason why it is not
|
|
55785
|
+
*/
|
|
55786
|
+
IdentityProvedResponse.verify = function verify(message) {
|
|
55787
|
+
if (typeof message !== "object" || message === null)
|
|
55788
|
+
return "object expected";
|
|
55789
|
+
if (message.grovedbIdentityPublicKeyHashProof != null && message.hasOwnProperty("grovedbIdentityPublicKeyHashProof")) {
|
|
55790
|
+
var error = $root.org.dash.platform.dapi.v0.Proof.verify(message.grovedbIdentityPublicKeyHashProof);
|
|
55791
|
+
if (error)
|
|
55792
|
+
return "grovedbIdentityPublicKeyHashProof." + error;
|
|
55793
|
+
}
|
|
55794
|
+
if (message.identityProofBytes != null && message.hasOwnProperty("identityProofBytes"))
|
|
55795
|
+
if (!(message.identityProofBytes && typeof message.identityProofBytes.length === "number" || $util.isString(message.identityProofBytes)))
|
|
55796
|
+
return "identityProofBytes: buffer expected";
|
|
55797
|
+
return null;
|
|
55798
|
+
};
|
|
55799
|
+
|
|
55800
|
+
/**
|
|
55801
|
+
* Creates an IdentityProvedResponse message from a plain object. Also converts values to their respective internal types.
|
|
55802
|
+
* @function fromObject
|
|
55803
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.IdentityProvedResponse
|
|
55804
|
+
* @static
|
|
55805
|
+
* @param {Object.<string,*>} object Plain object
|
|
55806
|
+
* @returns {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.IdentityProvedResponse} IdentityProvedResponse
|
|
55807
|
+
*/
|
|
55808
|
+
IdentityProvedResponse.fromObject = function fromObject(object) {
|
|
55809
|
+
if (object instanceof $root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.IdentityProvedResponse)
|
|
55810
|
+
return object;
|
|
55811
|
+
var message = new $root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.IdentityProvedResponse();
|
|
55812
|
+
if (object.grovedbIdentityPublicKeyHashProof != null) {
|
|
55813
|
+
if (typeof object.grovedbIdentityPublicKeyHashProof !== "object")
|
|
55814
|
+
throw TypeError(".org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.IdentityProvedResponse.grovedbIdentityPublicKeyHashProof: object expected");
|
|
55815
|
+
message.grovedbIdentityPublicKeyHashProof = $root.org.dash.platform.dapi.v0.Proof.fromObject(object.grovedbIdentityPublicKeyHashProof);
|
|
55816
|
+
}
|
|
55817
|
+
if (object.identityProofBytes != null)
|
|
55818
|
+
if (typeof object.identityProofBytes === "string")
|
|
55819
|
+
$util.base64.decode(object.identityProofBytes, message.identityProofBytes = $util.newBuffer($util.base64.length(object.identityProofBytes)), 0);
|
|
55820
|
+
else if (object.identityProofBytes.length >= 0)
|
|
55821
|
+
message.identityProofBytes = object.identityProofBytes;
|
|
55822
|
+
return message;
|
|
55823
|
+
};
|
|
55824
|
+
|
|
55825
|
+
/**
|
|
55826
|
+
* Creates a plain object from an IdentityProvedResponse message. Also converts values to other types if specified.
|
|
55827
|
+
* @function toObject
|
|
55828
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.IdentityProvedResponse
|
|
55829
|
+
* @static
|
|
55830
|
+
* @param {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.IdentityProvedResponse} message IdentityProvedResponse
|
|
55831
|
+
* @param {$protobuf.IConversionOptions} [options] Conversion options
|
|
55832
|
+
* @returns {Object.<string,*>} Plain object
|
|
55833
|
+
*/
|
|
55834
|
+
IdentityProvedResponse.toObject = function toObject(message, options) {
|
|
55835
|
+
if (!options)
|
|
55836
|
+
options = {};
|
|
55837
|
+
var object = {};
|
|
55838
|
+
if (options.defaults) {
|
|
55839
|
+
object.grovedbIdentityPublicKeyHashProof = null;
|
|
55840
|
+
if (options.bytes === String)
|
|
55841
|
+
object.identityProofBytes = "";
|
|
55842
|
+
else {
|
|
55843
|
+
object.identityProofBytes = [];
|
|
55844
|
+
if (options.bytes !== Array)
|
|
55845
|
+
object.identityProofBytes = $util.newBuffer(object.identityProofBytes);
|
|
55846
|
+
}
|
|
55847
|
+
}
|
|
55848
|
+
if (message.grovedbIdentityPublicKeyHashProof != null && message.hasOwnProperty("grovedbIdentityPublicKeyHashProof"))
|
|
55849
|
+
object.grovedbIdentityPublicKeyHashProof = $root.org.dash.platform.dapi.v0.Proof.toObject(message.grovedbIdentityPublicKeyHashProof, options);
|
|
55850
|
+
if (message.identityProofBytes != null && message.hasOwnProperty("identityProofBytes"))
|
|
55851
|
+
object.identityProofBytes = options.bytes === String ? $util.base64.encode(message.identityProofBytes, 0, message.identityProofBytes.length) : options.bytes === Array ? Array.prototype.slice.call(message.identityProofBytes) : message.identityProofBytes;
|
|
55852
|
+
return object;
|
|
55853
|
+
};
|
|
55854
|
+
|
|
55855
|
+
/**
|
|
55856
|
+
* Converts this IdentityProvedResponse to JSON.
|
|
55857
|
+
* @function toJSON
|
|
55858
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV0.IdentityProvedResponse
|
|
55859
|
+
* @instance
|
|
55860
|
+
* @returns {Object.<string,*>} JSON object
|
|
55861
|
+
*/
|
|
55862
|
+
IdentityProvedResponse.prototype.toJSON = function toJSON() {
|
|
55863
|
+
return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
|
|
55864
|
+
};
|
|
55865
|
+
|
|
55866
|
+
return IdentityProvedResponse;
|
|
55867
|
+
})();
|
|
55868
|
+
|
|
55327
55869
|
return GetIdentityByNonUniquePublicKeyHashResponseV0;
|
|
55328
55870
|
})();
|
|
55329
55871
|
|
|
55872
|
+
GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1 = (function() {
|
|
55873
|
+
|
|
55874
|
+
/**
|
|
55875
|
+
* Properties of a GetIdentityByNonUniquePublicKeyHashResponseV1.
|
|
55876
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse
|
|
55877
|
+
* @interface IGetIdentityByNonUniquePublicKeyHashResponseV1
|
|
55878
|
+
* @property {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.IIdentityResponse|null} [identity] GetIdentityByNonUniquePublicKeyHashResponseV1 identity
|
|
55879
|
+
* @property {org.dash.platform.dapi.v0.IProof|null} [proof] GetIdentityByNonUniquePublicKeyHashResponseV1 proof
|
|
55880
|
+
* @property {org.dash.platform.dapi.v0.IResponseMetadata|null} [metadata] GetIdentityByNonUniquePublicKeyHashResponseV1 metadata
|
|
55881
|
+
*/
|
|
55882
|
+
|
|
55883
|
+
/**
|
|
55884
|
+
* Constructs a new GetIdentityByNonUniquePublicKeyHashResponseV1.
|
|
55885
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse
|
|
55886
|
+
* @classdesc Represents a GetIdentityByNonUniquePublicKeyHashResponseV1.
|
|
55887
|
+
* @implements IGetIdentityByNonUniquePublicKeyHashResponseV1
|
|
55888
|
+
* @constructor
|
|
55889
|
+
* @param {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.IGetIdentityByNonUniquePublicKeyHashResponseV1=} [properties] Properties to set
|
|
55890
|
+
*/
|
|
55891
|
+
function GetIdentityByNonUniquePublicKeyHashResponseV1(properties) {
|
|
55892
|
+
if (properties)
|
|
55893
|
+
for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
|
|
55894
|
+
if (properties[keys[i]] != null)
|
|
55895
|
+
this[keys[i]] = properties[keys[i]];
|
|
55896
|
+
}
|
|
55897
|
+
|
|
55898
|
+
/**
|
|
55899
|
+
* GetIdentityByNonUniquePublicKeyHashResponseV1 identity.
|
|
55900
|
+
* @member {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.IIdentityResponse|null|undefined} identity
|
|
55901
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1
|
|
55902
|
+
* @instance
|
|
55903
|
+
*/
|
|
55904
|
+
GetIdentityByNonUniquePublicKeyHashResponseV1.prototype.identity = null;
|
|
55905
|
+
|
|
55906
|
+
/**
|
|
55907
|
+
* GetIdentityByNonUniquePublicKeyHashResponseV1 proof.
|
|
55908
|
+
* @member {org.dash.platform.dapi.v0.IProof|null|undefined} proof
|
|
55909
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1
|
|
55910
|
+
* @instance
|
|
55911
|
+
*/
|
|
55912
|
+
GetIdentityByNonUniquePublicKeyHashResponseV1.prototype.proof = null;
|
|
55913
|
+
|
|
55914
|
+
/**
|
|
55915
|
+
* GetIdentityByNonUniquePublicKeyHashResponseV1 metadata.
|
|
55916
|
+
* @member {org.dash.platform.dapi.v0.IResponseMetadata|null|undefined} metadata
|
|
55917
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1
|
|
55918
|
+
* @instance
|
|
55919
|
+
*/
|
|
55920
|
+
GetIdentityByNonUniquePublicKeyHashResponseV1.prototype.metadata = null;
|
|
55921
|
+
|
|
55922
|
+
// OneOf field names bound to virtual getters and setters
|
|
55923
|
+
var $oneOfFields;
|
|
55924
|
+
|
|
55925
|
+
/**
|
|
55926
|
+
* GetIdentityByNonUniquePublicKeyHashResponseV1 result.
|
|
55927
|
+
* @member {"identity"|"proof"|undefined} result
|
|
55928
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1
|
|
55929
|
+
* @instance
|
|
55930
|
+
*/
|
|
55931
|
+
Object.defineProperty(GetIdentityByNonUniquePublicKeyHashResponseV1.prototype, "result", {
|
|
55932
|
+
get: $util.oneOfGetter($oneOfFields = ["identity", "proof"]),
|
|
55933
|
+
set: $util.oneOfSetter($oneOfFields)
|
|
55934
|
+
});
|
|
55935
|
+
|
|
55936
|
+
/**
|
|
55937
|
+
* Creates a new GetIdentityByNonUniquePublicKeyHashResponseV1 instance using the specified properties.
|
|
55938
|
+
* @function create
|
|
55939
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1
|
|
55940
|
+
* @static
|
|
55941
|
+
* @param {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.IGetIdentityByNonUniquePublicKeyHashResponseV1=} [properties] Properties to set
|
|
55942
|
+
* @returns {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1} GetIdentityByNonUniquePublicKeyHashResponseV1 instance
|
|
55943
|
+
*/
|
|
55944
|
+
GetIdentityByNonUniquePublicKeyHashResponseV1.create = function create(properties) {
|
|
55945
|
+
return new GetIdentityByNonUniquePublicKeyHashResponseV1(properties);
|
|
55946
|
+
};
|
|
55947
|
+
|
|
55948
|
+
/**
|
|
55949
|
+
* Encodes the specified GetIdentityByNonUniquePublicKeyHashResponseV1 message. Does not implicitly {@link org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.verify|verify} messages.
|
|
55950
|
+
* @function encode
|
|
55951
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1
|
|
55952
|
+
* @static
|
|
55953
|
+
* @param {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.IGetIdentityByNonUniquePublicKeyHashResponseV1} message GetIdentityByNonUniquePublicKeyHashResponseV1 message or plain object to encode
|
|
55954
|
+
* @param {$protobuf.Writer} [writer] Writer to encode to
|
|
55955
|
+
* @returns {$protobuf.Writer} Writer
|
|
55956
|
+
*/
|
|
55957
|
+
GetIdentityByNonUniquePublicKeyHashResponseV1.encode = function encode(message, writer) {
|
|
55958
|
+
if (!writer)
|
|
55959
|
+
writer = $Writer.create();
|
|
55960
|
+
if (message.identity != null && Object.hasOwnProperty.call(message, "identity"))
|
|
55961
|
+
$root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.IdentityResponse.encode(message.identity, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim();
|
|
55962
|
+
if (message.proof != null && Object.hasOwnProperty.call(message, "proof"))
|
|
55963
|
+
$root.org.dash.platform.dapi.v0.Proof.encode(message.proof, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim();
|
|
55964
|
+
if (message.metadata != null && Object.hasOwnProperty.call(message, "metadata"))
|
|
55965
|
+
$root.org.dash.platform.dapi.v0.ResponseMetadata.encode(message.metadata, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim();
|
|
55966
|
+
return writer;
|
|
55967
|
+
};
|
|
55968
|
+
|
|
55969
|
+
/**
|
|
55970
|
+
* Encodes the specified GetIdentityByNonUniquePublicKeyHashResponseV1 message, length delimited. Does not implicitly {@link org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.verify|verify} messages.
|
|
55971
|
+
* @function encodeDelimited
|
|
55972
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1
|
|
55973
|
+
* @static
|
|
55974
|
+
* @param {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.IGetIdentityByNonUniquePublicKeyHashResponseV1} message GetIdentityByNonUniquePublicKeyHashResponseV1 message or plain object to encode
|
|
55975
|
+
* @param {$protobuf.Writer} [writer] Writer to encode to
|
|
55976
|
+
* @returns {$protobuf.Writer} Writer
|
|
55977
|
+
*/
|
|
55978
|
+
GetIdentityByNonUniquePublicKeyHashResponseV1.encodeDelimited = function encodeDelimited(message, writer) {
|
|
55979
|
+
return this.encode(message, writer).ldelim();
|
|
55980
|
+
};
|
|
55981
|
+
|
|
55982
|
+
/**
|
|
55983
|
+
* Decodes a GetIdentityByNonUniquePublicKeyHashResponseV1 message from the specified reader or buffer.
|
|
55984
|
+
* @function decode
|
|
55985
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1
|
|
55986
|
+
* @static
|
|
55987
|
+
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
|
|
55988
|
+
* @param {number} [length] Message length if known beforehand
|
|
55989
|
+
* @returns {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1} GetIdentityByNonUniquePublicKeyHashResponseV1
|
|
55990
|
+
* @throws {Error} If the payload is not a reader or valid buffer
|
|
55991
|
+
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
|
55992
|
+
*/
|
|
55993
|
+
GetIdentityByNonUniquePublicKeyHashResponseV1.decode = function decode(reader, length) {
|
|
55994
|
+
if (!(reader instanceof $Reader))
|
|
55995
|
+
reader = $Reader.create(reader);
|
|
55996
|
+
var end = length === undefined ? reader.len : reader.pos + length, message = new $root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1();
|
|
55997
|
+
while (reader.pos < end) {
|
|
55998
|
+
var tag = reader.uint32();
|
|
55999
|
+
switch (tag >>> 3) {
|
|
56000
|
+
case 1:
|
|
56001
|
+
message.identity = $root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.IdentityResponse.decode(reader, reader.uint32());
|
|
56002
|
+
break;
|
|
56003
|
+
case 2:
|
|
56004
|
+
message.proof = $root.org.dash.platform.dapi.v0.Proof.decode(reader, reader.uint32());
|
|
56005
|
+
break;
|
|
56006
|
+
case 3:
|
|
56007
|
+
message.metadata = $root.org.dash.platform.dapi.v0.ResponseMetadata.decode(reader, reader.uint32());
|
|
56008
|
+
break;
|
|
56009
|
+
default:
|
|
56010
|
+
reader.skipType(tag & 7);
|
|
56011
|
+
break;
|
|
56012
|
+
}
|
|
56013
|
+
}
|
|
56014
|
+
return message;
|
|
56015
|
+
};
|
|
56016
|
+
|
|
56017
|
+
/**
|
|
56018
|
+
* Decodes a GetIdentityByNonUniquePublicKeyHashResponseV1 message from the specified reader or buffer, length delimited.
|
|
56019
|
+
* @function decodeDelimited
|
|
56020
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1
|
|
56021
|
+
* @static
|
|
56022
|
+
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
|
|
56023
|
+
* @returns {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1} GetIdentityByNonUniquePublicKeyHashResponseV1
|
|
56024
|
+
* @throws {Error} If the payload is not a reader or valid buffer
|
|
56025
|
+
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
|
56026
|
+
*/
|
|
56027
|
+
GetIdentityByNonUniquePublicKeyHashResponseV1.decodeDelimited = function decodeDelimited(reader) {
|
|
56028
|
+
if (!(reader instanceof $Reader))
|
|
56029
|
+
reader = new $Reader(reader);
|
|
56030
|
+
return this.decode(reader, reader.uint32());
|
|
56031
|
+
};
|
|
56032
|
+
|
|
56033
|
+
/**
|
|
56034
|
+
* Verifies a GetIdentityByNonUniquePublicKeyHashResponseV1 message.
|
|
56035
|
+
* @function verify
|
|
56036
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1
|
|
56037
|
+
* @static
|
|
56038
|
+
* @param {Object.<string,*>} message Plain object to verify
|
|
56039
|
+
* @returns {string|null} `null` if valid, otherwise the reason why it is not
|
|
56040
|
+
*/
|
|
56041
|
+
GetIdentityByNonUniquePublicKeyHashResponseV1.verify = function verify(message) {
|
|
56042
|
+
if (typeof message !== "object" || message === null)
|
|
56043
|
+
return "object expected";
|
|
56044
|
+
var properties = {};
|
|
56045
|
+
if (message.identity != null && message.hasOwnProperty("identity")) {
|
|
56046
|
+
properties.result = 1;
|
|
56047
|
+
{
|
|
56048
|
+
var error = $root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.IdentityResponse.verify(message.identity);
|
|
56049
|
+
if (error)
|
|
56050
|
+
return "identity." + error;
|
|
56051
|
+
}
|
|
56052
|
+
}
|
|
56053
|
+
if (message.proof != null && message.hasOwnProperty("proof")) {
|
|
56054
|
+
if (properties.result === 1)
|
|
56055
|
+
return "result: multiple values";
|
|
56056
|
+
properties.result = 1;
|
|
56057
|
+
{
|
|
56058
|
+
var error = $root.org.dash.platform.dapi.v0.Proof.verify(message.proof);
|
|
56059
|
+
if (error)
|
|
56060
|
+
return "proof." + error;
|
|
56061
|
+
}
|
|
56062
|
+
}
|
|
56063
|
+
if (message.metadata != null && message.hasOwnProperty("metadata")) {
|
|
56064
|
+
var error = $root.org.dash.platform.dapi.v0.ResponseMetadata.verify(message.metadata);
|
|
56065
|
+
if (error)
|
|
56066
|
+
return "metadata." + error;
|
|
56067
|
+
}
|
|
56068
|
+
return null;
|
|
56069
|
+
};
|
|
56070
|
+
|
|
56071
|
+
/**
|
|
56072
|
+
* Creates a GetIdentityByNonUniquePublicKeyHashResponseV1 message from a plain object. Also converts values to their respective internal types.
|
|
56073
|
+
* @function fromObject
|
|
56074
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1
|
|
56075
|
+
* @static
|
|
56076
|
+
* @param {Object.<string,*>} object Plain object
|
|
56077
|
+
* @returns {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1} GetIdentityByNonUniquePublicKeyHashResponseV1
|
|
56078
|
+
*/
|
|
56079
|
+
GetIdentityByNonUniquePublicKeyHashResponseV1.fromObject = function fromObject(object) {
|
|
56080
|
+
if (object instanceof $root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1)
|
|
56081
|
+
return object;
|
|
56082
|
+
var message = new $root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1();
|
|
56083
|
+
if (object.identity != null) {
|
|
56084
|
+
if (typeof object.identity !== "object")
|
|
56085
|
+
throw TypeError(".org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.identity: object expected");
|
|
56086
|
+
message.identity = $root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.IdentityResponse.fromObject(object.identity);
|
|
56087
|
+
}
|
|
56088
|
+
if (object.proof != null) {
|
|
56089
|
+
if (typeof object.proof !== "object")
|
|
56090
|
+
throw TypeError(".org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.proof: object expected");
|
|
56091
|
+
message.proof = $root.org.dash.platform.dapi.v0.Proof.fromObject(object.proof);
|
|
56092
|
+
}
|
|
56093
|
+
if (object.metadata != null) {
|
|
56094
|
+
if (typeof object.metadata !== "object")
|
|
56095
|
+
throw TypeError(".org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.metadata: object expected");
|
|
56096
|
+
message.metadata = $root.org.dash.platform.dapi.v0.ResponseMetadata.fromObject(object.metadata);
|
|
56097
|
+
}
|
|
56098
|
+
return message;
|
|
56099
|
+
};
|
|
56100
|
+
|
|
56101
|
+
/**
|
|
56102
|
+
* Creates a plain object from a GetIdentityByNonUniquePublicKeyHashResponseV1 message. Also converts values to other types if specified.
|
|
56103
|
+
* @function toObject
|
|
56104
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1
|
|
56105
|
+
* @static
|
|
56106
|
+
* @param {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1} message GetIdentityByNonUniquePublicKeyHashResponseV1
|
|
56107
|
+
* @param {$protobuf.IConversionOptions} [options] Conversion options
|
|
56108
|
+
* @returns {Object.<string,*>} Plain object
|
|
56109
|
+
*/
|
|
56110
|
+
GetIdentityByNonUniquePublicKeyHashResponseV1.toObject = function toObject(message, options) {
|
|
56111
|
+
if (!options)
|
|
56112
|
+
options = {};
|
|
56113
|
+
var object = {};
|
|
56114
|
+
if (options.defaults)
|
|
56115
|
+
object.metadata = null;
|
|
56116
|
+
if (message.identity != null && message.hasOwnProperty("identity")) {
|
|
56117
|
+
object.identity = $root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.IdentityResponse.toObject(message.identity, options);
|
|
56118
|
+
if (options.oneofs)
|
|
56119
|
+
object.result = "identity";
|
|
56120
|
+
}
|
|
56121
|
+
if (message.proof != null && message.hasOwnProperty("proof")) {
|
|
56122
|
+
object.proof = $root.org.dash.platform.dapi.v0.Proof.toObject(message.proof, options);
|
|
56123
|
+
if (options.oneofs)
|
|
56124
|
+
object.result = "proof";
|
|
56125
|
+
}
|
|
56126
|
+
if (message.metadata != null && message.hasOwnProperty("metadata"))
|
|
56127
|
+
object.metadata = $root.org.dash.platform.dapi.v0.ResponseMetadata.toObject(message.metadata, options);
|
|
56128
|
+
return object;
|
|
56129
|
+
};
|
|
56130
|
+
|
|
56131
|
+
/**
|
|
56132
|
+
* Converts this GetIdentityByNonUniquePublicKeyHashResponseV1 to JSON.
|
|
56133
|
+
* @function toJSON
|
|
56134
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1
|
|
56135
|
+
* @instance
|
|
56136
|
+
* @returns {Object.<string,*>} JSON object
|
|
56137
|
+
*/
|
|
56138
|
+
GetIdentityByNonUniquePublicKeyHashResponseV1.prototype.toJSON = function toJSON() {
|
|
56139
|
+
return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
|
|
56140
|
+
};
|
|
56141
|
+
|
|
56142
|
+
GetIdentityByNonUniquePublicKeyHashResponseV1.IdentityResponse = (function() {
|
|
56143
|
+
|
|
56144
|
+
/**
|
|
56145
|
+
* Properties of an IdentityResponse.
|
|
56146
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1
|
|
56147
|
+
* @interface IIdentityResponse
|
|
56148
|
+
* @property {Uint8Array|null} [identity] IdentityResponse identity
|
|
56149
|
+
*/
|
|
56150
|
+
|
|
56151
|
+
/**
|
|
56152
|
+
* Constructs a new IdentityResponse.
|
|
56153
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1
|
|
56154
|
+
* @classdesc Represents an IdentityResponse.
|
|
56155
|
+
* @implements IIdentityResponse
|
|
56156
|
+
* @constructor
|
|
56157
|
+
* @param {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.IIdentityResponse=} [properties] Properties to set
|
|
56158
|
+
*/
|
|
56159
|
+
function IdentityResponse(properties) {
|
|
56160
|
+
if (properties)
|
|
56161
|
+
for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
|
|
56162
|
+
if (properties[keys[i]] != null)
|
|
56163
|
+
this[keys[i]] = properties[keys[i]];
|
|
56164
|
+
}
|
|
56165
|
+
|
|
56166
|
+
/**
|
|
56167
|
+
* IdentityResponse identity.
|
|
56168
|
+
* @member {Uint8Array} identity
|
|
56169
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.IdentityResponse
|
|
56170
|
+
* @instance
|
|
56171
|
+
*/
|
|
56172
|
+
IdentityResponse.prototype.identity = $util.newBuffer([]);
|
|
56173
|
+
|
|
56174
|
+
/**
|
|
56175
|
+
* Creates a new IdentityResponse instance using the specified properties.
|
|
56176
|
+
* @function create
|
|
56177
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.IdentityResponse
|
|
56178
|
+
* @static
|
|
56179
|
+
* @param {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.IIdentityResponse=} [properties] Properties to set
|
|
56180
|
+
* @returns {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.IdentityResponse} IdentityResponse instance
|
|
56181
|
+
*/
|
|
56182
|
+
IdentityResponse.create = function create(properties) {
|
|
56183
|
+
return new IdentityResponse(properties);
|
|
56184
|
+
};
|
|
56185
|
+
|
|
56186
|
+
/**
|
|
56187
|
+
* Encodes the specified IdentityResponse message. Does not implicitly {@link org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.IdentityResponse.verify|verify} messages.
|
|
56188
|
+
* @function encode
|
|
56189
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.IdentityResponse
|
|
56190
|
+
* @static
|
|
56191
|
+
* @param {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.IIdentityResponse} message IdentityResponse message or plain object to encode
|
|
56192
|
+
* @param {$protobuf.Writer} [writer] Writer to encode to
|
|
56193
|
+
* @returns {$protobuf.Writer} Writer
|
|
56194
|
+
*/
|
|
56195
|
+
IdentityResponse.encode = function encode(message, writer) {
|
|
56196
|
+
if (!writer)
|
|
56197
|
+
writer = $Writer.create();
|
|
56198
|
+
if (message.identity != null && Object.hasOwnProperty.call(message, "identity"))
|
|
56199
|
+
writer.uint32(/* id 1, wireType 2 =*/10).bytes(message.identity);
|
|
56200
|
+
return writer;
|
|
56201
|
+
};
|
|
56202
|
+
|
|
56203
|
+
/**
|
|
56204
|
+
* Encodes the specified IdentityResponse message, length delimited. Does not implicitly {@link org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.IdentityResponse.verify|verify} messages.
|
|
56205
|
+
* @function encodeDelimited
|
|
56206
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.IdentityResponse
|
|
56207
|
+
* @static
|
|
56208
|
+
* @param {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.IIdentityResponse} message IdentityResponse message or plain object to encode
|
|
56209
|
+
* @param {$protobuf.Writer} [writer] Writer to encode to
|
|
56210
|
+
* @returns {$protobuf.Writer} Writer
|
|
56211
|
+
*/
|
|
56212
|
+
IdentityResponse.encodeDelimited = function encodeDelimited(message, writer) {
|
|
56213
|
+
return this.encode(message, writer).ldelim();
|
|
56214
|
+
};
|
|
56215
|
+
|
|
56216
|
+
/**
|
|
56217
|
+
* Decodes an IdentityResponse message from the specified reader or buffer.
|
|
56218
|
+
* @function decode
|
|
56219
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.IdentityResponse
|
|
56220
|
+
* @static
|
|
56221
|
+
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
|
|
56222
|
+
* @param {number} [length] Message length if known beforehand
|
|
56223
|
+
* @returns {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.IdentityResponse} IdentityResponse
|
|
56224
|
+
* @throws {Error} If the payload is not a reader or valid buffer
|
|
56225
|
+
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
|
56226
|
+
*/
|
|
56227
|
+
IdentityResponse.decode = function decode(reader, length) {
|
|
56228
|
+
if (!(reader instanceof $Reader))
|
|
56229
|
+
reader = $Reader.create(reader);
|
|
56230
|
+
var end = length === undefined ? reader.len : reader.pos + length, message = new $root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.IdentityResponse();
|
|
56231
|
+
while (reader.pos < end) {
|
|
56232
|
+
var tag = reader.uint32();
|
|
56233
|
+
switch (tag >>> 3) {
|
|
56234
|
+
case 1:
|
|
56235
|
+
message.identity = reader.bytes();
|
|
56236
|
+
break;
|
|
56237
|
+
default:
|
|
56238
|
+
reader.skipType(tag & 7);
|
|
56239
|
+
break;
|
|
56240
|
+
}
|
|
56241
|
+
}
|
|
56242
|
+
return message;
|
|
56243
|
+
};
|
|
56244
|
+
|
|
56245
|
+
/**
|
|
56246
|
+
* Decodes an IdentityResponse message from the specified reader or buffer, length delimited.
|
|
56247
|
+
* @function decodeDelimited
|
|
56248
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.IdentityResponse
|
|
56249
|
+
* @static
|
|
56250
|
+
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
|
|
56251
|
+
* @returns {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.IdentityResponse} IdentityResponse
|
|
56252
|
+
* @throws {Error} If the payload is not a reader or valid buffer
|
|
56253
|
+
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
|
56254
|
+
*/
|
|
56255
|
+
IdentityResponse.decodeDelimited = function decodeDelimited(reader) {
|
|
56256
|
+
if (!(reader instanceof $Reader))
|
|
56257
|
+
reader = new $Reader(reader);
|
|
56258
|
+
return this.decode(reader, reader.uint32());
|
|
56259
|
+
};
|
|
56260
|
+
|
|
56261
|
+
/**
|
|
56262
|
+
* Verifies an IdentityResponse message.
|
|
56263
|
+
* @function verify
|
|
56264
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.IdentityResponse
|
|
56265
|
+
* @static
|
|
56266
|
+
* @param {Object.<string,*>} message Plain object to verify
|
|
56267
|
+
* @returns {string|null} `null` if valid, otherwise the reason why it is not
|
|
56268
|
+
*/
|
|
56269
|
+
IdentityResponse.verify = function verify(message) {
|
|
56270
|
+
if (typeof message !== "object" || message === null)
|
|
56271
|
+
return "object expected";
|
|
56272
|
+
if (message.identity != null && message.hasOwnProperty("identity"))
|
|
56273
|
+
if (!(message.identity && typeof message.identity.length === "number" || $util.isString(message.identity)))
|
|
56274
|
+
return "identity: buffer expected";
|
|
56275
|
+
return null;
|
|
56276
|
+
};
|
|
56277
|
+
|
|
56278
|
+
/**
|
|
56279
|
+
* Creates an IdentityResponse message from a plain object. Also converts values to their respective internal types.
|
|
56280
|
+
* @function fromObject
|
|
56281
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.IdentityResponse
|
|
56282
|
+
* @static
|
|
56283
|
+
* @param {Object.<string,*>} object Plain object
|
|
56284
|
+
* @returns {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.IdentityResponse} IdentityResponse
|
|
56285
|
+
*/
|
|
56286
|
+
IdentityResponse.fromObject = function fromObject(object) {
|
|
56287
|
+
if (object instanceof $root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.IdentityResponse)
|
|
56288
|
+
return object;
|
|
56289
|
+
var message = new $root.org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.IdentityResponse();
|
|
56290
|
+
if (object.identity != null)
|
|
56291
|
+
if (typeof object.identity === "string")
|
|
56292
|
+
$util.base64.decode(object.identity, message.identity = $util.newBuffer($util.base64.length(object.identity)), 0);
|
|
56293
|
+
else if (object.identity.length >= 0)
|
|
56294
|
+
message.identity = object.identity;
|
|
56295
|
+
return message;
|
|
56296
|
+
};
|
|
56297
|
+
|
|
56298
|
+
/**
|
|
56299
|
+
* Creates a plain object from an IdentityResponse message. Also converts values to other types if specified.
|
|
56300
|
+
* @function toObject
|
|
56301
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.IdentityResponse
|
|
56302
|
+
* @static
|
|
56303
|
+
* @param {org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.IdentityResponse} message IdentityResponse
|
|
56304
|
+
* @param {$protobuf.IConversionOptions} [options] Conversion options
|
|
56305
|
+
* @returns {Object.<string,*>} Plain object
|
|
56306
|
+
*/
|
|
56307
|
+
IdentityResponse.toObject = function toObject(message, options) {
|
|
56308
|
+
if (!options)
|
|
56309
|
+
options = {};
|
|
56310
|
+
var object = {};
|
|
56311
|
+
if (options.defaults)
|
|
56312
|
+
if (options.bytes === String)
|
|
56313
|
+
object.identity = "";
|
|
56314
|
+
else {
|
|
56315
|
+
object.identity = [];
|
|
56316
|
+
if (options.bytes !== Array)
|
|
56317
|
+
object.identity = $util.newBuffer(object.identity);
|
|
56318
|
+
}
|
|
56319
|
+
if (message.identity != null && message.hasOwnProperty("identity"))
|
|
56320
|
+
object.identity = options.bytes === String ? $util.base64.encode(message.identity, 0, message.identity.length) : options.bytes === Array ? Array.prototype.slice.call(message.identity) : message.identity;
|
|
56321
|
+
return object;
|
|
56322
|
+
};
|
|
56323
|
+
|
|
56324
|
+
/**
|
|
56325
|
+
* Converts this IdentityResponse to JSON.
|
|
56326
|
+
* @function toJSON
|
|
56327
|
+
* @memberof org.dash.platform.dapi.v0.GetIdentityByNonUniquePublicKeyHashResponse.GetIdentityByNonUniquePublicKeyHashResponseV1.IdentityResponse
|
|
56328
|
+
* @instance
|
|
56329
|
+
* @returns {Object.<string,*>} JSON object
|
|
56330
|
+
*/
|
|
56331
|
+
IdentityResponse.prototype.toJSON = function toJSON() {
|
|
56332
|
+
return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
|
|
56333
|
+
};
|
|
56334
|
+
|
|
56335
|
+
return IdentityResponse;
|
|
56336
|
+
})();
|
|
56337
|
+
|
|
56338
|
+
return GetIdentityByNonUniquePublicKeyHashResponseV1;
|
|
56339
|
+
})();
|
|
56340
|
+
|
|
55330
56341
|
return GetIdentityByNonUniquePublicKeyHashResponse;
|
|
55331
56342
|
})();
|
|
55332
56343
|
|