Class protos.google.spanner.v1.BatchCreateSessionsRequest

Represents a BatchCreateSessionsRequest.

Package

@google-cloud/spanner!

Constructors

(constructor)(properties)

constructor(properties?: google.spanner.v1.IBatchCreateSessionsRequest);

Constructs a new BatchCreateSessionsRequest.

Parameter
TypeNameDescription
google.spanner.v1.IBatchCreateSessionsRequestproperties

Properties to set

Properties

database

public database: string;

BatchCreateSessionsRequest database.

Property Value
TypeDescription
string

sessionCount

public sessionCount: number;

BatchCreateSessionsRequest sessionCount.

Property Value
TypeDescription
number

sessionTemplate

public sessionTemplate?: (google.spanner.v1.ISession|null);

BatchCreateSessionsRequest sessionTemplate.

Property Value
TypeDescription
(google.spanner.v1.ISession|null)

Methods

create(properties)

public static create(properties?: google.spanner.v1.IBatchCreateSessionsRequest): google.spanner.v1.BatchCreateSessionsRequest;

Creates a new BatchCreateSessionsRequest instance using the specified properties.

Parameter
TypeNameDescription
google.spanner.v1.IBatchCreateSessionsRequestproperties

Properties to set

Returns
TypeDescription
google.spanner.v1.BatchCreateSessionsRequest

BatchCreateSessionsRequest instance

decode(reader, length)

public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.spanner.v1.BatchCreateSessionsRequest;

Decodes a BatchCreateSessionsRequest message from the specified reader or buffer.

Parameters
TypeNameDescription
($protobuf.Reader|Uint8Array)reader

Reader or buffer to decode from

numberlength

Message length if known beforehand

Returns
TypeDescription
google.spanner.v1.BatchCreateSessionsRequest

BatchCreateSessionsRequest

decodeDelimited(reader)

public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.spanner.v1.BatchCreateSessionsRequest;

Decodes a BatchCreateSessionsRequest message from the specified reader or buffer, length delimited.

Parameter
TypeNameDescription
($protobuf.Reader|Uint8Array)reader

Reader or buffer to decode from

Returns
TypeDescription
google.spanner.v1.BatchCreateSessionsRequest

BatchCreateSessionsRequest

encode(message, writer)

public static encode(message: google.spanner.v1.IBatchCreateSessionsRequest, writer?: $protobuf.Writer): $protobuf.Writer;

Encodes the specified BatchCreateSessionsRequest message. Does not implicitly messages.

Parameters
TypeNameDescription
google.spanner.v1.IBatchCreateSessionsRequestmessage

BatchCreateSessionsRequest message or plain object to encode

$protobuf.Writerwriter

Writer to encode to

Returns
TypeDescription
$protobuf.Writer

Writer

encodeDelimited(message, writer)

public static encodeDelimited(message: google.spanner.v1.IBatchCreateSessionsRequest, writer?: $protobuf.Writer): $protobuf.Writer;

Encodes the specified BatchCreateSessionsRequest message, length delimited. Does not implicitly messages.

Parameters
TypeNameDescription
google.spanner.v1.IBatchCreateSessionsRequestmessage

BatchCreateSessionsRequest message or plain object to encode

$protobuf.Writerwriter

Writer to encode to

Returns
TypeDescription
$protobuf.Writer

Writer

fromObject(object)

public static fromObject(object: { [k: string]: any }): google.spanner.v1.BatchCreateSessionsRequest;

Creates a BatchCreateSessionsRequest message from a plain object. Also converts values to their respective internal types.

Parameter
TypeNameDescription
{ [k: string]: any }object

Plain object

Returns
TypeDescription
google.spanner.v1.BatchCreateSessionsRequest

BatchCreateSessionsRequest

toJSON()

public toJSON(): { [k: string]: any };

Converts this BatchCreateSessionsRequest to JSON.

Returns
TypeDescription
{ [k: string]: any }

JSON object

toObject(message, options)

public static toObject(message: google.spanner.v1.BatchCreateSessionsRequest, options?: $protobuf.IConversionOptions): { [k: string]: any };

Creates a plain object from a BatchCreateSessionsRequest message. Also converts values to other types if specified.

Parameters
TypeNameDescription
google.spanner.v1.BatchCreateSessionsRequestmessage

BatchCreateSessionsRequest

$protobuf.IConversionOptionsoptions

Conversion options

Returns
TypeDescription
{ [k: string]: any }

Plain object

verify(message)

public static verify(message: { [k: string]: any }): (string|null);

Verifies a BatchCreateSessionsRequest message.

Parameter
TypeNameDescription
{ [k: string]: any }message

Plain object to verify

Returns
TypeDescription
(string|null)

null if valid, otherwise the reason why it is not