Class Dimension.Builder (0.21.0)

public static final class Dimension.Builder extends GeneratedMessageV3.Builder<Dimension.Builder> implements DimensionOrBuilder

Dimensions are attributes of your data. For example, the dimension city indicates the city from which an event originates. Dimension values in report responses are strings; for example, the city could be "Paris" or "New York".

Protobuf type google.analytics.data.v1alpha.Dimension

Implements

DimensionOrBuilder

Static Methods

getDescriptor()

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

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

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

build()

public Dimension build()
Returns
TypeDescription
Dimension

buildPartial()

public Dimension buildPartial()
Returns
TypeDescription
Dimension

clear()

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

clearDimensionExpression()

public Dimension.Builder clearDimensionExpression()

One dimension can be the result of an expression of multiple dimensions. For example, dimension "country, city": concatenate(country, ", ", city).

.google.analytics.data.v1alpha.DimensionExpression dimension_expression = 2;

Returns
TypeDescription
Dimension.Builder

clearField(Descriptors.FieldDescriptor field)

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

clearName()

public Dimension.Builder clearName()

The name of the dimension. See the API Dimensions for the list of dimension names. If dimensionExpression is specified, name can be any string that you would like within the allowed character set. For example if a dimensionExpression concatenates country and city, you could call that dimension countryAndCity. Dimension names that you choose must match the regular expression ^[a-zA-Z0-9_]$. Dimensions are referenced by name in dimensionFilter, orderBys, dimensionExpression, and pivots.

string name = 1;

Returns
TypeDescription
Dimension.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

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

clone()

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

getDefaultInstanceForType()

public Dimension getDefaultInstanceForType()
Returns
TypeDescription
Dimension

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getDimensionExpression()

public DimensionExpression getDimensionExpression()

One dimension can be the result of an expression of multiple dimensions. For example, dimension "country, city": concatenate(country, ", ", city).

.google.analytics.data.v1alpha.DimensionExpression dimension_expression = 2;

Returns
TypeDescription
DimensionExpression

The dimensionExpression.

getDimensionExpressionBuilder()

public DimensionExpression.Builder getDimensionExpressionBuilder()

One dimension can be the result of an expression of multiple dimensions. For example, dimension "country, city": concatenate(country, ", ", city).

.google.analytics.data.v1alpha.DimensionExpression dimension_expression = 2;

Returns
TypeDescription
DimensionExpression.Builder

getDimensionExpressionOrBuilder()

public DimensionExpressionOrBuilder getDimensionExpressionOrBuilder()

One dimension can be the result of an expression of multiple dimensions. For example, dimension "country, city": concatenate(country, ", ", city).

.google.analytics.data.v1alpha.DimensionExpression dimension_expression = 2;

Returns
TypeDescription
DimensionExpressionOrBuilder

getName()

public String getName()

The name of the dimension. See the API Dimensions for the list of dimension names. If dimensionExpression is specified, name can be any string that you would like within the allowed character set. For example if a dimensionExpression concatenates country and city, you could call that dimension countryAndCity. Dimension names that you choose must match the regular expression ^[a-zA-Z0-9_]$. Dimensions are referenced by name in dimensionFilter, orderBys, dimensionExpression, and pivots.

string name = 1;

Returns
TypeDescription
String

The name.

getNameBytes()

public ByteString getNameBytes()

The name of the dimension. See the API Dimensions for the list of dimension names. If dimensionExpression is specified, name can be any string that you would like within the allowed character set. For example if a dimensionExpression concatenates country and city, you could call that dimension countryAndCity. Dimension names that you choose must match the regular expression ^[a-zA-Z0-9_]$. Dimensions are referenced by name in dimensionFilter, orderBys, dimensionExpression, and pivots.

string name = 1;

Returns
TypeDescription
ByteString

The bytes for name.

hasDimensionExpression()

public boolean hasDimensionExpression()

One dimension can be the result of an expression of multiple dimensions. For example, dimension "country, city": concatenate(country, ", ", city).

.google.analytics.data.v1alpha.DimensionExpression dimension_expression = 2;

Returns
TypeDescription
boolean

Whether the dimensionExpression field is set.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeDimensionExpression(DimensionExpression value)

public Dimension.Builder mergeDimensionExpression(DimensionExpression value)

One dimension can be the result of an expression of multiple dimensions. For example, dimension "country, city": concatenate(country, ", ", city).

.google.analytics.data.v1alpha.DimensionExpression dimension_expression = 2;

Parameter
NameDescription
valueDimensionExpression
Returns
TypeDescription
Dimension.Builder

mergeFrom(Dimension other)

public Dimension.Builder mergeFrom(Dimension other)
Parameter
NameDescription
otherDimension
Returns
TypeDescription
Dimension.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

mergeUnknownFields(UnknownFieldSet unknownFields)

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

setDimensionExpression(DimensionExpression value)

public Dimension.Builder setDimensionExpression(DimensionExpression value)

One dimension can be the result of an expression of multiple dimensions. For example, dimension "country, city": concatenate(country, ", ", city).

.google.analytics.data.v1alpha.DimensionExpression dimension_expression = 2;

Parameter
NameDescription
valueDimensionExpression
Returns
TypeDescription
Dimension.Builder

setDimensionExpression(DimensionExpression.Builder builderForValue)

public Dimension.Builder setDimensionExpression(DimensionExpression.Builder builderForValue)

One dimension can be the result of an expression of multiple dimensions. For example, dimension "country, city": concatenate(country, ", ", city).

.google.analytics.data.v1alpha.DimensionExpression dimension_expression = 2;

Parameter
NameDescription
builderForValueDimensionExpression.Builder
Returns
TypeDescription
Dimension.Builder

setField(Descriptors.FieldDescriptor field, Object value)

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

setName(String value)

public Dimension.Builder setName(String value)

The name of the dimension. See the API Dimensions for the list of dimension names. If dimensionExpression is specified, name can be any string that you would like within the allowed character set. For example if a dimensionExpression concatenates country and city, you could call that dimension countryAndCity. Dimension names that you choose must match the regular expression ^[a-zA-Z0-9_]$. Dimensions are referenced by name in dimensionFilter, orderBys, dimensionExpression, and pivots.

string name = 1;

Parameter
NameDescription
valueString

The name to set.

Returns
TypeDescription
Dimension.Builder

This builder for chaining.

setNameBytes(ByteString value)

public Dimension.Builder setNameBytes(ByteString value)

The name of the dimension. See the API Dimensions for the list of dimension names. If dimensionExpression is specified, name can be any string that you would like within the allowed character set. For example if a dimensionExpression concatenates country and city, you could call that dimension countryAndCity. Dimension names that you choose must match the regular expression ^[a-zA-Z0-9_]$. Dimensions are referenced by name in dimensionFilter, orderBys, dimensionExpression, and pivots.

string name = 1;

Parameter
NameDescription
valueByteString

The bytes for name to set.

Returns
TypeDescription
Dimension.Builder

This builder for chaining.

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

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

setUnknownFields(UnknownFieldSet unknownFields)

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