Class Function.Builder (3.35.1)

public static final class Function.Builder extends GeneratedMessageV3.Builder<Function.Builder> implements FunctionOrBuilder

Represents an unevaluated scalar expression.

For example, the expression like(user_name, "%alice%") is represented as:

<code><code> name: "like" args { field_reference: "user_name" } args { string_value: "%alice%" } </code></code>

Protobuf type google.firestore.v1.Function

Implements

FunctionOrBuilder

Static Methods

getDescriptor()

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

Methods

addAllArgs(Iterable<? extends Value> values)

public Function.Builder addAllArgs(Iterable<? extends Value> values)

Optional. Ordered list of arguments the given function expects.

repeated .google.firestore.v1.Value args = 2 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
values Iterable<? extends com.google.firestore.v1.Value>
Returns
Type Description
Function.Builder

addArgs(Value value)

public Function.Builder addArgs(Value value)

Optional. Ordered list of arguments the given function expects.

repeated .google.firestore.v1.Value args = 2 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value Value
Returns
Type Description
Function.Builder

addArgs(Value.Builder builderForValue)

public Function.Builder addArgs(Value.Builder builderForValue)

Optional. Ordered list of arguments the given function expects.

repeated .google.firestore.v1.Value args = 2 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
builderForValue Value.Builder
Returns
Type Description
Function.Builder

addArgs(int index, Value value)

public Function.Builder addArgs(int index, Value value)

Optional. Ordered list of arguments the given function expects.

repeated .google.firestore.v1.Value args = 2 [(.google.api.field_behavior) = OPTIONAL];

Parameters
Name Description
index int
value Value
Returns
Type Description
Function.Builder

addArgs(int index, Value.Builder builderForValue)

public Function.Builder addArgs(int index, Value.Builder builderForValue)

Optional. Ordered list of arguments the given function expects.

repeated .google.firestore.v1.Value args = 2 [(.google.api.field_behavior) = OPTIONAL];

Parameters
Name Description
index int
builderForValue Value.Builder
Returns
Type Description
Function.Builder

addArgsBuilder()

public Value.Builder addArgsBuilder()

Optional. Ordered list of arguments the given function expects.

repeated .google.firestore.v1.Value args = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
Value.Builder

addArgsBuilder(int index)

public Value.Builder addArgsBuilder(int index)

Optional. Ordered list of arguments the given function expects.

repeated .google.firestore.v1.Value args = 2 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
index int
Returns
Type Description
Value.Builder

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

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

build()

public Function build()
Returns
Type Description
Function

buildPartial()

public Function buildPartial()
Returns
Type Description
Function

clear()

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

clearArgs()

public Function.Builder clearArgs()

Optional. Ordered list of arguments the given function expects.

repeated .google.firestore.v1.Value args = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
Function.Builder

clearField(Descriptors.FieldDescriptor field)

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

clearName()

public Function.Builder clearName()

Required. The name of the function to evaluate.

Requires:

  • must be in snake case (lower case with underscore separator).

string name = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
Function.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

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

clearOptions()

public Function.Builder clearOptions()
Returns
Type Description
Function.Builder

clone()

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

containsOptions(String key)

public boolean containsOptions(String key)

Optional. Optional named arguments that certain functions may support.

map<string, .google.firestore.v1.Value> options = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
key String
Returns
Type Description
boolean

getArgs(int index)

public Value getArgs(int index)

Optional. Ordered list of arguments the given function expects.

repeated .google.firestore.v1.Value args = 2 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
index int
Returns
Type Description
Value

getArgsBuilder(int index)

public Value.Builder getArgsBuilder(int index)

Optional. Ordered list of arguments the given function expects.

repeated .google.firestore.v1.Value args = 2 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
index int
Returns
Type Description
Value.Builder

getArgsBuilderList()

public List<Value.Builder> getArgsBuilderList()

Optional. Ordered list of arguments the given function expects.

repeated .google.firestore.v1.Value args = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
List<Builder>

getArgsCount()

public int getArgsCount()

Optional. Ordered list of arguments the given function expects.

repeated .google.firestore.v1.Value args = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
int

getArgsList()

public List<Value> getArgsList()

Optional. Ordered list of arguments the given function expects.

repeated .google.firestore.v1.Value args = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
List<Value>

getArgsOrBuilder(int index)

public ValueOrBuilder getArgsOrBuilder(int index)

Optional. Ordered list of arguments the given function expects.

repeated .google.firestore.v1.Value args = 2 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
index int
Returns
Type Description
ValueOrBuilder

getArgsOrBuilderList()

public List<? extends ValueOrBuilder> getArgsOrBuilderList()

Optional. Ordered list of arguments the given function expects.

repeated .google.firestore.v1.Value args = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
List<? extends com.google.firestore.v1.ValueOrBuilder>

getDefaultInstanceForType()

public Function getDefaultInstanceForType()
Returns
Type Description
Function

getDescriptorForType()

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

getMutableOptions() (deprecated)

public Map<String,Value> getMutableOptions()

