Class MetricMetadata (0.27.0)

public final class MetricMetadata extends GeneratedMessageV3 implements MetricMetadataOrBuilder

Explains a metric.

Protobuf type google.analytics.data.v1beta.MetricMetadata

Static Fields

API_NAME_FIELD_NUMBER

public static final int API_NAME_FIELD_NUMBER
Field Value
TypeDescription
int

BLOCKED_REASONS_FIELD_NUMBER

public static final int BLOCKED_REASONS_FIELD_NUMBER
Field Value
TypeDescription
int

CATEGORY_FIELD_NUMBER

public static final int CATEGORY_FIELD_NUMBER
Field Value
TypeDescription
int

CUSTOM_DEFINITION_FIELD_NUMBER

public static final int CUSTOM_DEFINITION_FIELD_NUMBER
Field Value
TypeDescription
int

DEPRECATED_API_NAMES_FIELD_NUMBER

public static final int DEPRECATED_API_NAMES_FIELD_NUMBER
Field Value
TypeDescription
int

DESCRIPTION_FIELD_NUMBER

public static final int DESCRIPTION_FIELD_NUMBER
Field Value
TypeDescription
int

EXPRESSION_FIELD_NUMBER

public static final int EXPRESSION_FIELD_NUMBER
Field Value
TypeDescription
int

TYPE_FIELD_NUMBER

public static final int TYPE_FIELD_NUMBER
Field Value
TypeDescription
int

UI_NAME_FIELD_NUMBER

public static final int UI_NAME_FIELD_NUMBER
Field Value
TypeDescription
int

Static Methods

getDefaultInstance()

public static MetricMetadata getDefaultInstance()
Returns
TypeDescription
MetricMetadata

getDescriptor()

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

newBuilder()

public static MetricMetadata.Builder newBuilder()
Returns
TypeDescription
MetricMetadata.Builder

newBuilder(MetricMetadata prototype)

public static MetricMetadata.Builder newBuilder(MetricMetadata prototype)
Parameter
NameDescription
prototypeMetricMetadata
Returns
TypeDescription
MetricMetadata.Builder

parseDelimitedFrom(InputStream input)

public static MetricMetadata parseDelimitedFrom(InputStream input)
Parameter
NameDescription
inputInputStream
Returns
TypeDescription
MetricMetadata
Exceptions
TypeDescription
IOException

parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static MetricMetadata parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
MetricMetadata
Exceptions
TypeDescription
IOException

parseFrom(byte[] data)

public static MetricMetadata parseFrom(byte[] data)
Parameter
NameDescription
databyte[]
Returns
TypeDescription
MetricMetadata
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)

public static MetricMetadata parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
databyte[]
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
MetricMetadata
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteString data)

public static MetricMetadata parseFrom(ByteString data)
Parameter
NameDescription
dataByteString
Returns
TypeDescription
MetricMetadata
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)

public static MetricMetadata parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
dataByteString
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
MetricMetadata
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(CodedInputStream input)

public static MetricMetadata parseFrom(CodedInputStream input)
Parameter
NameDescription
inputCodedInputStream
Returns
TypeDescription
MetricMetadata
Exceptions
TypeDescription
IOException

parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public static MetricMetadata parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
MetricMetadata
Exceptions
TypeDescription
IOException

parseFrom(InputStream input)

public static MetricMetadata parseFrom(InputStream input)
Parameter
NameDescription
inputInputStream
Returns
TypeDescription
MetricMetadata
Exceptions
TypeDescription
IOException

parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static MetricMetadata parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
MetricMetadata
Exceptions
TypeDescription
IOException

parseFrom(ByteBuffer data)

public static MetricMetadata parseFrom(ByteBuffer data)
Parameter
NameDescription
dataByteBuffer
Returns
TypeDescription
MetricMetadata
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)

public static MetricMetadata parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
dataByteBuffer
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
MetricMetadata
Exceptions
TypeDescription
InvalidProtocolBufferException

parser()

public static Parser<MetricMetadata> parser()
Returns
TypeDescription
Parser<MetricMetadata>

Methods

equals(Object obj)

public boolean equals(Object obj)
Parameter
NameDescription
objObject
Returns
TypeDescription
boolean
Overrides

getApiName()

public String getApiName()

