Interface TokensInfoOrBuilder (3.56.0)

public interface TokensInfoOrBuilder extends MessageOrBuilder

Implements

MessageOrBuilder

Methods

getRole()

public abstract String getRole()

Optional. Optional fields for the role from the corresponding Content.

string role = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
String

The role.

getRoleBytes()

public abstract ByteString getRoleBytes()

Optional. Optional fields for the role from the corresponding Content.

string role = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
ByteString

The bytes for role.

getTokenIds(int index)

public abstract long getTokenIds(int index)

A list of token ids from the input.

repeated int64 token_ids = 2;

Parameter
Name Description
index int

The index of the element to return.

Returns
Type Description
long

The tokenIds at the given index.

getTokenIdsCount()

public abstract int getTokenIdsCount()

A list of token ids from the input.

repeated int64 token_ids = 2;

Returns
Type Description
int

The count of tokenIds.

getTokenIdsList()

public abstract List<Long> getTokenIdsList()

A list of token ids from the input.

repeated int64 token_ids = 2;

Returns
Type Description
List<Long>

A list containing the tokenIds.

getTokens(int index)

public abstract ByteString getTokens(int index)

A list of tokens from the input.

repeated bytes tokens = 1;

Parameter
Name Description
index int

The index of the element to return.

Returns
Type Description
ByteString

The tokens at the given index.

getTokensCount()

public abstract int getTokensCount()

A list of tokens from the input.

repeated bytes tokens = 1;

Returns
Type Description
int

The count of tokens.

getTokensList()

public abstract List<ByteString> getTokensList()

A list of tokens from the input.

repeated bytes tokens = 1;

Returns
Type Description
List<ByteString>

A list containing the tokens.