Class Rule.Builder (0.28.0)

public static final class Rule.Builder extends GeneratedMessageV3.Builder<Rule.Builder> implements RuleOrBuilder

Represents the rule for a content warehouse trigger.

Protobuf type google.cloud.contentwarehouse.v1.Rule

Implements

RuleOrBuilder

Static Methods

getDescriptor()

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

Methods

addActions(Action value)

public Rule.Builder addActions(Action value)

List of actions that are executed when the rule is satisfied.

repeated .google.cloud.contentwarehouse.v1.Action actions = 5;

Parameter
NameDescription
valueAction
Returns
TypeDescription
Rule.Builder

addActions(Action.Builder builderForValue)

public Rule.Builder addActions(Action.Builder builderForValue)

List of actions that are executed when the rule is satisfied.

repeated .google.cloud.contentwarehouse.v1.Action actions = 5;

Parameter
NameDescription
builderForValueAction.Builder
Returns
TypeDescription
Rule.Builder

addActions(int index, Action value)

public Rule.Builder addActions(int index, Action value)

List of actions that are executed when the rule is satisfied.

repeated .google.cloud.contentwarehouse.v1.Action actions = 5;

Parameters
NameDescription
indexint
valueAction
Returns
TypeDescription
Rule.Builder

addActions(int index, Action.Builder builderForValue)

public Rule.Builder addActions(int index, Action.Builder builderForValue)

List of actions that are executed when the rule is satisfied.

repeated .google.cloud.contentwarehouse.v1.Action actions = 5;

Parameters
NameDescription
indexint
builderForValueAction.Builder
Returns
TypeDescription
Rule.Builder

addActionsBuilder()

public Action.Builder addActionsBuilder()

List of actions that are executed when the rule is satisfied.

repeated .google.cloud.contentwarehouse.v1.Action actions = 5;

Returns
TypeDescription
Action.Builder

addActionsBuilder(int index)

public Action.Builder addActionsBuilder(int index)

List of actions that are executed when the rule is satisfied.

repeated .google.cloud.contentwarehouse.v1.Action actions = 5;

Parameter
NameDescription
indexint
Returns
TypeDescription
Action.Builder

addAllActions(Iterable<? extends Action> values)

public Rule.Builder addAllActions(Iterable<? extends Action> values)

List of actions that are executed when the rule is satisfied.

repeated .google.cloud.contentwarehouse.v1.Action actions = 5;

Parameter
NameDescription
valuesIterable<? extends com.google.cloud.contentwarehouse.v1.Action>
Returns
TypeDescription
Rule.Builder

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public Rule.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
Rule.Builder
Overrides

build()

public Rule build()
Returns
TypeDescription
Rule

buildPartial()

public Rule buildPartial()
Returns
TypeDescription
Rule

clear()

public Rule.Builder clear()
Returns
TypeDescription
Rule.Builder
Overrides

clearActions()

public Rule.Builder clearActions()

List of actions that are executed when the rule is satisfied.

repeated .google.cloud.contentwarehouse.v1.Action actions = 5;

Returns
TypeDescription
Rule.Builder

clearCondition()

public Rule.Builder clearCondition()

Represents the conditional expression to be evaluated. Expression should evaluate to a boolean result. When the condition is true actions are executed. Example: user_role = "hsbc_role_1" AND doc.salary > 20000

string condition = 4;

Returns
TypeDescription
Rule.Builder

This builder for chaining.

clearDescription()

public Rule.Builder clearDescription()

Short description of the rule and its context.

string description = 1;

Returns
TypeDescription
Rule.Builder

This builder for chaining.

clearField(Descriptors.FieldDescriptor field)

public Rule.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
NameDescription
fieldFieldDescriptor
Returns
TypeDescription
Rule.Builder
Overrides

clearOneof(Descriptors.OneofDescriptor oneof)

public Rule.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
NameDescription
oneofOneofDescriptor
Returns
TypeDescription
Rule.Builder
Overrides

clearRuleId()

public Rule.Builder clearRuleId()

ID of the rule. It has to be unique across all the examples. This is managed internally.

string rule_id = 2;

Returns
TypeDescription
Rule.Builder

This builder for chaining.

clearTriggerType()

public Rule.Builder clearTriggerType()

Identifies the trigger type for running the policy.

.google.cloud.contentwarehouse.v1.Rule.TriggerType trigger_type = 3;

