@google-cloud/spanner 7.18.1 → 7.19.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.
- package/CHANGELOG.md +30 -0
- package/README.md +1 -0
- package/build/protos/google/spanner/admin/database/v1/backup.proto +16 -0
- package/build/protos/google/spanner/admin/database/v1/spanner_database_admin.proto +70 -0
- package/build/protos/google/spanner/v1/transaction.proto +48 -1
- package/build/protos/protos.d.ts +552 -0
- package/build/protos/protos.js +1300 -1
- package/build/protos/protos.json +122 -2
- package/build/src/database.js +14 -9
- package/build/src/multiplexed-session.d.ts +0 -1
- package/build/src/multiplexed-session.js +0 -3
- package/build/src/request_id_header.d.ts +41 -0
- package/build/src/request_id_header.js +138 -0
- package/build/src/session-factory.d.ts +15 -0
- package/build/src/session-factory.js +18 -5
- package/build/src/session-pool.js +18 -7
- package/build/src/transaction.d.ts +3 -0
- package/build/src/transaction.js +6 -6
- package/build/src/v1/database_admin_client.d.ts +40 -9
- package/build/src/v1/database_admin_client.js +87 -9
- package/build/src/v1/database_admin_client_config.json +5 -0
- package/build/src/v1/instance_admin_client.d.ts +5 -5
- package/build/src/v1/instance_admin_client.js +5 -5
- package/build/src/v1/spanner_client.d.ts +1 -1
- package/build/src/v1/spanner_client.js +2 -2
- package/build/src/v1/spanner_executor_proxy_client.js +1 -1
- package/package.json +2 -2
package/build/protos/protos.js
CHANGED
|
@@ -17707,6 +17707,7 @@
|
|
|
17707
17707
|
* @property {Array.<string>|null} [backupSchedules] Backup backupSchedules
|
|
17708
17708
|
* @property {string|null} [incrementalBackupChainId] Backup incrementalBackupChainId
|
|
17709
17709
|
* @property {google.protobuf.ITimestamp|null} [oldestVersionTime] Backup oldestVersionTime
|
|
17710
|
+
* @property {Array.<google.spanner.admin.database.v1.IBackupInstancePartition>|null} [instancePartitions] Backup instancePartitions
|
|
17710
17711
|
*/
|
|
17711
17712
|
|
|
17712
17713
|
/**
|
|
@@ -17722,6 +17723,7 @@
|
|
|
17722
17723
|
this.encryptionInformation = [];
|
|
17723
17724
|
this.referencingBackups = [];
|
|
17724
17725
|
this.backupSchedules = [];
|
|
17726
|
+
this.instancePartitions = [];
|
|
17725
17727
|
if (properties)
|
|
17726
17728
|
for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
|
|
17727
17729
|
if (properties[keys[i]] != null)
|
|
@@ -17872,6 +17874,14 @@
|
|
|
17872
17874
|
*/
|
|
17873
17875
|
Backup.prototype.oldestVersionTime = null;
|
|
17874
17876
|
|
|
17877
|
+
/**
|
|
17878
|
+
* Backup instancePartitions.
|
|
17879
|
+
* @member {Array.<google.spanner.admin.database.v1.IBackupInstancePartition>} instancePartitions
|
|
17880
|
+
* @memberof google.spanner.admin.database.v1.Backup
|
|
17881
|
+
* @instance
|
|
17882
|
+
*/
|
|
17883
|
+
Backup.prototype.instancePartitions = $util.emptyArray;
|
|
17884
|
+
|
|
17875
17885
|
/**
|
|
17876
17886
|
* Creates a new Backup instance using the specified properties.
|
|
17877
17887
|
* @function create
|
|
@@ -17936,6 +17946,9 @@
|
|
|
17936
17946
|
writer.uint32(/* id 17, wireType 2 =*/138).string(message.incrementalBackupChainId);
|
|
17937
17947
|
if (message.oldestVersionTime != null && Object.hasOwnProperty.call(message, "oldestVersionTime"))
|
|
17938
17948
|
$root.google.protobuf.Timestamp.encode(message.oldestVersionTime, writer.uint32(/* id 18, wireType 2 =*/146).fork()).ldelim();
|
|
17949
|
+
if (message.instancePartitions != null && message.instancePartitions.length)
|
|
17950
|
+
for (var i = 0; i < message.instancePartitions.length; ++i)
|
|
17951
|
+
$root.google.spanner.admin.database.v1.BackupInstancePartition.encode(message.instancePartitions[i], writer.uint32(/* id 19, wireType 2 =*/154).fork()).ldelim();
|
|
17939
17952
|
return writer;
|
|
17940
17953
|
};
|
|
17941
17954
|
|
|
@@ -18050,6 +18063,12 @@
|
|
|
18050
18063
|
message.oldestVersionTime = $root.google.protobuf.Timestamp.decode(reader, reader.uint32());
|
|
18051
18064
|
break;
|
|
18052
18065
|
}
|
|
18066
|
+
case 19: {
|
|
18067
|
+
if (!(message.instancePartitions && message.instancePartitions.length))
|
|
18068
|
+
message.instancePartitions = [];
|
|
18069
|
+
message.instancePartitions.push($root.google.spanner.admin.database.v1.BackupInstancePartition.decode(reader, reader.uint32()));
|
|
18070
|
+
break;
|
|
18071
|
+
}
|
|
18053
18072
|
default:
|
|
18054
18073
|
reader.skipType(tag & 7);
|
|
18055
18074
|
break;
|
|
@@ -18181,6 +18200,15 @@
|
|
|
18181
18200
|
if (error)
|
|
18182
18201
|
return "oldestVersionTime." + error;
|
|
18183
18202
|
}
|
|
18203
|
+
if (message.instancePartitions != null && message.hasOwnProperty("instancePartitions")) {
|
|
18204
|
+
if (!Array.isArray(message.instancePartitions))
|
|
18205
|
+
return "instancePartitions: array expected";
|
|
18206
|
+
for (var i = 0; i < message.instancePartitions.length; ++i) {
|
|
18207
|
+
var error = $root.google.spanner.admin.database.v1.BackupInstancePartition.verify(message.instancePartitions[i]);
|
|
18208
|
+
if (error)
|
|
18209
|
+
return "instancePartitions." + error;
|
|
18210
|
+
}
|
|
18211
|
+
}
|
|
18184
18212
|
return null;
|
|
18185
18213
|
};
|
|
18186
18214
|
|
|
@@ -18330,6 +18358,16 @@
|
|
|
18330
18358
|
throw TypeError(".google.spanner.admin.database.v1.Backup.oldestVersionTime: object expected");
|
|
18331
18359
|
message.oldestVersionTime = $root.google.protobuf.Timestamp.fromObject(object.oldestVersionTime);
|
|
18332
18360
|
}
|
|
18361
|
+
if (object.instancePartitions) {
|
|
18362
|
+
if (!Array.isArray(object.instancePartitions))
|
|
18363
|
+
throw TypeError(".google.spanner.admin.database.v1.Backup.instancePartitions: array expected");
|
|
18364
|
+
message.instancePartitions = [];
|
|
18365
|
+
for (var i = 0; i < object.instancePartitions.length; ++i) {
|
|
18366
|
+
if (typeof object.instancePartitions[i] !== "object")
|
|
18367
|
+
throw TypeError(".google.spanner.admin.database.v1.Backup.instancePartitions: object expected");
|
|
18368
|
+
message.instancePartitions[i] = $root.google.spanner.admin.database.v1.BackupInstancePartition.fromObject(object.instancePartitions[i]);
|
|
18369
|
+
}
|
|
18370
|
+
}
|
|
18333
18371
|
return message;
|
|
18334
18372
|
};
|
|
18335
18373
|
|
|
@@ -18351,6 +18389,7 @@
|
|
|
18351
18389
|
object.referencingBackups = [];
|
|
18352
18390
|
object.encryptionInformation = [];
|
|
18353
18391
|
object.backupSchedules = [];
|
|
18392
|
+
object.instancePartitions = [];
|
|
18354
18393
|
}
|
|
18355
18394
|
if (options.defaults) {
|
|
18356
18395
|
object.name = "";
|
|
@@ -18437,6 +18476,11 @@
|
|
|
18437
18476
|
object.incrementalBackupChainId = message.incrementalBackupChainId;
|
|
18438
18477
|
if (message.oldestVersionTime != null && message.hasOwnProperty("oldestVersionTime"))
|
|
18439
18478
|
object.oldestVersionTime = $root.google.protobuf.Timestamp.toObject(message.oldestVersionTime, options);
|
|
18479
|
+
if (message.instancePartitions && message.instancePartitions.length) {
|
|
18480
|
+
object.instancePartitions = [];
|
|
18481
|
+
for (var j = 0; j < message.instancePartitions.length; ++j)
|
|
18482
|
+
object.instancePartitions[j] = $root.google.spanner.admin.database.v1.BackupInstancePartition.toObject(message.instancePartitions[j], options);
|
|
18483
|
+
}
|
|
18440
18484
|
return object;
|
|
18441
18485
|
};
|
|
18442
18486
|
|
|
@@ -22586,6 +22630,209 @@
|
|
|
22586
22630
|
return IncrementalBackupSpec;
|
|
22587
22631
|
})();
|
|
22588
22632
|
|
|
22633
|
+
v1.BackupInstancePartition = (function() {
|
|
22634
|
+
|
|
22635
|
+
/**
|
|
22636
|
+
* Properties of a BackupInstancePartition.
|
|
22637
|
+
* @memberof google.spanner.admin.database.v1
|
|
22638
|
+
* @interface IBackupInstancePartition
|
|
22639
|
+
* @property {string|null} [instancePartition] BackupInstancePartition instancePartition
|
|
22640
|
+
*/
|
|
22641
|
+
|
|
22642
|
+
/**
|
|
22643
|
+
* Constructs a new BackupInstancePartition.
|
|
22644
|
+
* @memberof google.spanner.admin.database.v1
|
|
22645
|
+
* @classdesc Represents a BackupInstancePartition.
|
|
22646
|
+
* @implements IBackupInstancePartition
|
|
22647
|
+
* @constructor
|
|
22648
|
+
* @param {google.spanner.admin.database.v1.IBackupInstancePartition=} [properties] Properties to set
|
|
22649
|
+
*/
|
|
22650
|
+
function BackupInstancePartition(properties) {
|
|
22651
|
+
if (properties)
|
|
22652
|
+
for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
|
|
22653
|
+
if (properties[keys[i]] != null)
|
|
22654
|
+
this[keys[i]] = properties[keys[i]];
|
|
22655
|
+
}
|
|
22656
|
+
|
|
22657
|
+
/**
|
|
22658
|
+
* BackupInstancePartition instancePartition.
|
|
22659
|
+
* @member {string} instancePartition
|
|
22660
|
+
* @memberof google.spanner.admin.database.v1.BackupInstancePartition
|
|
22661
|
+
* @instance
|
|
22662
|
+
*/
|
|
22663
|
+
BackupInstancePartition.prototype.instancePartition = "";
|
|
22664
|
+
|
|
22665
|
+
/**
|
|
22666
|
+
* Creates a new BackupInstancePartition instance using the specified properties.
|
|
22667
|
+
* @function create
|
|
22668
|
+
* @memberof google.spanner.admin.database.v1.BackupInstancePartition
|
|
22669
|
+
* @static
|
|
22670
|
+
* @param {google.spanner.admin.database.v1.IBackupInstancePartition=} [properties] Properties to set
|
|
22671
|
+
* @returns {google.spanner.admin.database.v1.BackupInstancePartition} BackupInstancePartition instance
|
|
22672
|
+
*/
|
|
22673
|
+
BackupInstancePartition.create = function create(properties) {
|
|
22674
|
+
return new BackupInstancePartition(properties);
|
|
22675
|
+
};
|
|
22676
|
+
|
|
22677
|
+
/**
|
|
22678
|
+
* Encodes the specified BackupInstancePartition message. Does not implicitly {@link google.spanner.admin.database.v1.BackupInstancePartition.verify|verify} messages.
|
|
22679
|
+
* @function encode
|
|
22680
|
+
* @memberof google.spanner.admin.database.v1.BackupInstancePartition
|
|
22681
|
+
* @static
|
|
22682
|
+
* @param {google.spanner.admin.database.v1.IBackupInstancePartition} message BackupInstancePartition message or plain object to encode
|
|
22683
|
+
* @param {$protobuf.Writer} [writer] Writer to encode to
|
|
22684
|
+
* @returns {$protobuf.Writer} Writer
|
|
22685
|
+
*/
|
|
22686
|
+
BackupInstancePartition.encode = function encode(message, writer) {
|
|
22687
|
+
if (!writer)
|
|
22688
|
+
writer = $Writer.create();
|
|
22689
|
+
if (message.instancePartition != null && Object.hasOwnProperty.call(message, "instancePartition"))
|
|
22690
|
+
writer.uint32(/* id 1, wireType 2 =*/10).string(message.instancePartition);
|
|
22691
|
+
return writer;
|
|
22692
|
+
};
|
|
22693
|
+
|
|
22694
|
+
/**
|
|
22695
|
+
* Encodes the specified BackupInstancePartition message, length delimited. Does not implicitly {@link google.spanner.admin.database.v1.BackupInstancePartition.verify|verify} messages.
|
|
22696
|
+
* @function encodeDelimited
|
|
22697
|
+
* @memberof google.spanner.admin.database.v1.BackupInstancePartition
|
|
22698
|
+
* @static
|
|
22699
|
+
* @param {google.spanner.admin.database.v1.IBackupInstancePartition} message BackupInstancePartition message or plain object to encode
|
|
22700
|
+
* @param {$protobuf.Writer} [writer] Writer to encode to
|
|
22701
|
+
* @returns {$protobuf.Writer} Writer
|
|
22702
|
+
*/
|
|
22703
|
+
BackupInstancePartition.encodeDelimited = function encodeDelimited(message, writer) {
|
|
22704
|
+
return this.encode(message, writer).ldelim();
|
|
22705
|
+
};
|
|
22706
|
+
|
|
22707
|
+
/**
|
|
22708
|
+
* Decodes a BackupInstancePartition message from the specified reader or buffer.
|
|
22709
|
+
* @function decode
|
|
22710
|
+
* @memberof google.spanner.admin.database.v1.BackupInstancePartition
|
|
22711
|
+
* @static
|
|
22712
|
+
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
|
|
22713
|
+
* @param {number} [length] Message length if known beforehand
|
|
22714
|
+
* @returns {google.spanner.admin.database.v1.BackupInstancePartition} BackupInstancePartition
|
|
22715
|
+
* @throws {Error} If the payload is not a reader or valid buffer
|
|
22716
|
+
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
|
22717
|
+
*/
|
|
22718
|
+
BackupInstancePartition.decode = function decode(reader, length) {
|
|
22719
|
+
if (!(reader instanceof $Reader))
|
|
22720
|
+
reader = $Reader.create(reader);
|
|
22721
|
+
var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.spanner.admin.database.v1.BackupInstancePartition();
|
|
22722
|
+
while (reader.pos < end) {
|
|
22723
|
+
var tag = reader.uint32();
|
|
22724
|
+
switch (tag >>> 3) {
|
|
22725
|
+
case 1: {
|
|
22726
|
+
message.instancePartition = reader.string();
|
|
22727
|
+
break;
|
|
22728
|
+
}
|
|
22729
|
+
default:
|
|
22730
|
+
reader.skipType(tag & 7);
|
|
22731
|
+
break;
|
|
22732
|
+
}
|
|
22733
|
+
}
|
|
22734
|
+
return message;
|
|
22735
|
+
};
|
|
22736
|
+
|
|
22737
|
+
/**
|
|
22738
|
+
* Decodes a BackupInstancePartition message from the specified reader or buffer, length delimited.
|
|
22739
|
+
* @function decodeDelimited
|
|
22740
|
+
* @memberof google.spanner.admin.database.v1.BackupInstancePartition
|
|
22741
|
+
* @static
|
|
22742
|
+
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
|
|
22743
|
+
* @returns {google.spanner.admin.database.v1.BackupInstancePartition} BackupInstancePartition
|
|
22744
|
+
* @throws {Error} If the payload is not a reader or valid buffer
|
|
22745
|
+
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
|
22746
|
+
*/
|
|
22747
|
+
BackupInstancePartition.decodeDelimited = function decodeDelimited(reader) {
|
|
22748
|
+
if (!(reader instanceof $Reader))
|
|
22749
|
+
reader = new $Reader(reader);
|
|
22750
|
+
return this.decode(reader, reader.uint32());
|
|
22751
|
+
};
|
|
22752
|
+
|
|
22753
|
+
/**
|
|
22754
|
+
* Verifies a BackupInstancePartition message.
|
|
22755
|
+
* @function verify
|
|
22756
|
+
* @memberof google.spanner.admin.database.v1.BackupInstancePartition
|
|
22757
|
+
* @static
|
|
22758
|
+
* @param {Object.<string,*>} message Plain object to verify
|
|
22759
|
+
* @returns {string|null} `null` if valid, otherwise the reason why it is not
|
|
22760
|
+
*/
|
|
22761
|
+
BackupInstancePartition.verify = function verify(message) {
|
|
22762
|
+
if (typeof message !== "object" || message === null)
|
|
22763
|
+
return "object expected";
|
|
22764
|
+
if (message.instancePartition != null && message.hasOwnProperty("instancePartition"))
|
|
22765
|
+
if (!$util.isString(message.instancePartition))
|
|
22766
|
+
return "instancePartition: string expected";
|
|
22767
|
+
return null;
|
|
22768
|
+
};
|
|
22769
|
+
|
|
22770
|
+
/**
|
|
22771
|
+
* Creates a BackupInstancePartition message from a plain object. Also converts values to their respective internal types.
|
|
22772
|
+
* @function fromObject
|
|
22773
|
+
* @memberof google.spanner.admin.database.v1.BackupInstancePartition
|
|
22774
|
+
* @static
|
|
22775
|
+
* @param {Object.<string,*>} object Plain object
|
|
22776
|
+
* @returns {google.spanner.admin.database.v1.BackupInstancePartition} BackupInstancePartition
|
|
22777
|
+
*/
|
|
22778
|
+
BackupInstancePartition.fromObject = function fromObject(object) {
|
|
22779
|
+
if (object instanceof $root.google.spanner.admin.database.v1.BackupInstancePartition)
|
|
22780
|
+
return object;
|
|
22781
|
+
var message = new $root.google.spanner.admin.database.v1.BackupInstancePartition();
|
|
22782
|
+
if (object.instancePartition != null)
|
|
22783
|
+
message.instancePartition = String(object.instancePartition);
|
|
22784
|
+
return message;
|
|
22785
|
+
};
|
|
22786
|
+
|
|
22787
|
+
/**
|
|
22788
|
+
* Creates a plain object from a BackupInstancePartition message. Also converts values to other types if specified.
|
|
22789
|
+
* @function toObject
|
|
22790
|
+
* @memberof google.spanner.admin.database.v1.BackupInstancePartition
|
|
22791
|
+
* @static
|
|
22792
|
+
* @param {google.spanner.admin.database.v1.BackupInstancePartition} message BackupInstancePartition
|
|
22793
|
+
* @param {$protobuf.IConversionOptions} [options] Conversion options
|
|
22794
|
+
* @returns {Object.<string,*>} Plain object
|
|
22795
|
+
*/
|
|
22796
|
+
BackupInstancePartition.toObject = function toObject(message, options) {
|
|
22797
|
+
if (!options)
|
|
22798
|
+
options = {};
|
|
22799
|
+
var object = {};
|
|
22800
|
+
if (options.defaults)
|
|
22801
|
+
object.instancePartition = "";
|
|
22802
|
+
if (message.instancePartition != null && message.hasOwnProperty("instancePartition"))
|
|
22803
|
+
object.instancePartition = message.instancePartition;
|
|
22804
|
+
return object;
|
|
22805
|
+
};
|
|
22806
|
+
|
|
22807
|
+
/**
|
|
22808
|
+
* Converts this BackupInstancePartition to JSON.
|
|
22809
|
+
* @function toJSON
|
|
22810
|
+
* @memberof google.spanner.admin.database.v1.BackupInstancePartition
|
|
22811
|
+
* @instance
|
|
22812
|
+
* @returns {Object.<string,*>} JSON object
|
|
22813
|
+
*/
|
|
22814
|
+
BackupInstancePartition.prototype.toJSON = function toJSON() {
|
|
22815
|
+
return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
|
|
22816
|
+
};
|
|
22817
|
+
|
|
22818
|
+
/**
|
|
22819
|
+
* Gets the default type url for BackupInstancePartition
|
|
22820
|
+
* @function getTypeUrl
|
|
22821
|
+
* @memberof google.spanner.admin.database.v1.BackupInstancePartition
|
|
22822
|
+
* @static
|
|
22823
|
+
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
|
|
22824
|
+
* @returns {string} The default type url
|
|
22825
|
+
*/
|
|
22826
|
+
BackupInstancePartition.getTypeUrl = function getTypeUrl(typeUrlPrefix) {
|
|
22827
|
+
if (typeUrlPrefix === undefined) {
|
|
22828
|
+
typeUrlPrefix = "type.googleapis.com";
|
|
22829
|
+
}
|
|
22830
|
+
return typeUrlPrefix + "/google.spanner.admin.database.v1.BackupInstancePartition";
|
|
22831
|
+
};
|
|
22832
|
+
|
|
22833
|
+
return BackupInstancePartition;
|
|
22834
|
+
})();
|
|
22835
|
+
|
|
22589
22836
|
v1.OperationProgress = (function() {
|
|
22590
22837
|
|
|
22591
22838
|
/**
|
|
@@ -26369,6 +26616,39 @@
|
|
|
26369
26616
|
* @variation 2
|
|
26370
26617
|
*/
|
|
26371
26618
|
|
|
26619
|
+
/**
|
|
26620
|
+
* Callback as used by {@link google.spanner.admin.database.v1.DatabaseAdmin|addSplitPoints}.
|
|
26621
|
+
* @memberof google.spanner.admin.database.v1.DatabaseAdmin
|
|
26622
|
+
* @typedef AddSplitPointsCallback
|
|
26623
|
+
* @type {function}
|
|
26624
|
+
* @param {Error|null} error Error, if any
|
|
26625
|
+
* @param {google.spanner.admin.database.v1.AddSplitPointsResponse} [response] AddSplitPointsResponse
|
|
26626
|
+
*/
|
|
26627
|
+
|
|
26628
|
+
/**
|
|
26629
|
+
* Calls AddSplitPoints.
|
|
26630
|
+
* @function addSplitPoints
|
|
26631
|
+
* @memberof google.spanner.admin.database.v1.DatabaseAdmin
|
|
26632
|
+
* @instance
|
|
26633
|
+
* @param {google.spanner.admin.database.v1.IAddSplitPointsRequest} request AddSplitPointsRequest message or plain object
|
|
26634
|
+
* @param {google.spanner.admin.database.v1.DatabaseAdmin.AddSplitPointsCallback} callback Node-style callback called with the error, if any, and AddSplitPointsResponse
|
|
26635
|
+
* @returns {undefined}
|
|
26636
|
+
* @variation 1
|
|
26637
|
+
*/
|
|
26638
|
+
Object.defineProperty(DatabaseAdmin.prototype.addSplitPoints = function addSplitPoints(request, callback) {
|
|
26639
|
+
return this.rpcCall(addSplitPoints, $root.google.spanner.admin.database.v1.AddSplitPointsRequest, $root.google.spanner.admin.database.v1.AddSplitPointsResponse, request, callback);
|
|
26640
|
+
}, "name", { value: "AddSplitPoints" });
|
|
26641
|
+
|
|
26642
|
+
/**
|
|
26643
|
+
* Calls AddSplitPoints.
|
|
26644
|
+
* @function addSplitPoints
|
|
26645
|
+
* @memberof google.spanner.admin.database.v1.DatabaseAdmin
|
|
26646
|
+
* @instance
|
|
26647
|
+
* @param {google.spanner.admin.database.v1.IAddSplitPointsRequest} request AddSplitPointsRequest message or plain object
|
|
26648
|
+
* @returns {Promise<google.spanner.admin.database.v1.AddSplitPointsResponse>} Promise
|
|
26649
|
+
* @variation 2
|
|
26650
|
+
*/
|
|
26651
|
+
|
|
26372
26652
|
/**
|
|
26373
26653
|
* Callback as used by {@link google.spanner.admin.database.v1.DatabaseAdmin|createBackupSchedule}.
|
|
26374
26654
|
* @memberof google.spanner.admin.database.v1.DatabaseAdmin
|
|
@@ -33233,6 +33513,961 @@
|
|
|
33233
33513
|
return ListDatabaseRolesResponse;
|
|
33234
33514
|
})();
|
|
33235
33515
|
|
|
33516
|
+
v1.AddSplitPointsRequest = (function() {
|
|
33517
|
+
|
|
33518
|
+
/**
|
|
33519
|
+
* Properties of an AddSplitPointsRequest.
|
|
33520
|
+
* @memberof google.spanner.admin.database.v1
|
|
33521
|
+
* @interface IAddSplitPointsRequest
|
|
33522
|
+
* @property {string|null} [database] AddSplitPointsRequest database
|
|
33523
|
+
* @property {Array.<google.spanner.admin.database.v1.ISplitPoints>|null} [splitPoints] AddSplitPointsRequest splitPoints
|
|
33524
|
+
* @property {string|null} [initiator] AddSplitPointsRequest initiator
|
|
33525
|
+
*/
|
|
33526
|
+
|
|
33527
|
+
/**
|
|
33528
|
+
* Constructs a new AddSplitPointsRequest.
|
|
33529
|
+
* @memberof google.spanner.admin.database.v1
|
|
33530
|
+
* @classdesc Represents an AddSplitPointsRequest.
|
|
33531
|
+
* @implements IAddSplitPointsRequest
|
|
33532
|
+
* @constructor
|
|
33533
|
+
* @param {google.spanner.admin.database.v1.IAddSplitPointsRequest=} [properties] Properties to set
|
|
33534
|
+
*/
|
|
33535
|
+
function AddSplitPointsRequest(properties) {
|
|
33536
|
+
this.splitPoints = [];
|
|
33537
|
+
if (properties)
|
|
33538
|
+
for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
|
|
33539
|
+
if (properties[keys[i]] != null)
|
|
33540
|
+
this[keys[i]] = properties[keys[i]];
|
|
33541
|
+
}
|
|
33542
|
+
|
|
33543
|
+
/**
|
|
33544
|
+
* AddSplitPointsRequest database.
|
|
33545
|
+
* @member {string} database
|
|
33546
|
+
* @memberof google.spanner.admin.database.v1.AddSplitPointsRequest
|
|
33547
|
+
* @instance
|
|
33548
|
+
*/
|
|
33549
|
+
AddSplitPointsRequest.prototype.database = "";
|
|
33550
|
+
|
|
33551
|
+
/**
|
|
33552
|
+
* AddSplitPointsRequest splitPoints.
|
|
33553
|
+
* @member {Array.<google.spanner.admin.database.v1.ISplitPoints>} splitPoints
|
|
33554
|
+
* @memberof google.spanner.admin.database.v1.AddSplitPointsRequest
|
|
33555
|
+
* @instance
|
|
33556
|
+
*/
|
|
33557
|
+
AddSplitPointsRequest.prototype.splitPoints = $util.emptyArray;
|
|
33558
|
+
|
|
33559
|
+
/**
|
|
33560
|
+
* AddSplitPointsRequest initiator.
|
|
33561
|
+
* @member {string} initiator
|
|
33562
|
+
* @memberof google.spanner.admin.database.v1.AddSplitPointsRequest
|
|
33563
|
+
* @instance
|
|
33564
|
+
*/
|
|
33565
|
+
AddSplitPointsRequest.prototype.initiator = "";
|
|
33566
|
+
|
|
33567
|
+
/**
|
|
33568
|
+
* Creates a new AddSplitPointsRequest instance using the specified properties.
|
|
33569
|
+
* @function create
|
|
33570
|
+
* @memberof google.spanner.admin.database.v1.AddSplitPointsRequest
|
|
33571
|
+
* @static
|
|
33572
|
+
* @param {google.spanner.admin.database.v1.IAddSplitPointsRequest=} [properties] Properties to set
|
|
33573
|
+
* @returns {google.spanner.admin.database.v1.AddSplitPointsRequest} AddSplitPointsRequest instance
|
|
33574
|
+
*/
|
|
33575
|
+
AddSplitPointsRequest.create = function create(properties) {
|
|
33576
|
+
return new AddSplitPointsRequest(properties);
|
|
33577
|
+
};
|
|
33578
|
+
|
|
33579
|
+
/**
|
|
33580
|
+
* Encodes the specified AddSplitPointsRequest message. Does not implicitly {@link google.spanner.admin.database.v1.AddSplitPointsRequest.verify|verify} messages.
|
|
33581
|
+
* @function encode
|
|
33582
|
+
* @memberof google.spanner.admin.database.v1.AddSplitPointsRequest
|
|
33583
|
+
* @static
|
|
33584
|
+
* @param {google.spanner.admin.database.v1.IAddSplitPointsRequest} message AddSplitPointsRequest message or plain object to encode
|
|
33585
|
+
* @param {$protobuf.Writer} [writer] Writer to encode to
|
|
33586
|
+
* @returns {$protobuf.Writer} Writer
|
|
33587
|
+
*/
|
|
33588
|
+
AddSplitPointsRequest.encode = function encode(message, writer) {
|
|
33589
|
+
if (!writer)
|
|
33590
|
+
writer = $Writer.create();
|
|
33591
|
+
if (message.database != null && Object.hasOwnProperty.call(message, "database"))
|
|
33592
|
+
writer.uint32(/* id 1, wireType 2 =*/10).string(message.database);
|
|
33593
|
+
if (message.splitPoints != null && message.splitPoints.length)
|
|
33594
|
+
for (var i = 0; i < message.splitPoints.length; ++i)
|
|
33595
|
+
$root.google.spanner.admin.database.v1.SplitPoints.encode(message.splitPoints[i], writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim();
|
|
33596
|
+
if (message.initiator != null && Object.hasOwnProperty.call(message, "initiator"))
|
|
33597
|
+
writer.uint32(/* id 3, wireType 2 =*/26).string(message.initiator);
|
|
33598
|
+
return writer;
|
|
33599
|
+
};
|
|
33600
|
+
|
|
33601
|
+
/**
|
|
33602
|
+
* Encodes the specified AddSplitPointsRequest message, length delimited. Does not implicitly {@link google.spanner.admin.database.v1.AddSplitPointsRequest.verify|verify} messages.
|
|
33603
|
+
* @function encodeDelimited
|
|
33604
|
+
* @memberof google.spanner.admin.database.v1.AddSplitPointsRequest
|
|
33605
|
+
* @static
|
|
33606
|
+
* @param {google.spanner.admin.database.v1.IAddSplitPointsRequest} message AddSplitPointsRequest message or plain object to encode
|
|
33607
|
+
* @param {$protobuf.Writer} [writer] Writer to encode to
|
|
33608
|
+
* @returns {$protobuf.Writer} Writer
|
|
33609
|
+
*/
|
|
33610
|
+
AddSplitPointsRequest.encodeDelimited = function encodeDelimited(message, writer) {
|
|
33611
|
+
return this.encode(message, writer).ldelim();
|
|
33612
|
+
};
|
|
33613
|
+
|
|
33614
|
+
/**
|
|
33615
|
+
* Decodes an AddSplitPointsRequest message from the specified reader or buffer.
|
|
33616
|
+
* @function decode
|
|
33617
|
+
* @memberof google.spanner.admin.database.v1.AddSplitPointsRequest
|
|
33618
|
+
* @static
|
|
33619
|
+
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
|
|
33620
|
+
* @param {number} [length] Message length if known beforehand
|
|
33621
|
+
* @returns {google.spanner.admin.database.v1.AddSplitPointsRequest} AddSplitPointsRequest
|
|
33622
|
+
* @throws {Error} If the payload is not a reader or valid buffer
|
|
33623
|
+
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
|
33624
|
+
*/
|
|
33625
|
+
AddSplitPointsRequest.decode = function decode(reader, length) {
|
|
33626
|
+
if (!(reader instanceof $Reader))
|
|
33627
|
+
reader = $Reader.create(reader);
|
|
33628
|
+
var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.spanner.admin.database.v1.AddSplitPointsRequest();
|
|
33629
|
+
while (reader.pos < end) {
|
|
33630
|
+
var tag = reader.uint32();
|
|
33631
|
+
switch (tag >>> 3) {
|
|
33632
|
+
case 1: {
|
|
33633
|
+
message.database = reader.string();
|
|
33634
|
+
break;
|
|
33635
|
+
}
|
|
33636
|
+
case 2: {
|
|
33637
|
+
if (!(message.splitPoints && message.splitPoints.length))
|
|
33638
|
+
message.splitPoints = [];
|
|
33639
|
+
message.splitPoints.push($root.google.spanner.admin.database.v1.SplitPoints.decode(reader, reader.uint32()));
|
|
33640
|
+
break;
|
|
33641
|
+
}
|
|
33642
|
+
case 3: {
|
|
33643
|
+
message.initiator = reader.string();
|
|
33644
|
+
break;
|
|
33645
|
+
}
|
|
33646
|
+
default:
|
|
33647
|
+
reader.skipType(tag & 7);
|
|
33648
|
+
break;
|
|
33649
|
+
}
|
|
33650
|
+
}
|
|
33651
|
+
return message;
|
|
33652
|
+
};
|
|
33653
|
+
|
|
33654
|
+
/**
|
|
33655
|
+
* Decodes an AddSplitPointsRequest message from the specified reader or buffer, length delimited.
|
|
33656
|
+
* @function decodeDelimited
|
|
33657
|
+
* @memberof google.spanner.admin.database.v1.AddSplitPointsRequest
|
|
33658
|
+
* @static
|
|
33659
|
+
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
|
|
33660
|
+
* @returns {google.spanner.admin.database.v1.AddSplitPointsRequest} AddSplitPointsRequest
|
|
33661
|
+
* @throws {Error} If the payload is not a reader or valid buffer
|
|
33662
|
+
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
|
33663
|
+
*/
|
|
33664
|
+
AddSplitPointsRequest.decodeDelimited = function decodeDelimited(reader) {
|
|
33665
|
+
if (!(reader instanceof $Reader))
|
|
33666
|
+
reader = new $Reader(reader);
|
|
33667
|
+
return this.decode(reader, reader.uint32());
|
|
33668
|
+
};
|
|
33669
|
+
|
|
33670
|
+
/**
|
|
33671
|
+
* Verifies an AddSplitPointsRequest message.
|
|
33672
|
+
* @function verify
|
|
33673
|
+
* @memberof google.spanner.admin.database.v1.AddSplitPointsRequest
|
|
33674
|
+
* @static
|
|
33675
|
+
* @param {Object.<string,*>} message Plain object to verify
|
|
33676
|
+
* @returns {string|null} `null` if valid, otherwise the reason why it is not
|
|
33677
|
+
*/
|
|
33678
|
+
AddSplitPointsRequest.verify = function verify(message) {
|
|
33679
|
+
if (typeof message !== "object" || message === null)
|
|
33680
|
+
return "object expected";
|
|
33681
|
+
if (message.database != null && message.hasOwnProperty("database"))
|
|
33682
|
+
if (!$util.isString(message.database))
|
|
33683
|
+
return "database: string expected";
|
|
33684
|
+
if (message.splitPoints != null && message.hasOwnProperty("splitPoints")) {
|
|
33685
|
+
if (!Array.isArray(message.splitPoints))
|
|
33686
|
+
return "splitPoints: array expected";
|
|
33687
|
+
for (var i = 0; i < message.splitPoints.length; ++i) {
|
|
33688
|
+
var error = $root.google.spanner.admin.database.v1.SplitPoints.verify(message.splitPoints[i]);
|
|
33689
|
+
if (error)
|
|
33690
|
+
return "splitPoints." + error;
|
|
33691
|
+
}
|
|
33692
|
+
}
|
|
33693
|
+
if (message.initiator != null && message.hasOwnProperty("initiator"))
|
|
33694
|
+
if (!$util.isString(message.initiator))
|
|
33695
|
+
return "initiator: string expected";
|
|
33696
|
+
return null;
|
|
33697
|
+
};
|
|
33698
|
+
|
|
33699
|
+
/**
|
|
33700
|
+
* Creates an AddSplitPointsRequest message from a plain object. Also converts values to their respective internal types.
|
|
33701
|
+
* @function fromObject
|
|
33702
|
+
* @memberof google.spanner.admin.database.v1.AddSplitPointsRequest
|
|
33703
|
+
* @static
|
|
33704
|
+
* @param {Object.<string,*>} object Plain object
|
|
33705
|
+
* @returns {google.spanner.admin.database.v1.AddSplitPointsRequest} AddSplitPointsRequest
|
|
33706
|
+
*/
|
|
33707
|
+
AddSplitPointsRequest.fromObject = function fromObject(object) {
|
|
33708
|
+
if (object instanceof $root.google.spanner.admin.database.v1.AddSplitPointsRequest)
|
|
33709
|
+
return object;
|
|
33710
|
+
var message = new $root.google.spanner.admin.database.v1.AddSplitPointsRequest();
|
|
33711
|
+
if (object.database != null)
|
|
33712
|
+
message.database = String(object.database);
|
|
33713
|
+
if (object.splitPoints) {
|
|
33714
|
+
if (!Array.isArray(object.splitPoints))
|
|
33715
|
+
throw TypeError(".google.spanner.admin.database.v1.AddSplitPointsRequest.splitPoints: array expected");
|
|
33716
|
+
message.splitPoints = [];
|
|
33717
|
+
for (var i = 0; i < object.splitPoints.length; ++i) {
|
|
33718
|
+
if (typeof object.splitPoints[i] !== "object")
|
|
33719
|
+
throw TypeError(".google.spanner.admin.database.v1.AddSplitPointsRequest.splitPoints: object expected");
|
|
33720
|
+
message.splitPoints[i] = $root.google.spanner.admin.database.v1.SplitPoints.fromObject(object.splitPoints[i]);
|
|
33721
|
+
}
|
|
33722
|
+
}
|
|
33723
|
+
if (object.initiator != null)
|
|
33724
|
+
message.initiator = String(object.initiator);
|
|
33725
|
+
return message;
|
|
33726
|
+
};
|
|
33727
|
+
|
|
33728
|
+
/**
|
|
33729
|
+
* Creates a plain object from an AddSplitPointsRequest message. Also converts values to other types if specified.
|
|
33730
|
+
* @function toObject
|
|
33731
|
+
* @memberof google.spanner.admin.database.v1.AddSplitPointsRequest
|
|
33732
|
+
* @static
|
|
33733
|
+
* @param {google.spanner.admin.database.v1.AddSplitPointsRequest} message AddSplitPointsRequest
|
|
33734
|
+
* @param {$protobuf.IConversionOptions} [options] Conversion options
|
|
33735
|
+
* @returns {Object.<string,*>} Plain object
|
|
33736
|
+
*/
|
|
33737
|
+
AddSplitPointsRequest.toObject = function toObject(message, options) {
|
|
33738
|
+
if (!options)
|
|
33739
|
+
options = {};
|
|
33740
|
+
var object = {};
|
|
33741
|
+
if (options.arrays || options.defaults)
|
|
33742
|
+
object.splitPoints = [];
|
|
33743
|
+
if (options.defaults) {
|
|
33744
|
+
object.database = "";
|
|
33745
|
+
object.initiator = "";
|
|
33746
|
+
}
|
|
33747
|
+
if (message.database != null && message.hasOwnProperty("database"))
|
|
33748
|
+
object.database = message.database;
|
|
33749
|
+
if (message.splitPoints && message.splitPoints.length) {
|
|
33750
|
+
object.splitPoints = [];
|
|
33751
|
+
for (var j = 0; j < message.splitPoints.length; ++j)
|
|
33752
|
+
object.splitPoints[j] = $root.google.spanner.admin.database.v1.SplitPoints.toObject(message.splitPoints[j], options);
|
|
33753
|
+
}
|
|
33754
|
+
if (message.initiator != null && message.hasOwnProperty("initiator"))
|
|
33755
|
+
object.initiator = message.initiator;
|
|
33756
|
+
return object;
|
|
33757
|
+
};
|
|
33758
|
+
|
|
33759
|
+
/**
|
|
33760
|
+
* Converts this AddSplitPointsRequest to JSON.
|
|
33761
|
+
* @function toJSON
|
|
33762
|
+
* @memberof google.spanner.admin.database.v1.AddSplitPointsRequest
|
|
33763
|
+
* @instance
|
|
33764
|
+
* @returns {Object.<string,*>} JSON object
|
|
33765
|
+
*/
|
|
33766
|
+
AddSplitPointsRequest.prototype.toJSON = function toJSON() {
|
|
33767
|
+
return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
|
|
33768
|
+
};
|
|
33769
|
+
|
|
33770
|
+
/**
|
|
33771
|
+
* Gets the default type url for AddSplitPointsRequest
|
|
33772
|
+
* @function getTypeUrl
|
|
33773
|
+
* @memberof google.spanner.admin.database.v1.AddSplitPointsRequest
|
|
33774
|
+
* @static
|
|
33775
|
+
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
|
|
33776
|
+
* @returns {string} The default type url
|
|
33777
|
+
*/
|
|
33778
|
+
AddSplitPointsRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) {
|
|
33779
|
+
if (typeUrlPrefix === undefined) {
|
|
33780
|
+
typeUrlPrefix = "type.googleapis.com";
|
|
33781
|
+
}
|
|
33782
|
+
return typeUrlPrefix + "/google.spanner.admin.database.v1.AddSplitPointsRequest";
|
|
33783
|
+
};
|
|
33784
|
+
|
|
33785
|
+
return AddSplitPointsRequest;
|
|
33786
|
+
})();
|
|
33787
|
+
|
|
33788
|
+
v1.AddSplitPointsResponse = (function() {
|
|
33789
|
+
|
|
33790
|
+
/**
|
|
33791
|
+
* Properties of an AddSplitPointsResponse.
|
|
33792
|
+
* @memberof google.spanner.admin.database.v1
|
|
33793
|
+
* @interface IAddSplitPointsResponse
|
|
33794
|
+
*/
|
|
33795
|
+
|
|
33796
|
+
/**
|
|
33797
|
+
* Constructs a new AddSplitPointsResponse.
|
|
33798
|
+
* @memberof google.spanner.admin.database.v1
|
|
33799
|
+
* @classdesc Represents an AddSplitPointsResponse.
|
|
33800
|
+
* @implements IAddSplitPointsResponse
|
|
33801
|
+
* @constructor
|
|
33802
|
+
* @param {google.spanner.admin.database.v1.IAddSplitPointsResponse=} [properties] Properties to set
|
|
33803
|
+
*/
|
|
33804
|
+
function AddSplitPointsResponse(properties) {
|
|
33805
|
+
if (properties)
|
|
33806
|
+
for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
|
|
33807
|
+
if (properties[keys[i]] != null)
|
|
33808
|
+
this[keys[i]] = properties[keys[i]];
|
|
33809
|
+
}
|
|
33810
|
+
|
|
33811
|
+
/**
|
|
33812
|
+
* Creates a new AddSplitPointsResponse instance using the specified properties.
|
|
33813
|
+
* @function create
|
|
33814
|
+
* @memberof google.spanner.admin.database.v1.AddSplitPointsResponse
|
|
33815
|
+
* @static
|
|
33816
|
+
* @param {google.spanner.admin.database.v1.IAddSplitPointsResponse=} [properties] Properties to set
|
|
33817
|
+
* @returns {google.spanner.admin.database.v1.AddSplitPointsResponse} AddSplitPointsResponse instance
|
|
33818
|
+
*/
|
|
33819
|
+
AddSplitPointsResponse.create = function create(properties) {
|
|
33820
|
+
return new AddSplitPointsResponse(properties);
|
|
33821
|
+
};
|
|
33822
|
+
|
|
33823
|
+
/**
|
|
33824
|
+
* Encodes the specified AddSplitPointsResponse message. Does not implicitly {@link google.spanner.admin.database.v1.AddSplitPointsResponse.verify|verify} messages.
|
|
33825
|
+
* @function encode
|
|
33826
|
+
* @memberof google.spanner.admin.database.v1.AddSplitPointsResponse
|
|
33827
|
+
* @static
|
|
33828
|
+
* @param {google.spanner.admin.database.v1.IAddSplitPointsResponse} message AddSplitPointsResponse message or plain object to encode
|
|
33829
|
+
* @param {$protobuf.Writer} [writer] Writer to encode to
|
|
33830
|
+
* @returns {$protobuf.Writer} Writer
|
|
33831
|
+
*/
|
|
33832
|
+
AddSplitPointsResponse.encode = function encode(message, writer) {
|
|
33833
|
+
if (!writer)
|
|
33834
|
+
writer = $Writer.create();
|
|
33835
|
+
return writer;
|
|
33836
|
+
};
|
|
33837
|
+
|
|
33838
|
+
/**
|
|
33839
|
+
* Encodes the specified AddSplitPointsResponse message, length delimited. Does not implicitly {@link google.spanner.admin.database.v1.AddSplitPointsResponse.verify|verify} messages.
|
|
33840
|
+
* @function encodeDelimited
|
|
33841
|
+
* @memberof google.spanner.admin.database.v1.AddSplitPointsResponse
|
|
33842
|
+
* @static
|
|
33843
|
+
* @param {google.spanner.admin.database.v1.IAddSplitPointsResponse} message AddSplitPointsResponse message or plain object to encode
|
|
33844
|
+
* @param {$protobuf.Writer} [writer] Writer to encode to
|
|
33845
|
+
* @returns {$protobuf.Writer} Writer
|
|
33846
|
+
*/
|
|
33847
|
+
AddSplitPointsResponse.encodeDelimited = function encodeDelimited(message, writer) {
|
|
33848
|
+
return this.encode(message, writer).ldelim();
|
|
33849
|
+
};
|
|
33850
|
+
|
|
33851
|
+
/**
|
|
33852
|
+
* Decodes an AddSplitPointsResponse message from the specified reader or buffer.
|
|
33853
|
+
* @function decode
|
|
33854
|
+
* @memberof google.spanner.admin.database.v1.AddSplitPointsResponse
|
|
33855
|
+
* @static
|
|
33856
|
+
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
|
|
33857
|
+
* @param {number} [length] Message length if known beforehand
|
|
33858
|
+
* @returns {google.spanner.admin.database.v1.AddSplitPointsResponse} AddSplitPointsResponse
|
|
33859
|
+
* @throws {Error} If the payload is not a reader or valid buffer
|
|
33860
|
+
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
|
33861
|
+
*/
|
|
33862
|
+
AddSplitPointsResponse.decode = function decode(reader, length) {
|
|
33863
|
+
if (!(reader instanceof $Reader))
|
|
33864
|
+
reader = $Reader.create(reader);
|
|
33865
|
+
var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.spanner.admin.database.v1.AddSplitPointsResponse();
|
|
33866
|
+
while (reader.pos < end) {
|
|
33867
|
+
var tag = reader.uint32();
|
|
33868
|
+
switch (tag >>> 3) {
|
|
33869
|
+
default:
|
|
33870
|
+
reader.skipType(tag & 7);
|
|
33871
|
+
break;
|
|
33872
|
+
}
|
|
33873
|
+
}
|
|
33874
|
+
return message;
|
|
33875
|
+
};
|
|
33876
|
+
|
|
33877
|
+
/**
|
|
33878
|
+
* Decodes an AddSplitPointsResponse message from the specified reader or buffer, length delimited.
|
|
33879
|
+
* @function decodeDelimited
|
|
33880
|
+
* @memberof google.spanner.admin.database.v1.AddSplitPointsResponse
|
|
33881
|
+
* @static
|
|
33882
|
+
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
|
|
33883
|
+
* @returns {google.spanner.admin.database.v1.AddSplitPointsResponse} AddSplitPointsResponse
|
|
33884
|
+
* @throws {Error} If the payload is not a reader or valid buffer
|
|
33885
|
+
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
|
33886
|
+
*/
|
|
33887
|
+
AddSplitPointsResponse.decodeDelimited = function decodeDelimited(reader) {
|
|
33888
|
+
if (!(reader instanceof $Reader))
|
|
33889
|
+
reader = new $Reader(reader);
|
|
33890
|
+
return this.decode(reader, reader.uint32());
|
|
33891
|
+
};
|
|
33892
|
+
|
|
33893
|
+
/**
|
|
33894
|
+
* Verifies an AddSplitPointsResponse message.
|
|
33895
|
+
* @function verify
|
|
33896
|
+
* @memberof google.spanner.admin.database.v1.AddSplitPointsResponse
|
|
33897
|
+
* @static
|
|
33898
|
+
* @param {Object.<string,*>} message Plain object to verify
|
|
33899
|
+
* @returns {string|null} `null` if valid, otherwise the reason why it is not
|
|
33900
|
+
*/
|
|
33901
|
+
AddSplitPointsResponse.verify = function verify(message) {
|
|
33902
|
+
if (typeof message !== "object" || message === null)
|
|
33903
|
+
return "object expected";
|
|
33904
|
+
return null;
|
|
33905
|
+
};
|
|
33906
|
+
|
|
33907
|
+
/**
|
|
33908
|
+
* Creates an AddSplitPointsResponse message from a plain object. Also converts values to their respective internal types.
|
|
33909
|
+
* @function fromObject
|
|
33910
|
+
* @memberof google.spanner.admin.database.v1.AddSplitPointsResponse
|
|
33911
|
+
* @static
|
|
33912
|
+
* @param {Object.<string,*>} object Plain object
|
|
33913
|
+
* @returns {google.spanner.admin.database.v1.AddSplitPointsResponse} AddSplitPointsResponse
|
|
33914
|
+
*/
|
|
33915
|
+
AddSplitPointsResponse.fromObject = function fromObject(object) {
|
|
33916
|
+
if (object instanceof $root.google.spanner.admin.database.v1.AddSplitPointsResponse)
|
|
33917
|
+
return object;
|
|
33918
|
+
return new $root.google.spanner.admin.database.v1.AddSplitPointsResponse();
|
|
33919
|
+
};
|
|
33920
|
+
|
|
33921
|
+
/**
|
|
33922
|
+
* Creates a plain object from an AddSplitPointsResponse message. Also converts values to other types if specified.
|
|
33923
|
+
* @function toObject
|
|
33924
|
+
* @memberof google.spanner.admin.database.v1.AddSplitPointsResponse
|
|
33925
|
+
* @static
|
|
33926
|
+
* @param {google.spanner.admin.database.v1.AddSplitPointsResponse} message AddSplitPointsResponse
|
|
33927
|
+
* @param {$protobuf.IConversionOptions} [options] Conversion options
|
|
33928
|
+
* @returns {Object.<string,*>} Plain object
|
|
33929
|
+
*/
|
|
33930
|
+
AddSplitPointsResponse.toObject = function toObject() {
|
|
33931
|
+
return {};
|
|
33932
|
+
};
|
|
33933
|
+
|
|
33934
|
+
/**
|
|
33935
|
+
* Converts this AddSplitPointsResponse to JSON.
|
|
33936
|
+
* @function toJSON
|
|
33937
|
+
* @memberof google.spanner.admin.database.v1.AddSplitPointsResponse
|
|
33938
|
+
* @instance
|
|
33939
|
+
* @returns {Object.<string,*>} JSON object
|
|
33940
|
+
*/
|
|
33941
|
+
AddSplitPointsResponse.prototype.toJSON = function toJSON() {
|
|
33942
|
+
return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
|
|
33943
|
+
};
|
|
33944
|
+
|
|
33945
|
+
/**
|
|
33946
|
+
* Gets the default type url for AddSplitPointsResponse
|
|
33947
|
+
* @function getTypeUrl
|
|
33948
|
+
* @memberof google.spanner.admin.database.v1.AddSplitPointsResponse
|
|
33949
|
+
* @static
|
|
33950
|
+
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
|
|
33951
|
+
* @returns {string} The default type url
|
|
33952
|
+
*/
|
|
33953
|
+
AddSplitPointsResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) {
|
|
33954
|
+
if (typeUrlPrefix === undefined) {
|
|
33955
|
+
typeUrlPrefix = "type.googleapis.com";
|
|
33956
|
+
}
|
|
33957
|
+
return typeUrlPrefix + "/google.spanner.admin.database.v1.AddSplitPointsResponse";
|
|
33958
|
+
};
|
|
33959
|
+
|
|
33960
|
+
return AddSplitPointsResponse;
|
|
33961
|
+
})();
|
|
33962
|
+
|
|
33963
|
+
v1.SplitPoints = (function() {
|
|
33964
|
+
|
|
33965
|
+
/**
|
|
33966
|
+
* Properties of a SplitPoints.
|
|
33967
|
+
* @memberof google.spanner.admin.database.v1
|
|
33968
|
+
* @interface ISplitPoints
|
|
33969
|
+
* @property {string|null} [table] SplitPoints table
|
|
33970
|
+
* @property {string|null} [index] SplitPoints index
|
|
33971
|
+
* @property {Array.<google.spanner.admin.database.v1.SplitPoints.IKey>|null} [keys] SplitPoints keys
|
|
33972
|
+
* @property {google.protobuf.ITimestamp|null} [expireTime] SplitPoints expireTime
|
|
33973
|
+
*/
|
|
33974
|
+
|
|
33975
|
+
/**
|
|
33976
|
+
* Constructs a new SplitPoints.
|
|
33977
|
+
* @memberof google.spanner.admin.database.v1
|
|
33978
|
+
* @classdesc Represents a SplitPoints.
|
|
33979
|
+
* @implements ISplitPoints
|
|
33980
|
+
* @constructor
|
|
33981
|
+
* @param {google.spanner.admin.database.v1.ISplitPoints=} [properties] Properties to set
|
|
33982
|
+
*/
|
|
33983
|
+
function SplitPoints(properties) {
|
|
33984
|
+
this.keys = [];
|
|
33985
|
+
if (properties)
|
|
33986
|
+
for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
|
|
33987
|
+
if (properties[keys[i]] != null)
|
|
33988
|
+
this[keys[i]] = properties[keys[i]];
|
|
33989
|
+
}
|
|
33990
|
+
|
|
33991
|
+
/**
|
|
33992
|
+
* SplitPoints table.
|
|
33993
|
+
* @member {string} table
|
|
33994
|
+
* @memberof google.spanner.admin.database.v1.SplitPoints
|
|
33995
|
+
* @instance
|
|
33996
|
+
*/
|
|
33997
|
+
SplitPoints.prototype.table = "";
|
|
33998
|
+
|
|
33999
|
+
/**
|
|
34000
|
+
* SplitPoints index.
|
|
34001
|
+
* @member {string} index
|
|
34002
|
+
* @memberof google.spanner.admin.database.v1.SplitPoints
|
|
34003
|
+
* @instance
|
|
34004
|
+
*/
|
|
34005
|
+
SplitPoints.prototype.index = "";
|
|
34006
|
+
|
|
34007
|
+
/**
|
|
34008
|
+
* SplitPoints keys.
|
|
34009
|
+
* @member {Array.<google.spanner.admin.database.v1.SplitPoints.IKey>} keys
|
|
34010
|
+
* @memberof google.spanner.admin.database.v1.SplitPoints
|
|
34011
|
+
* @instance
|
|
34012
|
+
*/
|
|
34013
|
+
SplitPoints.prototype.keys = $util.emptyArray;
|
|
34014
|
+
|
|
34015
|
+
/**
|
|
34016
|
+
* SplitPoints expireTime.
|
|
34017
|
+
* @member {google.protobuf.ITimestamp|null|undefined} expireTime
|
|
34018
|
+
* @memberof google.spanner.admin.database.v1.SplitPoints
|
|
34019
|
+
* @instance
|
|
34020
|
+
*/
|
|
34021
|
+
SplitPoints.prototype.expireTime = null;
|
|
34022
|
+
|
|
34023
|
+
/**
|
|
34024
|
+
* Creates a new SplitPoints instance using the specified properties.
|
|
34025
|
+
* @function create
|
|
34026
|
+
* @memberof google.spanner.admin.database.v1.SplitPoints
|
|
34027
|
+
* @static
|
|
34028
|
+
* @param {google.spanner.admin.database.v1.ISplitPoints=} [properties] Properties to set
|
|
34029
|
+
* @returns {google.spanner.admin.database.v1.SplitPoints} SplitPoints instance
|
|
34030
|
+
*/
|
|
34031
|
+
SplitPoints.create = function create(properties) {
|
|
34032
|
+
return new SplitPoints(properties);
|
|
34033
|
+
};
|
|
34034
|
+
|
|
34035
|
+
/**
|
|
34036
|
+
* Encodes the specified SplitPoints message. Does not implicitly {@link google.spanner.admin.database.v1.SplitPoints.verify|verify} messages.
|
|
34037
|
+
* @function encode
|
|
34038
|
+
* @memberof google.spanner.admin.database.v1.SplitPoints
|
|
34039
|
+
* @static
|
|
34040
|
+
* @param {google.spanner.admin.database.v1.ISplitPoints} message SplitPoints message or plain object to encode
|
|
34041
|
+
* @param {$protobuf.Writer} [writer] Writer to encode to
|
|
34042
|
+
* @returns {$protobuf.Writer} Writer
|
|
34043
|
+
*/
|
|
34044
|
+
SplitPoints.encode = function encode(message, writer) {
|
|
34045
|
+
if (!writer)
|
|
34046
|
+
writer = $Writer.create();
|
|
34047
|
+
if (message.table != null && Object.hasOwnProperty.call(message, "table"))
|
|
34048
|
+
writer.uint32(/* id 1, wireType 2 =*/10).string(message.table);
|
|
34049
|
+
if (message.index != null && Object.hasOwnProperty.call(message, "index"))
|
|
34050
|
+
writer.uint32(/* id 2, wireType 2 =*/18).string(message.index);
|
|
34051
|
+
if (message.keys != null && message.keys.length)
|
|
34052
|
+
for (var i = 0; i < message.keys.length; ++i)
|
|
34053
|
+
$root.google.spanner.admin.database.v1.SplitPoints.Key.encode(message.keys[i], writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim();
|
|
34054
|
+
if (message.expireTime != null && Object.hasOwnProperty.call(message, "expireTime"))
|
|
34055
|
+
$root.google.protobuf.Timestamp.encode(message.expireTime, writer.uint32(/* id 5, wireType 2 =*/42).fork()).ldelim();
|
|
34056
|
+
return writer;
|
|
34057
|
+
};
|
|
34058
|
+
|
|
34059
|
+
/**
|
|
34060
|
+
* Encodes the specified SplitPoints message, length delimited. Does not implicitly {@link google.spanner.admin.database.v1.SplitPoints.verify|verify} messages.
|
|
34061
|
+
* @function encodeDelimited
|
|
34062
|
+
* @memberof google.spanner.admin.database.v1.SplitPoints
|
|
34063
|
+
* @static
|
|
34064
|
+
* @param {google.spanner.admin.database.v1.ISplitPoints} message SplitPoints message or plain object to encode
|
|
34065
|
+
* @param {$protobuf.Writer} [writer] Writer to encode to
|
|
34066
|
+
* @returns {$protobuf.Writer} Writer
|
|
34067
|
+
*/
|
|
34068
|
+
SplitPoints.encodeDelimited = function encodeDelimited(message, writer) {
|
|
34069
|
+
return this.encode(message, writer).ldelim();
|
|
34070
|
+
};
|
|
34071
|
+
|
|
34072
|
+
/**
|
|
34073
|
+
* Decodes a SplitPoints message from the specified reader or buffer.
|
|
34074
|
+
* @function decode
|
|
34075
|
+
* @memberof google.spanner.admin.database.v1.SplitPoints
|
|
34076
|
+
* @static
|
|
34077
|
+
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
|
|
34078
|
+
* @param {number} [length] Message length if known beforehand
|
|
34079
|
+
* @returns {google.spanner.admin.database.v1.SplitPoints} SplitPoints
|
|
34080
|
+
* @throws {Error} If the payload is not a reader or valid buffer
|
|
34081
|
+
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
|
34082
|
+
*/
|
|
34083
|
+
SplitPoints.decode = function decode(reader, length) {
|
|
34084
|
+
if (!(reader instanceof $Reader))
|
|
34085
|
+
reader = $Reader.create(reader);
|
|
34086
|
+
var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.spanner.admin.database.v1.SplitPoints();
|
|
34087
|
+
while (reader.pos < end) {
|
|
34088
|
+
var tag = reader.uint32();
|
|
34089
|
+
switch (tag >>> 3) {
|
|
34090
|
+
case 1: {
|
|
34091
|
+
message.table = reader.string();
|
|
34092
|
+
break;
|
|
34093
|
+
}
|
|
34094
|
+
case 2: {
|
|
34095
|
+
message.index = reader.string();
|
|
34096
|
+
break;
|
|
34097
|
+
}
|
|
34098
|
+
case 3: {
|
|
34099
|
+
if (!(message.keys && message.keys.length))
|
|
34100
|
+
message.keys = [];
|
|
34101
|
+
message.keys.push($root.google.spanner.admin.database.v1.SplitPoints.Key.decode(reader, reader.uint32()));
|
|
34102
|
+
break;
|
|
34103
|
+
}
|
|
34104
|
+
case 5: {
|
|
34105
|
+
message.expireTime = $root.google.protobuf.Timestamp.decode(reader, reader.uint32());
|
|
34106
|
+
break;
|
|
34107
|
+
}
|
|
34108
|
+
default:
|
|
34109
|
+
reader.skipType(tag & 7);
|
|
34110
|
+
break;
|
|
34111
|
+
}
|
|
34112
|
+
}
|
|
34113
|
+
return message;
|
|
34114
|
+
};
|
|
34115
|
+
|
|
34116
|
+
/**
|
|
34117
|
+
* Decodes a SplitPoints message from the specified reader or buffer, length delimited.
|
|
34118
|
+
* @function decodeDelimited
|
|
34119
|
+
* @memberof google.spanner.admin.database.v1.SplitPoints
|
|
34120
|
+
* @static
|
|
34121
|
+
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
|
|
34122
|
+
* @returns {google.spanner.admin.database.v1.SplitPoints} SplitPoints
|
|
34123
|
+
* @throws {Error} If the payload is not a reader or valid buffer
|
|
34124
|
+
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
|
34125
|
+
*/
|
|
34126
|
+
SplitPoints.decodeDelimited = function decodeDelimited(reader) {
|
|
34127
|
+
if (!(reader instanceof $Reader))
|
|
34128
|
+
reader = new $Reader(reader);
|
|
34129
|
+
return this.decode(reader, reader.uint32());
|
|
34130
|
+
};
|
|
34131
|
+
|
|
34132
|
+
/**
|
|
34133
|
+
* Verifies a SplitPoints message.
|
|
34134
|
+
* @function verify
|
|
34135
|
+
* @memberof google.spanner.admin.database.v1.SplitPoints
|
|
34136
|
+
* @static
|
|
34137
|
+
* @param {Object.<string,*>} message Plain object to verify
|
|
34138
|
+
* @returns {string|null} `null` if valid, otherwise the reason why it is not
|
|
34139
|
+
*/
|
|
34140
|
+
SplitPoints.verify = function verify(message) {
|
|
34141
|
+
if (typeof message !== "object" || message === null)
|
|
34142
|
+
return "object expected";
|
|
34143
|
+
if (message.table != null && message.hasOwnProperty("table"))
|
|
34144
|
+
if (!$util.isString(message.table))
|
|
34145
|
+
return "table: string expected";
|
|
34146
|
+
if (message.index != null && message.hasOwnProperty("index"))
|
|
34147
|
+
if (!$util.isString(message.index))
|
|
34148
|
+
return "index: string expected";
|
|
34149
|
+
if (message.keys != null && message.hasOwnProperty("keys")) {
|
|
34150
|
+
if (!Array.isArray(message.keys))
|
|
34151
|
+
return "keys: array expected";
|
|
34152
|
+
for (var i = 0; i < message.keys.length; ++i) {
|
|
34153
|
+
var error = $root.google.spanner.admin.database.v1.SplitPoints.Key.verify(message.keys[i]);
|
|
34154
|
+
if (error)
|
|
34155
|
+
return "keys." + error;
|
|
34156
|
+
}
|
|
34157
|
+
}
|
|
34158
|
+
if (message.expireTime != null && message.hasOwnProperty("expireTime")) {
|
|
34159
|
+
var error = $root.google.protobuf.Timestamp.verify(message.expireTime);
|
|
34160
|
+
if (error)
|
|
34161
|
+
return "expireTime." + error;
|
|
34162
|
+
}
|
|
34163
|
+
return null;
|
|
34164
|
+
};
|
|
34165
|
+
|
|
34166
|
+
/**
|
|
34167
|
+
* Creates a SplitPoints message from a plain object. Also converts values to their respective internal types.
|
|
34168
|
+
* @function fromObject
|
|
34169
|
+
* @memberof google.spanner.admin.database.v1.SplitPoints
|
|
34170
|
+
* @static
|
|
34171
|
+
* @param {Object.<string,*>} object Plain object
|
|
34172
|
+
* @returns {google.spanner.admin.database.v1.SplitPoints} SplitPoints
|
|
34173
|
+
*/
|
|
34174
|
+
SplitPoints.fromObject = function fromObject(object) {
|
|
34175
|
+
if (object instanceof $root.google.spanner.admin.database.v1.SplitPoints)
|
|
34176
|
+
return object;
|
|
34177
|
+
var message = new $root.google.spanner.admin.database.v1.SplitPoints();
|
|
34178
|
+
if (object.table != null)
|
|
34179
|
+
message.table = String(object.table);
|
|
34180
|
+
if (object.index != null)
|
|
34181
|
+
message.index = String(object.index);
|
|
34182
|
+
if (object.keys) {
|
|
34183
|
+
if (!Array.isArray(object.keys))
|
|
34184
|
+
throw TypeError(".google.spanner.admin.database.v1.SplitPoints.keys: array expected");
|
|
34185
|
+
message.keys = [];
|
|
34186
|
+
for (var i = 0; i < object.keys.length; ++i) {
|
|
34187
|
+
if (typeof object.keys[i] !== "object")
|
|
34188
|
+
throw TypeError(".google.spanner.admin.database.v1.SplitPoints.keys: object expected");
|
|
34189
|
+
message.keys[i] = $root.google.spanner.admin.database.v1.SplitPoints.Key.fromObject(object.keys[i]);
|
|
34190
|
+
}
|
|
34191
|
+
}
|
|
34192
|
+
if (object.expireTime != null) {
|
|
34193
|
+
if (typeof object.expireTime !== "object")
|
|
34194
|
+
throw TypeError(".google.spanner.admin.database.v1.SplitPoints.expireTime: object expected");
|
|
34195
|
+
message.expireTime = $root.google.protobuf.Timestamp.fromObject(object.expireTime);
|
|
34196
|
+
}
|
|
34197
|
+
return message;
|
|
34198
|
+
};
|
|
34199
|
+
|
|
34200
|
+
/**
|
|
34201
|
+
* Creates a plain object from a SplitPoints message. Also converts values to other types if specified.
|
|
34202
|
+
* @function toObject
|
|
34203
|
+
* @memberof google.spanner.admin.database.v1.SplitPoints
|
|
34204
|
+
* @static
|
|
34205
|
+
* @param {google.spanner.admin.database.v1.SplitPoints} message SplitPoints
|
|
34206
|
+
* @param {$protobuf.IConversionOptions} [options] Conversion options
|
|
34207
|
+
* @returns {Object.<string,*>} Plain object
|
|
34208
|
+
*/
|
|
34209
|
+
SplitPoints.toObject = function toObject(message, options) {
|
|
34210
|
+
if (!options)
|
|
34211
|
+
options = {};
|
|
34212
|
+
var object = {};
|
|
34213
|
+
if (options.arrays || options.defaults)
|
|
34214
|
+
object.keys = [];
|
|
34215
|
+
if (options.defaults) {
|
|
34216
|
+
object.table = "";
|
|
34217
|
+
object.index = "";
|
|
34218
|
+
object.expireTime = null;
|
|
34219
|
+
}
|
|
34220
|
+
if (message.table != null && message.hasOwnProperty("table"))
|
|
34221
|
+
object.table = message.table;
|
|
34222
|
+
if (message.index != null && message.hasOwnProperty("index"))
|
|
34223
|
+
object.index = message.index;
|
|
34224
|
+
if (message.keys && message.keys.length) {
|
|
34225
|
+
object.keys = [];
|
|
34226
|
+
for (var j = 0; j < message.keys.length; ++j)
|
|
34227
|
+
object.keys[j] = $root.google.spanner.admin.database.v1.SplitPoints.Key.toObject(message.keys[j], options);
|
|
34228
|
+
}
|
|
34229
|
+
if (message.expireTime != null && message.hasOwnProperty("expireTime"))
|
|
34230
|
+
object.expireTime = $root.google.protobuf.Timestamp.toObject(message.expireTime, options);
|
|
34231
|
+
return object;
|
|
34232
|
+
};
|
|
34233
|
+
|
|
34234
|
+
/**
|
|
34235
|
+
* Converts this SplitPoints to JSON.
|
|
34236
|
+
* @function toJSON
|
|
34237
|
+
* @memberof google.spanner.admin.database.v1.SplitPoints
|
|
34238
|
+
* @instance
|
|
34239
|
+
* @returns {Object.<string,*>} JSON object
|
|
34240
|
+
*/
|
|
34241
|
+
SplitPoints.prototype.toJSON = function toJSON() {
|
|
34242
|
+
return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
|
|
34243
|
+
};
|
|
34244
|
+
|
|
34245
|
+
/**
|
|
34246
|
+
* Gets the default type url for SplitPoints
|
|
34247
|
+
* @function getTypeUrl
|
|
34248
|
+
* @memberof google.spanner.admin.database.v1.SplitPoints
|
|
34249
|
+
* @static
|
|
34250
|
+
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
|
|
34251
|
+
* @returns {string} The default type url
|
|
34252
|
+
*/
|
|
34253
|
+
SplitPoints.getTypeUrl = function getTypeUrl(typeUrlPrefix) {
|
|
34254
|
+
if (typeUrlPrefix === undefined) {
|
|
34255
|
+
typeUrlPrefix = "type.googleapis.com";
|
|
34256
|
+
}
|
|
34257
|
+
return typeUrlPrefix + "/google.spanner.admin.database.v1.SplitPoints";
|
|
34258
|
+
};
|
|
34259
|
+
|
|
34260
|
+
SplitPoints.Key = (function() {
|
|
34261
|
+
|
|
34262
|
+
/**
|
|
34263
|
+
* Properties of a Key.
|
|
34264
|
+
* @memberof google.spanner.admin.database.v1.SplitPoints
|
|
34265
|
+
* @interface IKey
|
|
34266
|
+
* @property {google.protobuf.IListValue|null} [keyParts] Key keyParts
|
|
34267
|
+
*/
|
|
34268
|
+
|
|
34269
|
+
/**
|
|
34270
|
+
* Constructs a new Key.
|
|
34271
|
+
* @memberof google.spanner.admin.database.v1.SplitPoints
|
|
34272
|
+
* @classdesc Represents a Key.
|
|
34273
|
+
* @implements IKey
|
|
34274
|
+
* @constructor
|
|
34275
|
+
* @param {google.spanner.admin.database.v1.SplitPoints.IKey=} [properties] Properties to set
|
|
34276
|
+
*/
|
|
34277
|
+
function Key(properties) {
|
|
34278
|
+
if (properties)
|
|
34279
|
+
for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
|
|
34280
|
+
if (properties[keys[i]] != null)
|
|
34281
|
+
this[keys[i]] = properties[keys[i]];
|
|
34282
|
+
}
|
|
34283
|
+
|
|
34284
|
+
/**
|
|
34285
|
+
* Key keyParts.
|
|
34286
|
+
* @member {google.protobuf.IListValue|null|undefined} keyParts
|
|
34287
|
+
* @memberof google.spanner.admin.database.v1.SplitPoints.Key
|
|
34288
|
+
* @instance
|
|
34289
|
+
*/
|
|
34290
|
+
Key.prototype.keyParts = null;
|
|
34291
|
+
|
|
34292
|
+
/**
|
|
34293
|
+
* Creates a new Key instance using the specified properties.
|
|
34294
|
+
* @function create
|
|
34295
|
+
* @memberof google.spanner.admin.database.v1.SplitPoints.Key
|
|
34296
|
+
* @static
|
|
34297
|
+
* @param {google.spanner.admin.database.v1.SplitPoints.IKey=} [properties] Properties to set
|
|
34298
|
+
* @returns {google.spanner.admin.database.v1.SplitPoints.Key} Key instance
|
|
34299
|
+
*/
|
|
34300
|
+
Key.create = function create(properties) {
|
|
34301
|
+
return new Key(properties);
|
|
34302
|
+
};
|
|
34303
|
+
|
|
34304
|
+
/**
|
|
34305
|
+
* Encodes the specified Key message. Does not implicitly {@link google.spanner.admin.database.v1.SplitPoints.Key.verify|verify} messages.
|
|
34306
|
+
* @function encode
|
|
34307
|
+
* @memberof google.spanner.admin.database.v1.SplitPoints.Key
|
|
34308
|
+
* @static
|
|
34309
|
+
* @param {google.spanner.admin.database.v1.SplitPoints.IKey} message Key message or plain object to encode
|
|
34310
|
+
* @param {$protobuf.Writer} [writer] Writer to encode to
|
|
34311
|
+
* @returns {$protobuf.Writer} Writer
|
|
34312
|
+
*/
|
|
34313
|
+
Key.encode = function encode(message, writer) {
|
|
34314
|
+
if (!writer)
|
|
34315
|
+
writer = $Writer.create();
|
|
34316
|
+
if (message.keyParts != null && Object.hasOwnProperty.call(message, "keyParts"))
|
|
34317
|
+
$root.google.protobuf.ListValue.encode(message.keyParts, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim();
|
|
34318
|
+
return writer;
|
|
34319
|
+
};
|
|
34320
|
+
|
|
34321
|
+
/**
|
|
34322
|
+
* Encodes the specified Key message, length delimited. Does not implicitly {@link google.spanner.admin.database.v1.SplitPoints.Key.verify|verify} messages.
|
|
34323
|
+
* @function encodeDelimited
|
|
34324
|
+
* @memberof google.spanner.admin.database.v1.SplitPoints.Key
|
|
34325
|
+
* @static
|
|
34326
|
+
* @param {google.spanner.admin.database.v1.SplitPoints.IKey} message Key message or plain object to encode
|
|
34327
|
+
* @param {$protobuf.Writer} [writer] Writer to encode to
|
|
34328
|
+
* @returns {$protobuf.Writer} Writer
|
|
34329
|
+
*/
|
|
34330
|
+
Key.encodeDelimited = function encodeDelimited(message, writer) {
|
|
34331
|
+
return this.encode(message, writer).ldelim();
|
|
34332
|
+
};
|
|
34333
|
+
|
|
34334
|
+
/**
|
|
34335
|
+
* Decodes a Key message from the specified reader or buffer.
|
|
34336
|
+
* @function decode
|
|
34337
|
+
* @memberof google.spanner.admin.database.v1.SplitPoints.Key
|
|
34338
|
+
* @static
|
|
34339
|
+
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
|
|
34340
|
+
* @param {number} [length] Message length if known beforehand
|
|
34341
|
+
* @returns {google.spanner.admin.database.v1.SplitPoints.Key} Key
|
|
34342
|
+
* @throws {Error} If the payload is not a reader or valid buffer
|
|
34343
|
+
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
|
34344
|
+
*/
|
|
34345
|
+
Key.decode = function decode(reader, length) {
|
|
34346
|
+
if (!(reader instanceof $Reader))
|
|
34347
|
+
reader = $Reader.create(reader);
|
|
34348
|
+
var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.spanner.admin.database.v1.SplitPoints.Key();
|
|
34349
|
+
while (reader.pos < end) {
|
|
34350
|
+
var tag = reader.uint32();
|
|
34351
|
+
switch (tag >>> 3) {
|
|
34352
|
+
case 1: {
|
|
34353
|
+
message.keyParts = $root.google.protobuf.ListValue.decode(reader, reader.uint32());
|
|
34354
|
+
break;
|
|
34355
|
+
}
|
|
34356
|
+
default:
|
|
34357
|
+
reader.skipType(tag & 7);
|
|
34358
|
+
break;
|
|
34359
|
+
}
|
|
34360
|
+
}
|
|
34361
|
+
return message;
|
|
34362
|
+
};
|
|
34363
|
+
|
|
34364
|
+
/**
|
|
34365
|
+
* Decodes a Key message from the specified reader or buffer, length delimited.
|
|
34366
|
+
* @function decodeDelimited
|
|
34367
|
+
* @memberof google.spanner.admin.database.v1.SplitPoints.Key
|
|
34368
|
+
* @static
|
|
34369
|
+
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
|
|
34370
|
+
* @returns {google.spanner.admin.database.v1.SplitPoints.Key} Key
|
|
34371
|
+
* @throws {Error} If the payload is not a reader or valid buffer
|
|
34372
|
+
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
|
34373
|
+
*/
|
|
34374
|
+
Key.decodeDelimited = function decodeDelimited(reader) {
|
|
34375
|
+
if (!(reader instanceof $Reader))
|
|
34376
|
+
reader = new $Reader(reader);
|
|
34377
|
+
return this.decode(reader, reader.uint32());
|
|
34378
|
+
};
|
|
34379
|
+
|
|
34380
|
+
/**
|
|
34381
|
+
* Verifies a Key message.
|
|
34382
|
+
* @function verify
|
|
34383
|
+
* @memberof google.spanner.admin.database.v1.SplitPoints.Key
|
|
34384
|
+
* @static
|
|
34385
|
+
* @param {Object.<string,*>} message Plain object to verify
|
|
34386
|
+
* @returns {string|null} `null` if valid, otherwise the reason why it is not
|
|
34387
|
+
*/
|
|
34388
|
+
Key.verify = function verify(message) {
|
|
34389
|
+
if (typeof message !== "object" || message === null)
|
|
34390
|
+
return "object expected";
|
|
34391
|
+
if (message.keyParts != null && message.hasOwnProperty("keyParts")) {
|
|
34392
|
+
var error = $root.google.protobuf.ListValue.verify(message.keyParts);
|
|
34393
|
+
if (error)
|
|
34394
|
+
return "keyParts." + error;
|
|
34395
|
+
}
|
|
34396
|
+
return null;
|
|
34397
|
+
};
|
|
34398
|
+
|
|
34399
|
+
/**
|
|
34400
|
+
* Creates a Key message from a plain object. Also converts values to their respective internal types.
|
|
34401
|
+
* @function fromObject
|
|
34402
|
+
* @memberof google.spanner.admin.database.v1.SplitPoints.Key
|
|
34403
|
+
* @static
|
|
34404
|
+
* @param {Object.<string,*>} object Plain object
|
|
34405
|
+
* @returns {google.spanner.admin.database.v1.SplitPoints.Key} Key
|
|
34406
|
+
*/
|
|
34407
|
+
Key.fromObject = function fromObject(object) {
|
|
34408
|
+
if (object instanceof $root.google.spanner.admin.database.v1.SplitPoints.Key)
|
|
34409
|
+
return object;
|
|
34410
|
+
var message = new $root.google.spanner.admin.database.v1.SplitPoints.Key();
|
|
34411
|
+
if (object.keyParts != null) {
|
|
34412
|
+
if (typeof object.keyParts !== "object")
|
|
34413
|
+
throw TypeError(".google.spanner.admin.database.v1.SplitPoints.Key.keyParts: object expected");
|
|
34414
|
+
message.keyParts = $root.google.protobuf.ListValue.fromObject(object.keyParts);
|
|
34415
|
+
}
|
|
34416
|
+
return message;
|
|
34417
|
+
};
|
|
34418
|
+
|
|
34419
|
+
/**
|
|
34420
|
+
* Creates a plain object from a Key message. Also converts values to other types if specified.
|
|
34421
|
+
* @function toObject
|
|
34422
|
+
* @memberof google.spanner.admin.database.v1.SplitPoints.Key
|
|
34423
|
+
* @static
|
|
34424
|
+
* @param {google.spanner.admin.database.v1.SplitPoints.Key} message Key
|
|
34425
|
+
* @param {$protobuf.IConversionOptions} [options] Conversion options
|
|
34426
|
+
* @returns {Object.<string,*>} Plain object
|
|
34427
|
+
*/
|
|
34428
|
+
Key.toObject = function toObject(message, options) {
|
|
34429
|
+
if (!options)
|
|
34430
|
+
options = {};
|
|
34431
|
+
var object = {};
|
|
34432
|
+
if (options.defaults)
|
|
34433
|
+
object.keyParts = null;
|
|
34434
|
+
if (message.keyParts != null && message.hasOwnProperty("keyParts"))
|
|
34435
|
+
object.keyParts = $root.google.protobuf.ListValue.toObject(message.keyParts, options);
|
|
34436
|
+
return object;
|
|
34437
|
+
};
|
|
34438
|
+
|
|
34439
|
+
/**
|
|
34440
|
+
* Converts this Key to JSON.
|
|
34441
|
+
* @function toJSON
|
|
34442
|
+
* @memberof google.spanner.admin.database.v1.SplitPoints.Key
|
|
34443
|
+
* @instance
|
|
34444
|
+
* @returns {Object.<string,*>} JSON object
|
|
34445
|
+
*/
|
|
34446
|
+
Key.prototype.toJSON = function toJSON() {
|
|
34447
|
+
return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
|
|
34448
|
+
};
|
|
34449
|
+
|
|
34450
|
+
/**
|
|
34451
|
+
* Gets the default type url for Key
|
|
34452
|
+
* @function getTypeUrl
|
|
34453
|
+
* @memberof google.spanner.admin.database.v1.SplitPoints.Key
|
|
34454
|
+
* @static
|
|
34455
|
+
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
|
|
34456
|
+
* @returns {string} The default type url
|
|
34457
|
+
*/
|
|
34458
|
+
Key.getTypeUrl = function getTypeUrl(typeUrlPrefix) {
|
|
34459
|
+
if (typeUrlPrefix === undefined) {
|
|
34460
|
+
typeUrlPrefix = "type.googleapis.com";
|
|
34461
|
+
}
|
|
34462
|
+
return typeUrlPrefix + "/google.spanner.admin.database.v1.SplitPoints.Key";
|
|
34463
|
+
};
|
|
34464
|
+
|
|
34465
|
+
return Key;
|
|
34466
|
+
})();
|
|
34467
|
+
|
|
34468
|
+
return SplitPoints;
|
|
34469
|
+
})();
|
|
34470
|
+
|
|
33236
34471
|
return v1;
|
|
33237
34472
|
})();
|
|
33238
34473
|
|
|
@@ -82096,6 +83331,7 @@
|
|
|
82096
83331
|
* @property {google.spanner.v1.TransactionOptions.IPartitionedDml|null} [partitionedDml] TransactionOptions partitionedDml
|
|
82097
83332
|
* @property {google.spanner.v1.TransactionOptions.IReadOnly|null} [readOnly] TransactionOptions readOnly
|
|
82098
83333
|
* @property {boolean|null} [excludeTxnFromChangeStreams] TransactionOptions excludeTxnFromChangeStreams
|
|
83334
|
+
* @property {google.spanner.v1.TransactionOptions.IsolationLevel|null} [isolationLevel] TransactionOptions isolationLevel
|
|
82099
83335
|
*/
|
|
82100
83336
|
|
|
82101
83337
|
/**
|
|
@@ -82145,6 +83381,14 @@
|
|
|
82145
83381
|
*/
|
|
82146
83382
|
TransactionOptions.prototype.excludeTxnFromChangeStreams = false;
|
|
82147
83383
|
|
|
83384
|
+
/**
|
|
83385
|
+
* TransactionOptions isolationLevel.
|
|
83386
|
+
* @member {google.spanner.v1.TransactionOptions.IsolationLevel} isolationLevel
|
|
83387
|
+
* @memberof google.spanner.v1.TransactionOptions
|
|
83388
|
+
* @instance
|
|
83389
|
+
*/
|
|
83390
|
+
TransactionOptions.prototype.isolationLevel = 0;
|
|
83391
|
+
|
|
82148
83392
|
// OneOf field names bound to virtual getters and setters
|
|
82149
83393
|
var $oneOfFields;
|
|
82150
83394
|
|
|
@@ -82191,6 +83435,8 @@
|
|
|
82191
83435
|
$root.google.spanner.v1.TransactionOptions.PartitionedDml.encode(message.partitionedDml, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim();
|
|
82192
83436
|
if (message.excludeTxnFromChangeStreams != null && Object.hasOwnProperty.call(message, "excludeTxnFromChangeStreams"))
|
|
82193
83437
|
writer.uint32(/* id 5, wireType 0 =*/40).bool(message.excludeTxnFromChangeStreams);
|
|
83438
|
+
if (message.isolationLevel != null && Object.hasOwnProperty.call(message, "isolationLevel"))
|
|
83439
|
+
writer.uint32(/* id 6, wireType 0 =*/48).int32(message.isolationLevel);
|
|
82194
83440
|
return writer;
|
|
82195
83441
|
};
|
|
82196
83442
|
|
|
@@ -82241,6 +83487,10 @@
|
|
|
82241
83487
|
message.excludeTxnFromChangeStreams = reader.bool();
|
|
82242
83488
|
break;
|
|
82243
83489
|
}
|
|
83490
|
+
case 6: {
|
|
83491
|
+
message.isolationLevel = reader.int32();
|
|
83492
|
+
break;
|
|
83493
|
+
}
|
|
82244
83494
|
default:
|
|
82245
83495
|
reader.skipType(tag & 7);
|
|
82246
83496
|
break;
|
|
@@ -82308,6 +83558,15 @@
|
|
|
82308
83558
|
if (message.excludeTxnFromChangeStreams != null && message.hasOwnProperty("excludeTxnFromChangeStreams"))
|
|
82309
83559
|
if (typeof message.excludeTxnFromChangeStreams !== "boolean")
|
|
82310
83560
|
return "excludeTxnFromChangeStreams: boolean expected";
|
|
83561
|
+
if (message.isolationLevel != null && message.hasOwnProperty("isolationLevel"))
|
|
83562
|
+
switch (message.isolationLevel) {
|
|
83563
|
+
default:
|
|
83564
|
+
return "isolationLevel: enum value expected";
|
|
83565
|
+
case 0:
|
|
83566
|
+
case 1:
|
|
83567
|
+
case 2:
|
|
83568
|
+
break;
|
|
83569
|
+
}
|
|
82311
83570
|
return null;
|
|
82312
83571
|
};
|
|
82313
83572
|
|
|
@@ -82340,6 +83599,26 @@
|
|
|
82340
83599
|
}
|
|
82341
83600
|
if (object.excludeTxnFromChangeStreams != null)
|
|
82342
83601
|
message.excludeTxnFromChangeStreams = Boolean(object.excludeTxnFromChangeStreams);
|
|
83602
|
+
switch (object.isolationLevel) {
|
|
83603
|
+
default:
|
|
83604
|
+
if (typeof object.isolationLevel === "number") {
|
|
83605
|
+
message.isolationLevel = object.isolationLevel;
|
|
83606
|
+
break;
|
|
83607
|
+
}
|
|
83608
|
+
break;
|
|
83609
|
+
case "ISOLATION_LEVEL_UNSPECIFIED":
|
|
83610
|
+
case 0:
|
|
83611
|
+
message.isolationLevel = 0;
|
|
83612
|
+
break;
|
|
83613
|
+
case "SERIALIZABLE":
|
|
83614
|
+
case 1:
|
|
83615
|
+
message.isolationLevel = 1;
|
|
83616
|
+
break;
|
|
83617
|
+
case "REPEATABLE_READ":
|
|
83618
|
+
case 2:
|
|
83619
|
+
message.isolationLevel = 2;
|
|
83620
|
+
break;
|
|
83621
|
+
}
|
|
82343
83622
|
return message;
|
|
82344
83623
|
};
|
|
82345
83624
|
|
|
@@ -82356,8 +83635,10 @@
|
|
|
82356
83635
|
if (!options)
|
|
82357
83636
|
options = {};
|
|
82358
83637
|
var object = {};
|
|
82359
|
-
if (options.defaults)
|
|
83638
|
+
if (options.defaults) {
|
|
82360
83639
|
object.excludeTxnFromChangeStreams = false;
|
|
83640
|
+
object.isolationLevel = options.enums === String ? "ISOLATION_LEVEL_UNSPECIFIED" : 0;
|
|
83641
|
+
}
|
|
82361
83642
|
if (message.readWrite != null && message.hasOwnProperty("readWrite")) {
|
|
82362
83643
|
object.readWrite = $root.google.spanner.v1.TransactionOptions.ReadWrite.toObject(message.readWrite, options);
|
|
82363
83644
|
if (options.oneofs)
|
|
@@ -82375,6 +83656,8 @@
|
|
|
82375
83656
|
}
|
|
82376
83657
|
if (message.excludeTxnFromChangeStreams != null && message.hasOwnProperty("excludeTxnFromChangeStreams"))
|
|
82377
83658
|
object.excludeTxnFromChangeStreams = message.excludeTxnFromChangeStreams;
|
|
83659
|
+
if (message.isolationLevel != null && message.hasOwnProperty("isolationLevel"))
|
|
83660
|
+
object.isolationLevel = options.enums === String ? $root.google.spanner.v1.TransactionOptions.IsolationLevel[message.isolationLevel] === undefined ? message.isolationLevel : $root.google.spanner.v1.TransactionOptions.IsolationLevel[message.isolationLevel] : message.isolationLevel;
|
|
82378
83661
|
return object;
|
|
82379
83662
|
};
|
|
82380
83663
|
|
|
@@ -83240,6 +84523,22 @@
|
|
|
83240
84523
|
return ReadOnly;
|
|
83241
84524
|
})();
|
|
83242
84525
|
|
|
84526
|
+
/**
|
|
84527
|
+
* IsolationLevel enum.
|
|
84528
|
+
* @name google.spanner.v1.TransactionOptions.IsolationLevel
|
|
84529
|
+
* @enum {number}
|
|
84530
|
+
* @property {number} ISOLATION_LEVEL_UNSPECIFIED=0 ISOLATION_LEVEL_UNSPECIFIED value
|
|
84531
|
+
* @property {number} SERIALIZABLE=1 SERIALIZABLE value
|
|
84532
|
+
* @property {number} REPEATABLE_READ=2 REPEATABLE_READ value
|
|
84533
|
+
*/
|
|
84534
|
+
TransactionOptions.IsolationLevel = (function() {
|
|
84535
|
+
var valuesById = {}, values = Object.create(valuesById);
|
|
84536
|
+
values[valuesById[0] = "ISOLATION_LEVEL_UNSPECIFIED"] = 0;
|
|
84537
|
+
values[valuesById[1] = "SERIALIZABLE"] = 1;
|
|
84538
|
+
values[valuesById[2] = "REPEATABLE_READ"] = 2;
|
|
84539
|
+
return values;
|
|
84540
|
+
})();
|
|
84541
|
+
|
|
83243
84542
|
return TransactionOptions;
|
|
83244
84543
|
})();
|
|
83245
84544
|
|