A metric name. Useable in Metric's name. For example, eventCount.

string api_name = 1;

Returns
TypeDescription
String

The apiName.

getApiNameBytes()

public ByteString getApiNameBytes()

A metric name. Useable in Metric's name. For example, eventCount.

string api_name = 1;

Returns
TypeDescription
ByteString

The bytes for apiName.

getBlockedReasons(int index)

public MetricMetadata.BlockedReason getBlockedReasons(int index)

If reasons are specified, your access is blocked to this metric for this property. API requests from you to this property for this metric will succeed; however, the report will contain only zeros for this metric. API requests with metric filters on blocked metrics will fail. If reasons are empty, you have access to this metric. To learn more, see Access and data-restriction management.

repeated .google.analytics.data.v1beta.MetricMetadata.BlockedReason blocked_reasons = 8;

Parameter
NameDescription
indexint

The index of the element to return.

Returns
TypeDescription
MetricMetadata.BlockedReason

The blockedReasons at the given index.

getBlockedReasonsCount()

public int getBlockedReasonsCount()

If reasons are specified, your access is blocked to this metric for this property. API requests from you to this property for this metric will succeed; however, the report will contain only zeros for this metric. API requests with metric filters on blocked metrics will fail. If reasons are empty, you have access to this metric. To learn more, see Access and data-restriction management.

repeated .google.analytics.data.v1beta.MetricMetadata.BlockedReason blocked_reasons = 8;

Returns
TypeDescription
int

The count of blockedReasons.

getBlockedReasonsList()

public List<MetricMetadata.BlockedReason> getBlockedReasonsList()

If reasons are specified, your access is blocked to this metric for this property. API requests from you to this property for this metric will succeed; however, the report will contain only zeros for this metric. API requests with metric filters on blocked metrics will fail. If reasons are empty, you have access to this metric. To learn more, see Access and data-restriction management.

repeated .google.analytics.data.v1beta.MetricMetadata.BlockedReason blocked_reasons = 8;

Returns
TypeDescription
List<BlockedReason>

A list containing the blockedReasons.

getBlockedReasonsValue(int index)

public int getBlockedReasonsValue(int index)

If reasons are specified, your access is blocked to this metric for this property. API requests from you to this property for this metric will succeed; however, the report will contain only zeros for this metric. API requests with metric filters on blocked metrics will fail. If reasons are empty, you have access to this metric. To learn more, see Access and data-restriction management.

repeated .google.analytics.data.v1beta.MetricMetadata.BlockedReason blocked_reasons = 8;

Parameter
NameDescription
indexint

The index of the value to return.

Returns
TypeDescription
int

The enum numeric value on the wire of blockedReasons at the given index.

getBlockedReasonsValueList()

public List<Integer> getBlockedReasonsValueList()

If reasons are specified, your access is blocked to this metric for this property. API requests from you to this property for this metric will succeed; however, the report will contain only zeros for this metric. API requests with metric filters on blocked metrics will fail. If reasons are empty, you have access to this metric. To learn more, see Access and data-restriction management.

repeated .google.analytics.data.v1beta.MetricMetadata.BlockedReason blocked_reasons = 8;

Returns
TypeDescription
List<Integer>

A list containing the enum numeric values on the wire for blockedReasons.

getCategory()

public String getCategory()

The display name of the category that this metrics belongs to. Similar dimensions and metrics are categorized together.

string category = 10;

Returns
TypeDescription
String

The category.

getCategoryBytes()

public ByteString getCategoryBytes()

The display name of the category that this metrics belongs to. Similar dimensions and metrics are categorized together.

string category = 10;

Returns
TypeDescription
ByteString

The bytes for category.

getCustomDefinition()

public boolean getCustomDefinition()

True if the metric is a custom metric for this property.

bool custom_definition = 7;

Returns
TypeDescription
boolean

The customDefinition.

getDefaultInstanceForType()

public MetricMetadata getDefaultInstanceForType()
Returns
TypeDescription
MetricMetadata

getDeprecatedApiNames(int index)

public String getDeprecatedApiNames(int index)

Still usable but deprecated names for this metric. If populated, this metric is available by either apiName or one of deprecatedApiNames for a period of time. After the deprecation period, the metric will be available only by apiName.

repeated string deprecated_api_names = 4;

