@InterfaceAudience.Private @InterfaceStability.Unstable public class EmailActionBuilder extends NodeBuilderBaseImpl<EmailActionBuilder> implements Builder<EmailAction>
EmailAction.
The properties of the builder can only be set once, an attempt to set them a second time will trigger
an IllegalStateException. The properties that are lists are an exception to this rule, of course multiple
elements can be added / removed.
Builder instances can be used to build several elements, although properties already set cannot be changed after
a call to build() either.
| Modifier and Type | Method and Description |
|---|---|
EmailAction |
build()
Creates a new
EmailAction object with the properties stores in this builder. |
static EmailActionBuilder |
create()
Creates and returns an empty builder.
|
static EmailActionBuilder |
createFromExistingAction(EmailAction action)
Create and return a new
EmailActionBuilder that is based on an already built
EmailAction object. |
static EmailActionBuilder |
createFromExistingAction(Node action) |
protected EmailActionBuilder |
getRuntimeSelfReference() |
EmailActionBuilder |
withAttachment(String attachment)
Sets the attachment of the email.
|
EmailActionBuilder |
withBcc(String bcc)
Sets the address of the secret recipient of a copy of the email.
|
EmailActionBuilder |
withBody(String body)
Sets the body of the email.
|
EmailActionBuilder |
withCc(String cc)
Sets the address of the recipient of a copy of the email.
|
EmailActionBuilder |
withContentType(String contentType)
Sets the content type of the email.
|
EmailActionBuilder |
withRecipient(String to)
Sets the address of the recipient of the email.
|
EmailActionBuilder |
withSubject(String subject)
Sets the subject of the email.
|
addAsChildToAllParents, clearCredentials, clearParents, withCredential, withErrorHandler, withName, withoutCredential, withoutErrorHandler, withoutParent, withParent, withParentDefaultConditional, withParentWithCondition, withRetryInterval, withRetryMax, withRetryPolicypublic static EmailActionBuilder create()
public static EmailActionBuilder createFromExistingAction(EmailAction action)
EmailActionBuilder that is based on an already built
EmailAction object. The properties of the builder will initially be the same as those of the
provided EmailAction object, but it is possible to modify them once.action - The EmailAction object on which this EmailActionBuilder will be based.EmailActionBuilder that is based on a previously built EmailAction object.public static EmailActionBuilder createFromExistingAction(Node action)
public EmailActionBuilder withRecipient(String to)
to - the recipient in To: fieldpublic EmailActionBuilder withCc(String cc)
cc - the recipient in CC: fieldpublic EmailActionBuilder withBcc(String bcc)
bcc - the recipient in BCC: fieldpublic EmailActionBuilder withSubject(String subject)
subject - the email subjectpublic EmailActionBuilder withBody(String body)
body - the email bodypublic EmailActionBuilder withContentType(String contentType)
contentType - the email content typepublic EmailActionBuilder withAttachment(String attachment)
attachment - the email attachment pathpublic EmailAction build()
EmailAction object with the properties stores in this builder.
The new EmailAction object is independent of this builder and the builder can be used to build
new instances.build in interface Builder<EmailAction>EmailAction object with the properties stored in this builder.protected EmailActionBuilder getRuntimeSelfReference()
getRuntimeSelfReference in class NodeBuilderBaseImpl<EmailActionBuilder>Copyright © 2021 Apache Software Foundation. All rights reserved.