Class ContextualTrigger.Builder (2.48.0)

public static final class ContextualTrigger.Builder extends GeneratedMessageV3.Builder<ContextualTrigger.Builder> implements ContextualTriggerOrBuilder

Defines a trigger that fires when the open email meets a specific criteria. When the trigger fires, it executes a specific endpoint, usually in order to create new cards and update the UI.

Protobuf type google.apps.script.type.gmail.ContextualTrigger

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
Type Description
Descriptor

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public ContextualTrigger.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
ContextualTrigger.Builder
Overrides

build()

public ContextualTrigger build()
Returns
Type Description
ContextualTrigger

buildPartial()

public ContextualTrigger buildPartial()
Returns
Type Description
ContextualTrigger

clear()

public ContextualTrigger.Builder clear()
Returns
Type Description
ContextualTrigger.Builder
Overrides

clearField(Descriptors.FieldDescriptor field)

public ContextualTrigger.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Name Description
field FieldDescriptor
Returns
Type Description
ContextualTrigger.Builder
Overrides

clearOnTriggerFunction()

public ContextualTrigger.Builder clearOnTriggerFunction()

Required. The name of the endpoint to call when a message matches the trigger.

string on_trigger_function = 4;

Returns
Type Description
ContextualTrigger.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

public ContextualTrigger.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Name Description
oneof OneofDescriptor
Returns
Type Description
ContextualTrigger.Builder
Overrides

clearTrigger()

public ContextualTrigger.Builder clearTrigger()
Returns
Type Description
ContextualTrigger.Builder

clearUnconditional()

public ContextualTrigger.Builder clearUnconditional()

UnconditionalTriggers are executed when any mail message is opened.

.google.apps.script.type.gmail.UnconditionalTrigger unconditional = 1;

Returns
Type Description
ContextualTrigger.Builder

clone()

public ContextualTrigger.Builder clone()
Returns
Type Description
ContextualTrigger.Builder
Overrides

getDefaultInstanceForType()

public ContextualTrigger getDefaultInstanceForType()
Returns
Type Description
ContextualTrigger

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
Type Description
Descriptor
Overrides

getOnTriggerFunction()

public String getOnTriggerFunction()

Required. The name of the endpoint to call when a message matches the trigger.

string on_trigger_function = 4;

Returns
Type Description
String

The onTriggerFunction.

getOnTriggerFunctionBytes()

public ByteString getOnTriggerFunctionBytes()

Required. The name of the endpoint to call when a message matches the trigger.

string on_trigger_function = 4;

Returns
Type Description
ByteString

The bytes for onTriggerFunction.

getTriggerCase()

public ContextualTrigger.TriggerCase getTriggerCase()
Returns
Type Description
ContextualTrigger.TriggerCase

getUnconditional()

public UnconditionalTrigger getUnconditional()

UnconditionalTriggers are executed when any mail message is opened.

.google.apps.script.type.gmail.UnconditionalTrigger unconditional = 1;

Returns
Type Description
UnconditionalTrigger

The unconditional.

getUnconditionalBuilder()

public UnconditionalTrigger.Builder getUnconditionalBuilder()

UnconditionalTriggers are executed when any mail message is opened.

.google.apps.script.type.gmail.UnconditionalTrigger unconditional = 1;

Returns
Type Description
UnconditionalTrigger.Builder

getUnconditionalOrBuilder()

public UnconditionalTriggerOrBuilder getUnconditionalOrBuilder()

UnconditionalTriggers are executed when any mail message is opened.

.google.apps.script.type.gmail.UnconditionalTrigger unconditional = 1;

Returns
Type Description
UnconditionalTriggerOrBuilder

hasUnconditional()

public boolean hasUnconditional()

UnconditionalTriggers are executed when any mail message is opened.

.google.apps.script.type.gmail.UnconditionalTrigger unconditional = 1;

Returns
Type Description
boolean

Whether the unconditional field is set.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Type Description
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(ContextualTrigger other)

public ContextualTrigger.Builder mergeFrom(ContextualTrigger other)
Parameter
Name Description
other ContextualTrigger
Returns
Type Description
ContextualTrigger.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public ContextualTrigger.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
ContextualTrigger.Builder
Overrides
Exceptions
Type Description
IOException

mergeFrom(Message other)

public ContextualTrigger.Builder mergeFrom(Message other)
Parameter
Name Description
other Message
Returns
Type Description
ContextualTrigger.Builder
Overrides

mergeUnconditional(UnconditionalTrigger value)

public ContextualTrigger.Builder mergeUnconditional(UnconditionalTrigger value)

UnconditionalTriggers are executed when any mail message is opened.

.google.apps.script.type.gmail.UnconditionalTrigger unconditional = 1;

Parameter
Name Description
value UnconditionalTrigger
Returns
Type Description
ContextualTrigger.Builder

mergeUnknownFields(UnknownFieldSet unknownFields)

public final ContextualTrigger.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
ContextualTrigger.Builder
Overrides

setField(Descriptors.FieldDescriptor field, Object value)

public ContextualTrigger.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
ContextualTrigger.Builder
Overrides

setOnTriggerFunction(String value)

public ContextualTrigger.Builder setOnTriggerFunction(String value)

Required. The name of the endpoint to call when a message matches the trigger.

string on_trigger_function = 4;

Parameter
Name Description
value String

The onTriggerFunction to set.

Returns
Type Description
ContextualTrigger.Builder

This builder for chaining.

setOnTriggerFunctionBytes(ByteString value)

public ContextualTrigger.Builder setOnTriggerFunctionBytes(ByteString value)

Required. The name of the endpoint to call when a message matches the trigger.

string on_trigger_function = 4;

Parameter
Name Description
value ByteString

The bytes for onTriggerFunction to set.

Returns
Type Description
ContextualTrigger.Builder

This builder for chaining.

setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)

public ContextualTrigger.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Name Description
field FieldDescriptor
index int
value Object
Returns
Type Description
ContextualTrigger.Builder
Overrides

setUnconditional(UnconditionalTrigger value)

public ContextualTrigger.Builder setUnconditional(UnconditionalTrigger value)

UnconditionalTriggers are executed when any mail message is opened.

.google.apps.script.type.gmail.UnconditionalTrigger unconditional = 1;

Parameter
Name Description
value UnconditionalTrigger
Returns
Type Description
ContextualTrigger.Builder

setUnconditional(UnconditionalTrigger.Builder builderForValue)

public ContextualTrigger.Builder setUnconditional(UnconditionalTrigger.Builder builderForValue)

UnconditionalTriggers are executed when any mail message is opened.

.google.apps.script.type.gmail.UnconditionalTrigger unconditional = 1;

Parameter
Name Description
builderForValue UnconditionalTrigger.Builder
Returns
Type Description
ContextualTrigger.Builder

setUnknownFields(UnknownFieldSet unknownFields)

public final ContextualTrigger.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
ContextualTrigger.Builder
Overrides