Parameter
NameDescription
indexint

The index of the element to return.

Returns
TypeDescription
String

The deprecatedApiNames at the given index.

getDeprecatedApiNamesBytes(int index)

public ByteString getDeprecatedApiNamesBytes(int index)

Still usable but deprecated names for this metric. If populated, this metric is available by either apiName or one of deprecatedApiNames for a period of time. After the deprecation period, the metric will be available only by apiName.

repeated string deprecated_api_names = 4;

Parameter
NameDescription
indexint

The index of the value to return.

Returns
TypeDescription
ByteString

The bytes of the deprecatedApiNames at the given index.

getDeprecatedApiNamesCount()

public int getDeprecatedApiNamesCount()

Still usable but deprecated names for this metric. If populated, this metric is available by either apiName or one of deprecatedApiNames for a period of time. After the deprecation period, the metric will be available only by apiName.

repeated string deprecated_api_names = 4;

Returns
TypeDescription
int

The count of deprecatedApiNames.

getDeprecatedApiNamesList()

public ProtocolStringList getDeprecatedApiNamesList()

Still usable but deprecated names for this metric. If populated, this metric is available by either apiName or one of deprecatedApiNames for a period of time. After the deprecation period, the metric will be available only by apiName.

repeated string deprecated_api_names = 4;

Returns
TypeDescription
ProtocolStringList

A list containing the deprecatedApiNames.

getDescription()

public String getDescription()

Description of how this metric is used and calculated.

string description = 3;

Returns
TypeDescription
String

The description.

getDescriptionBytes()

public ByteString getDescriptionBytes()

Description of how this metric is used and calculated.

string description = 3;

Returns
TypeDescription
ByteString

The bytes for description.

getExpression()

public String getExpression()

The mathematical expression for this derived metric. Can be used in Metric's expression field for equivalent reports. Most metrics are not expressions, and for non-expressions, this field is empty.

string expression = 6;

Returns
TypeDescription
String

The expression.

getExpressionBytes()

public ByteString getExpressionBytes()

The mathematical expression for this derived metric. Can be used in Metric's expression field for equivalent reports. Most metrics are not expressions, and for non-expressions, this field is empty.

string expression = 6;

Returns
TypeDescription
ByteString

The bytes for expression.

getParserForType()

public Parser<MetricMetadata> getParserForType()
Returns
TypeDescription
Parser<MetricMetadata>
Overrides

getSerializedSize()

public int getSerializedSize()
Returns
TypeDescription
int
Overrides

getType()

public MetricType getType()

The type of this metric.

.google.analytics.data.v1beta.MetricType type = 5;

Returns
TypeDescription
MetricType

The type.

getTypeValue()

public int getTypeValue()

The type of this metric.

.google.analytics.data.v1beta.MetricType type = 5;

Returns
TypeDescription
int

The enum numeric value on the wire for type.

getUiName()

public String getUiName()

This metric's name within the Google Analytics user interface. For example, Event count.

string ui_name = 2;

Returns
TypeDescription
String

The uiName.

getUiNameBytes()

public ByteString getUiNameBytes()

This metric's name within the Google Analytics user interface. For example, Event count.

string ui_name = 2;

Returns
TypeDescription
ByteString

The bytes for uiName.

getUnknownFields()

public final UnknownFieldSet getUnknownFields()
Returns
TypeDescription
UnknownFieldSet
Overrides

hashCode()

public int hashCode()
Returns
TypeDescription
int
Overrides

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

newBuilderForType()

public MetricMetadata.Builder newBuilderForType()
Returns
TypeDescription
MetricMetadata.Builder

newBuilderForType(GeneratedMessageV3.BuilderParent parent)

protected MetricMetadata.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Parameter
NameDescription
parentBuilderParent
Returns
TypeDescription
MetricMetadata.Builder
Overrides

newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)

protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Parameter
NameDescription
unusedUnusedPrivateParameter
Returns
TypeDescription
Object
Overrides

toBuilder()

public MetricMetadata.Builder toBuilder()
Returns
TypeDescription
MetricMetadata.Builder

writeTo(CodedOutputStream output)

public void writeTo(CodedOutputStream output)
Parameter
NameDescription
outputCodedOutputStream
Overrides
Exceptions
TypeDescription
IOException