Returns
TypeDescription
Rule.Builder

This builder for chaining.

clone()

public Rule.Builder clone()
Returns
TypeDescription
Rule.Builder
Overrides

getActions(int index)

public Action getActions(int index)

List of actions that are executed when the rule is satisfied.

repeated .google.cloud.contentwarehouse.v1.Action actions = 5;

Parameter
NameDescription
indexint
Returns
TypeDescription
Action

getActionsBuilder(int index)

public Action.Builder getActionsBuilder(int index)

List of actions that are executed when the rule is satisfied.

repeated .google.cloud.contentwarehouse.v1.Action actions = 5;

Parameter
NameDescription
indexint
Returns
TypeDescription
Action.Builder

getActionsBuilderList()

public List<Action.Builder> getActionsBuilderList()

List of actions that are executed when the rule is satisfied.

repeated .google.cloud.contentwarehouse.v1.Action actions = 5;

Returns
TypeDescription
List<Builder>

getActionsCount()

public int getActionsCount()

List of actions that are executed when the rule is satisfied.

repeated .google.cloud.contentwarehouse.v1.Action actions = 5;

Returns
TypeDescription
int

getActionsList()

public List<Action> getActionsList()

List of actions that are executed when the rule is satisfied.

repeated .google.cloud.contentwarehouse.v1.Action actions = 5;

Returns
TypeDescription
List<Action>

getActionsOrBuilder(int index)

public ActionOrBuilder getActionsOrBuilder(int index)

List of actions that are executed when the rule is satisfied.

repeated .google.cloud.contentwarehouse.v1.Action actions = 5;

Parameter
NameDescription
indexint
Returns
TypeDescription
ActionOrBuilder

getActionsOrBuilderList()

public List<? extends ActionOrBuilder> getActionsOrBuilderList()

List of actions that are executed when the rule is satisfied.

repeated .google.cloud.contentwarehouse.v1.Action actions = 5;

Returns
TypeDescription
List<? extends com.google.cloud.contentwarehouse.v1.ActionOrBuilder>

getCondition()

public String getCondition()

Represents the conditional expression to be evaluated. Expression should evaluate to a boolean result. When the condition is true actions are executed. Example: user_role = "hsbc_role_1" AND doc.salary > 20000

string condition = 4;

Returns
TypeDescription
String

The condition.

getConditionBytes()

public ByteString getConditionBytes()

Represents the conditional expression to be evaluated. Expression should evaluate to a boolean result. When the condition is true actions are executed. Example: user_role = "hsbc_role_1" AND doc.salary > 20000

string condition = 4;

Returns
TypeDescription
ByteString

The bytes for condition.

getDefaultInstanceForType()

public Rule getDefaultInstanceForType()
Returns
TypeDescription
Rule

getDescription()

public String getDescription()

Short description of the rule and its context.

string description = 1;

Returns
TypeDescription
String

The description.

getDescriptionBytes()

public ByteString getDescriptionBytes()

Short description of the rule and its context.

string description = 1;

Returns
TypeDescription
ByteString

The bytes for description.

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getRuleId()

public String getRuleId()

ID of the rule. It has to be unique across all the examples. This is managed internally.

string rule_id = 2;

Returns
TypeDescription
String

The ruleId.

getRuleIdBytes()

public ByteString getRuleIdBytes()

ID of the rule. It has to be unique across all the examples. This is managed internally.

string rule_id = 2;

Returns
TypeDescription
ByteString

The bytes for ruleId.

getTriggerType()

public Rule.TriggerType getTriggerType()

Identifies the trigger type for running the policy.

.google.cloud.contentwarehouse.v1.Rule.TriggerType trigger_type = 3;

Returns
TypeDescription
Rule.TriggerType

The triggerType.

getTriggerTypeValue()

public int getTriggerTypeValue()

Identifies the trigger type for running the policy.

.google.cloud.contentwarehouse.v1.Rule.TriggerType trigger_type = 3;

Returns
TypeDescription
int

The enum numeric value on the wire for triggerType.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeFrom(Rule other)

public Rule.Builder mergeFrom(Rule other)
Parameter
NameDescription
otherRule
Returns
TypeDescription
Rule.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public Rule.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
Rule.Builder
Overrides
Exceptions
TypeDescription
IOException

mergeFrom(Message other)

