Class MessageEvent.Builder
-
- All Implemented Interfaces:
public final class MessageEvent.BuilderA builder for MessageEvent.
-
-
Method Summary
Modifier and Type Method Description final MessageEvent.Builderid(String id)The unique identifier for the message event. final MessageEvent.Builderid(JsonField<String> id)Sets Builder.id to an arbitrary JSON value. final MessageEvent.Builder_typename(String _typename)The typename of the schema. final MessageEvent.Builder_typename(JsonField<String> _typename)Sets Builder._typename to an arbitrary JSON value. final MessageEvent.BuilderinsertedAt(OffsetDateTime insertedAt)Timestamp when the event was created. final MessageEvent.BuilderinsertedAt(JsonField<OffsetDateTime> insertedAt)Sets Builder.insertedAt to an arbitrary JSON value. final MessageEvent.Builderrecipient(RecipientReference recipient)A reference to a recipient, either a user identifier (string) or an object reference (ID, collection). final MessageEvent.Builderrecipient(JsonField<RecipientReference> recipient)Sets Builder.recipient to an arbitrary JSON value. final MessageEvent.Builderrecipient(String user)Alias for calling recipient with RecipientReference.ofUser(user).final MessageEvent.Builderrecipient(RecipientReference.ObjectReference objectReference)Alias for calling recipient with RecipientReference.ofObjectReference(objectReference).final MessageEvent.Buildertype(MessageEvent.Type type)The type of event that occurred. final MessageEvent.Buildertype(JsonField<MessageEvent.Type> type)Sets Builder.type to an arbitrary JSON value. final MessageEvent.Builderdata(MessageEvent.Data data)The data associated with the message event. final MessageEvent.Builderdata(Optional<MessageEvent.Data> data)Alias for calling Builder.data with data.orElse(null).final MessageEvent.Builderdata(JsonField<MessageEvent.Data> data)Sets Builder.data to an arbitrary JSON value. final MessageEvent.BuilderadditionalProperties(Map<String, JsonValue> additionalProperties)final MessageEvent.BuilderputAdditionalProperty(String key, JsonValue value)final MessageEvent.BuilderputAllAdditionalProperties(Map<String, JsonValue> additionalProperties)final MessageEvent.BuilderremoveAdditionalProperty(String key)final MessageEvent.BuilderremoveAllAdditionalProperties(Set<String> keys)final MessageEventbuild()Returns an immutable instance of MessageEvent. -
-
Method Detail
-
id
final MessageEvent.Builder id(String id)
The unique identifier for the message event.
-
id
final MessageEvent.Builder id(JsonField<String> id)
Sets Builder.id to an arbitrary JSON value.
You should usually call Builder.id with a well-typed String value instead. This method is primarily for setting the field to an undocumented or not yet supported value.
-
_typename
final MessageEvent.Builder _typename(String _typename)
The typename of the schema.
-
_typename
final MessageEvent.Builder _typename(JsonField<String> _typename)
Sets Builder._typename to an arbitrary JSON value.
You should usually call Builder._typename with a well-typed String value instead. This method is primarily for setting the field to an undocumented or not yet supported value.
-
insertedAt
final MessageEvent.Builder insertedAt(OffsetDateTime insertedAt)
Timestamp when the event was created.
-
insertedAt
final MessageEvent.Builder insertedAt(JsonField<OffsetDateTime> insertedAt)
Sets Builder.insertedAt to an arbitrary JSON value.
You should usually call Builder.insertedAt with a well-typed OffsetDateTime value instead. This method is primarily for setting the field to an undocumented or not yet supported value.
-
recipient
final MessageEvent.Builder recipient(RecipientReference recipient)
A reference to a recipient, either a user identifier (string) or an object reference (ID, collection).
-
recipient
final MessageEvent.Builder recipient(JsonField<RecipientReference> recipient)
Sets Builder.recipient to an arbitrary JSON value.
You should usually call Builder.recipient with a well-typed RecipientReference value instead. This method is primarily for setting the field to an undocumented or not yet supported value.
-
recipient
final MessageEvent.Builder recipient(String user)
Alias for calling recipient with
RecipientReference.ofUser(user).
-
recipient
final MessageEvent.Builder recipient(RecipientReference.ObjectReference objectReference)
Alias for calling recipient with
RecipientReference.ofObjectReference(objectReference).
-
type
final MessageEvent.Builder type(MessageEvent.Type type)
The type of event that occurred.
-
type
final MessageEvent.Builder type(JsonField<MessageEvent.Type> type)
Sets Builder.type to an arbitrary JSON value.
You should usually call Builder.type with a well-typed Type value instead. This method is primarily for setting the field to an undocumented or not yet supported value.
-
data
final MessageEvent.Builder data(MessageEvent.Data data)
The data associated with the message event. Only present for some event types.
-
data
final MessageEvent.Builder data(Optional<MessageEvent.Data> data)
Alias for calling Builder.data with
data.orElse(null).
-
data
final MessageEvent.Builder data(JsonField<MessageEvent.Data> data)
Sets Builder.data to an arbitrary JSON value.
You should usually call Builder.data with a well-typed Data value instead. This method is primarily for setting the field to an undocumented or not yet supported value.
-
additionalProperties
final MessageEvent.Builder additionalProperties(Map<String, JsonValue> additionalProperties)
-
putAdditionalProperty
final MessageEvent.Builder putAdditionalProperty(String key, JsonValue value)
-
putAllAdditionalProperties
final MessageEvent.Builder putAllAdditionalProperties(Map<String, JsonValue> additionalProperties)
-
removeAdditionalProperty
final MessageEvent.Builder removeAdditionalProperty(String key)
-
removeAllAdditionalProperties
final MessageEvent.Builder removeAllAdditionalProperties(Set<String> keys)
-
build
final MessageEvent build()
Returns an immutable instance of MessageEvent.
Further updates to this Builder will not mutate the returned instance.
The following fields are required:
.id() ._typename() .insertedAt() .recipient() .type()
-
-
-
-