Use alternate mutation accessors instead.

Returns
Type Description
Map<String,Value>

getName()

public String getName()

Required. The name of the function to evaluate.

Requires:

  • must be in snake case (lower case with underscore separator).

string name = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
String

The name.

getNameBytes()

public ByteString getNameBytes()

Required. The name of the function to evaluate.

Requires:

  • must be in snake case (lower case with underscore separator).

string name = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
ByteString

The bytes for name.

getOptions() (deprecated)

public Map<String,Value> getOptions()

Use #getOptionsMap() instead.

Returns
Type Description
Map<String,Value>

getOptionsCount()

public int getOptionsCount()

Optional. Optional named arguments that certain functions may support.

map<string, .google.firestore.v1.Value> options = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
int

getOptionsMap()

public Map<String,Value> getOptionsMap()

Optional. Optional named arguments that certain functions may support.

map<string, .google.firestore.v1.Value> options = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
Map<String,Value>

getOptionsOrDefault(String key, Value defaultValue)

public Value getOptionsOrDefault(String key, Value defaultValue)

Optional. Optional named arguments that certain functions may support.

map<string, .google.firestore.v1.Value> options = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameters
Name Description
key String
defaultValue Value
Returns
Type Description
Value

getOptionsOrThrow(String key)

public Value getOptionsOrThrow(String key)

Optional. Optional named arguments that certain functions may support.

map<string, .google.firestore.v1.Value> options = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
key String
Returns
Type Description
Value

internalGetFieldAccessorTable()

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

internalGetMapFieldReflection(int number)

protected MapFieldReflectionAccessor internalGetMapFieldReflection(int number)
Parameter
Name Description
number int
Returns
Type Description
com.google.protobuf.MapFieldReflectionAccessor
Overrides
com.google.protobuf.GeneratedMessageV3.Builder.internalGetMapFieldReflection(int)

internalGetMutableMapFieldReflection(int number)

protected MapFieldReflectionAccessor internalGetMutableMapFieldReflection(int number)
Parameter
Name Description
number int
Returns
Type Description
com.google.protobuf.MapFieldReflectionAccessor
Overrides
com.google.protobuf.GeneratedMessageV3.Builder.internalGetMutableMapFieldReflection(int)

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(Function other)

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

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

mergeUnknownFields(UnknownFieldSet unknownFields)

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

putAllOptions(Map<String,Value> values)

public Function.Builder putAllOptions(Map<String,Value> values)

Optional. Optional named arguments that certain functions may support.

map<string, .google.firestore.v1.Value> options = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
values Map<String,Value>
Returns
Type Description
Function.Builder

putOptions(String key, Value value)

public Function.Builder putOptions(String key, Value value)

Optional. Optional named arguments that certain functions may support.

map<string, .google.firestore.v1.Value> options = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameters
Name Description
key String
value Value
Returns
Type Description
Function.Builder

putOptionsBuilderIfAbsent(String key)

public Value.Builder putOptionsBuilderIfAbsent(String key)

Optional. Optional named arguments that certain functions may support.

map<string, .google.firestore.v1.Value> options = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
key String
Returns
Type Description
Value.Builder

removeArgs(int index)

public Function.Builder removeArgs(int index)

Optional. Ordered list of arguments the given function expects.

repeated .google.firestore.v1.Value args = 2 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
index int
Returns
Type Description
Function.Builder

removeOptions(String key)

public Function.Builder removeOptions(String key)

Optional. Optional named arguments that certain functions may support.

map<string, .google.firestore.v1.Value> options = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
key String
Returns
Type Description
Function.Builder

setArgs(int index, Value value)

public Function.Builder setArgs(int index, Value value)

Optional. Ordered list of arguments the given function expects.

repeated .google.firestore.v1.Value args = 2 [(.google.api.field_behavior) = OPTIONAL];

Parameters
Name Description
index int
value Value
Returns
Type Description
Function.Builder

setArgs(int index, Value.Builder builderForValue)

public Function.Builder setArgs(int index, Value.Builder builderForValue)

Optional. Ordered list of arguments the given function expects.

repeated .google.firestore.v1.Value args = 2 [(.google.api.field_behavior) = OPTIONAL];

Parameters
Name Description
index int
builderForValue Value.Builder
Returns
Type Description
Function.Builder

setField(Descriptors.FieldDescriptor field, Object value)

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

setName(String value)

public Function.Builder setName(String value)

Required. The name of the function to evaluate.

Requires:

  • must be in snake case (lower case with underscore separator).

string name = 1 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
value String

The name to set.

Returns
Type Description
Function.Builder

This builder for chaining.

setNameBytes(ByteString value)

public Function.Builder setNameBytes(ByteString value)

Required. The name of the function to evaluate.

Requires:

  • must be in snake case (lower case with underscore separator).

string name = 1 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
value ByteString

The bytes for name to set.

Returns
Type Description
Function.Builder

This builder for chaining.

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

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

setUnknownFields(UnknownFieldSet unknownFields)

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