Class RecipientRequest
-
- All Implemented Interfaces:
public final class RecipientRequestSpecifies a recipient in a request. This can either be a user identifier (string), an inline user request (object), or an inline object request, which is determined by the presence of a
collectionproperty.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public interfaceRecipientRequest.VisitorAn interface that defines how to map each variant of RecipientRequest to a value of type T.
-
Method Summary
Modifier and Type Method Description final Optional<String>userRecipient()The ID of the user which is used as the reference for the recipient. final Optional<InlineIdentifyUserRequest>inlineIdentifyUser()A set of parameters to inline-identify a user with. final Optional<InlineObjectRequest>inlineObject()A custom /concepts/objects entity which belongs to a collection. final BooleanisUserRecipient()final BooleanisInlineIdentifyUser()final BooleanisInlineObject()final StringasUserRecipient()The ID of the user which is used as the reference for the recipient. final InlineIdentifyUserRequestasInlineIdentifyUser()A set of parameters to inline-identify a user with. final InlineObjectRequestasInlineObject()A custom /concepts/objects entity which belongs to a collection. final Optional<JsonValue>_json()final <T extends Any> Taccept(RecipientRequest.Visitor<T> visitor)final RecipientRequestvalidate()final BooleanisValid()Booleanequals(Object other)IntegerhashCode()StringtoString()final static RecipientRequestofUserRecipient(String userRecipient)The ID of the user which is used as the reference for the recipient. final static RecipientRequestofInlineIdentifyUser(InlineIdentifyUserRequest inlineIdentifyUser)A set of parameters to inline-identify a user with. final static RecipientRequestofInlineObject(InlineObjectRequest inlineObject)A custom /concepts/objects entity which belongs to a collection. -
-
Method Detail
-
userRecipient
final Optional<String> userRecipient()
The ID of the user which is used as the reference for the recipient.
-
inlineIdentifyUser
final Optional<InlineIdentifyUserRequest> inlineIdentifyUser()
A set of parameters to inline-identify a user with. Inline identifying the user will ensure that the user is available before the request is executed in Knock. It will perform an upsert for the user you're supplying, replacing any properties specified.
-
inlineObject
final Optional<InlineObjectRequest> inlineObject()
A custom /concepts/objects entity which belongs to a collection.
-
isUserRecipient
final Boolean isUserRecipient()
-
isInlineIdentifyUser
final Boolean isInlineIdentifyUser()
-
isInlineObject
final Boolean isInlineObject()
-
asUserRecipient
final String asUserRecipient()
The ID of the user which is used as the reference for the recipient.
-
asInlineIdentifyUser
final InlineIdentifyUserRequest asInlineIdentifyUser()
A set of parameters to inline-identify a user with. Inline identifying the user will ensure that the user is available before the request is executed in Knock. It will perform an upsert for the user you're supplying, replacing any properties specified.
-
asInlineObject
final InlineObjectRequest asInlineObject()
A custom /concepts/objects entity which belongs to a collection.
-
accept
final <T extends Any> T accept(RecipientRequest.Visitor<T> visitor)
-
validate
final RecipientRequest validate()
-
ofUserRecipient
final static RecipientRequest ofUserRecipient(String userRecipient)
The ID of the user which is used as the reference for the recipient.
-
ofInlineIdentifyUser
final static RecipientRequest ofInlineIdentifyUser(InlineIdentifyUserRequest inlineIdentifyUser)
A set of parameters to inline-identify a user with. Inline identifying the user will ensure that the user is available before the request is executed in Knock. It will perform an upsert for the user you're supplying, replacing any properties specified.
-
ofInlineObject
final static RecipientRequest ofInlineObject(InlineObjectRequest inlineObject)
A custom /concepts/objects entity which belongs to a collection.
-
-
-
-