public Rule.Builder mergeFrom(Message other)
Parameter
NameDescription
otherMessage
Returns
TypeDescription
Rule.Builder
Overrides

mergeUnknownFields(UnknownFieldSet unknownFields)

public final Rule.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
Rule.Builder
Overrides

removeActions(int index)

public Rule.Builder removeActions(int index)

List of actions that are executed when the rule is satisfied.

repeated .google.cloud.contentwarehouse.v1.Action actions = 5;

Parameter
NameDescription
indexint
Returns
TypeDescription
Rule.Builder

setActions(int index, Action value)

public Rule.Builder setActions(int index, Action value)

List of actions that are executed when the rule is satisfied.

repeated .google.cloud.contentwarehouse.v1.Action actions = 5;

Parameters
NameDescription
indexint
valueAction
Returns
TypeDescription
Rule.Builder

setActions(int index, Action.Builder builderForValue)

public Rule.Builder setActions(int index, Action.Builder builderForValue)

List of actions that are executed when the rule is satisfied.

repeated .google.cloud.contentwarehouse.v1.Action actions = 5;

Parameters
NameDescription
indexint
builderForValueAction.Builder
Returns
TypeDescription
Rule.Builder

setCondition(String value)

public Rule.Builder setCondition(String value)

Represents the conditional expression to be evaluated. Expression should evaluate to a boolean result. When the condition is true actions are executed. Example: user_role = "hsbc_role_1" AND doc.salary > 20000

string condition = 4;

Parameter
NameDescription
valueString

The condition to set.

Returns
TypeDescription
Rule.Builder

This builder for chaining.

setConditionBytes(ByteString value)

public Rule.Builder setConditionBytes(ByteString value)

Represents the conditional expression to be evaluated. Expression should evaluate to a boolean result. When the condition is true actions are executed. Example: user_role = "hsbc_role_1" AND doc.salary > 20000

string condition = 4;

Parameter
NameDescription
valueByteString

The bytes for condition to set.

Returns
TypeDescription
Rule.Builder

This builder for chaining.

setDescription(String value)

public Rule.Builder setDescription(String value)

Short description of the rule and its context.

string description = 1;

Parameter
NameDescription
valueString

The description to set.

Returns
TypeDescription
Rule.Builder

This builder for chaining.

setDescriptionBytes(ByteString value)

public Rule.Builder setDescriptionBytes(ByteString value)

Short description of the rule and its context.

string description = 1;

Parameter
NameDescription
valueByteString

The bytes for description to set.

Returns
TypeDescription
Rule.Builder

This builder for chaining.

setField(Descriptors.FieldDescriptor field, Object value)

public Rule.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
Rule.Builder
Overrides

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

public Rule.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
NameDescription
fieldFieldDescriptor
indexint
valueObject
Returns
TypeDescription
Rule.Builder
Overrides

setRuleId(String value)

public Rule.Builder setRuleId(String value)

ID of the rule. It has to be unique across all the examples. This is managed internally.

string rule_id = 2;

Parameter
NameDescription
valueString

The ruleId to set.

Returns
TypeDescription
Rule.Builder

This builder for chaining.

setRuleIdBytes(ByteString value)

public Rule.Builder setRuleIdBytes(ByteString value)

ID of the rule. It has to be unique across all the examples. This is managed internally.

string rule_id = 2;

Parameter
NameDescription
valueByteString

The bytes for ruleId to set.

Returns
TypeDescription
Rule.Builder

This builder for chaining.

setTriggerType(Rule.TriggerType value)

public Rule.Builder setTriggerType(Rule.TriggerType value)

Identifies the trigger type for running the policy.

.google.cloud.contentwarehouse.v1.Rule.TriggerType trigger_type = 3;

Parameter
NameDescription
valueRule.TriggerType

The triggerType to set.

Returns
TypeDescription
Rule.Builder

This builder for chaining.

setTriggerTypeValue(int value)

public Rule.Builder setTriggerTypeValue(int value)

Identifies the trigger type for running the policy.

.google.cloud.contentwarehouse.v1.Rule.TriggerType trigger_type = 3;

Parameter
NameDescription
valueint

The enum numeric value on the wire for triggerType to set.

Returns
TypeDescription
Rule.Builder

This builder for chaining.

setUnknownFields(UnknownFieldSet unknownFields)

public final Rule.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
Rule.Builder
Overrides