Class Thread (0.3.0)

public final class Thread extends GeneratedMessageV3 implements ThreadOrBuilder

A thread in a Google Chat space. For example usage, see Start or reply to a message thread.

If you specify a thread when creating a message, you can set the messageReplyOption field to determine what happens if no matching thread is found.

Protobuf type google.chat.v1.Thread

Implements

ThreadOrBuilder

Static Fields

NAME_FIELD_NUMBER

public static final int NAME_FIELD_NUMBER
Field Value
TypeDescription
int

THREAD_KEY_FIELD_NUMBER

public static final int THREAD_KEY_FIELD_NUMBER
Field Value
TypeDescription
int

Static Methods

getDefaultInstance()

public static Thread getDefaultInstance()
Returns
TypeDescription
Thread

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
TypeDescription
Descriptor

newBuilder()

public static Thread.Builder newBuilder()
Returns
TypeDescription
Thread.Builder

newBuilder(Thread prototype)

public static Thread.Builder newBuilder(Thread prototype)
Parameter
NameDescription
prototypeThread
Returns
TypeDescription
Thread.Builder

parseDelimitedFrom(InputStream input)

public static Thread parseDelimitedFrom(InputStream input)
Parameter
NameDescription
inputInputStream
Returns
TypeDescription
Thread
Exceptions
TypeDescription
IOException

parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static Thread parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
Thread
Exceptions
TypeDescription
IOException

parseFrom(byte[] data)

public static Thread parseFrom(byte[] data)
Parameter
NameDescription
databyte[]
Returns
TypeDescription
Thread
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)

public static Thread parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
databyte[]
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
Thread
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteString data)

public static Thread parseFrom(ByteString data)
Parameter
NameDescription
dataByteString
Returns
TypeDescription
Thread
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)

public static Thread parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
dataByteString
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
Thread
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(CodedInputStream input)

public static Thread parseFrom(CodedInputStream input)
Parameter
NameDescription
inputCodedInputStream
Returns
TypeDescription
Thread
Exceptions
TypeDescription
IOException

parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public static Thread parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
Thread
Exceptions
TypeDescription
IOException

parseFrom(InputStream input)

public static Thread parseFrom(InputStream input)
Parameter
NameDescription
inputInputStream
Returns
TypeDescription
Thread
Exceptions
TypeDescription
IOException

parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static Thread parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
Thread
Exceptions
TypeDescription
IOException

parseFrom(ByteBuffer data)

public static Thread parseFrom(ByteBuffer data)
Parameter
NameDescription
dataByteBuffer
Returns
TypeDescription
Thread
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)

public static Thread parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
dataByteBuffer
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
Thread
Exceptions
TypeDescription
InvalidProtocolBufferException

parser()

public static Parser<Thread> parser()
Returns
TypeDescription
Parser<Thread>

Methods

equals(Object obj)

public boolean equals(Object obj)
Parameter
NameDescription
objObject
Returns
TypeDescription
boolean
Overrides

getDefaultInstanceForType()

public Thread getDefaultInstanceForType()
Returns
TypeDescription
Thread

getName()

public String getName()

Output only. Resource name of the thread.

Example: spaces/{space}/threads/{thread}

string name = 1;

Returns
TypeDescription
String

The name.

getNameBytes()

public ByteString getNameBytes()

Output only. Resource name of the thread.

Example: spaces/{space}/threads/{thread}

string name = 1;

Returns
TypeDescription
ByteString

The bytes for name.

getParserForType()

public Parser<Thread> getParserForType()
Returns
TypeDescription
Parser<Thread>
Overrides

getSerializedSize()

public int getSerializedSize()
Returns
TypeDescription
int
Overrides

getThreadKey()

public String getThreadKey()

Optional. Input for creating or updating a thread. Otherwise, output only. ID for the thread. Supports up to 4000 characters.

This ID is unique to the Chat app that sets it. For example, if multiple Chat apps create a message using the same thread key, the messages are posted in different threads. To reply in a thread created by a person or another Chat app, specify the thread name field instead.

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

Returns
TypeDescription
String

The threadKey.

getThreadKeyBytes()

public ByteString getThreadKeyBytes()

Optional. Input for creating or updating a thread. Otherwise, output only. ID for the thread. Supports up to 4000 characters.

This ID is unique to the Chat app that sets it. For example, if multiple Chat apps create a message using the same thread key, the messages are posted in different threads. To reply in a thread created by a person or another Chat app, specify the thread name field instead.

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

Returns
TypeDescription
ByteString

The bytes for threadKey.

hashCode()

public int hashCode()
Returns
TypeDescription
int
Overrides

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

newBuilderForType()

public Thread.Builder newBuilderForType()
Returns
TypeDescription
Thread.Builder

newBuilderForType(GeneratedMessageV3.BuilderParent parent)

protected Thread.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Parameter
NameDescription
parentBuilderParent
Returns
TypeDescription
Thread.Builder
Overrides

newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)

protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Parameter
NameDescription
unusedUnusedPrivateParameter
Returns
TypeDescription
Object
Overrides

toBuilder()

public Thread.Builder toBuilder()
Returns
TypeDescription
Thread.Builder

writeTo(CodedOutputStream output)

public void writeTo(CodedOutputStream output)
Parameter
NameDescription
outputCodedOutputStream
Overrides
Exceptions
TypeDescription
IOException