Class LabelStats.Builder (0.127.0)

public static final class LabelStats.Builder extends GeneratedMessageV3.Builder<LabelStats.Builder> implements LabelStatsOrBuilder

Statistics about annotation specs.

Protobuf type google.cloud.datalabeling.v1beta1.LabelStats

Implements

LabelStatsOrBuilder

Static Methods

getDescriptor()

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

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

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

build()

public LabelStats build()
Returns
TypeDescription
LabelStats

buildPartial()

public LabelStats buildPartial()
Returns
TypeDescription
LabelStats

clear()

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

clearExampleCount()

public LabelStats.Builder clearExampleCount()
Returns
TypeDescription
LabelStats.Builder

clearField(Descriptors.FieldDescriptor field)

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

clearOneof(Descriptors.OneofDescriptor oneof)

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

clone()

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

containsExampleCount(String key)

public boolean containsExampleCount(String key)

Map of each annotation spec's example count. Key is the annotation spec name and value is the number of examples for that annotation spec. If the annotated dataset does not have annotation spec, the map will return a pair where the key is empty string and value is the total number of annotations.

map<string, int64> example_count = 1;

Parameter
NameDescription
keyString
Returns
TypeDescription
boolean

getDefaultInstanceForType()

public LabelStats getDefaultInstanceForType()
Returns
TypeDescription
LabelStats

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getExampleCount()

public Map<String,Long> getExampleCount()

Use #getExampleCountMap() instead.

Returns
TypeDescription
Map<String,java.lang.Long>

getExampleCountCount()

public int getExampleCountCount()

Map of each annotation spec's example count. Key is the annotation spec name and value is the number of examples for that annotation spec. If the annotated dataset does not have annotation spec, the map will return a pair where the key is empty string and value is the total number of annotations.

map<string, int64> example_count = 1;

Returns
TypeDescription
int

getExampleCountMap()

public Map<String,Long> getExampleCountMap()

Map of each annotation spec's example count. Key is the annotation spec name and value is the number of examples for that annotation spec. If the annotated dataset does not have annotation spec, the map will return a pair where the key is empty string and value is the total number of annotations.

map<string, int64> example_count = 1;

Returns
TypeDescription
Map<String,java.lang.Long>

getExampleCountOrDefault(String key, long defaultValue)

public long getExampleCountOrDefault(String key, long defaultValue)

Map of each annotation spec's example count. Key is the annotation spec name and value is the number of examples for that annotation spec. If the annotated dataset does not have annotation spec, the map will return a pair where the key is empty string and value is the total number of annotations.

map<string, int64> example_count = 1;

Parameters
NameDescription
keyString
defaultValuelong
Returns
TypeDescription
long

getExampleCountOrThrow(String key)

public long getExampleCountOrThrow(String key)

Map of each annotation spec's example count. Key is the annotation spec name and value is the number of examples for that annotation spec. If the annotated dataset does not have annotation spec, the map will return a pair where the key is empty string and value is the total number of annotations.

map<string, int64> example_count = 1;

Parameter
NameDescription
keyString
Returns
TypeDescription
long

getMutableExampleCount()

public Map<String,Long> getMutableExampleCount()

Use alternate mutation accessors instead.

Returns
TypeDescription
Map<String,java.lang.Long>

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

internalGetMapField(int number)

protected MapField internalGetMapField(int number)
Parameter
NameDescription
numberint
Returns
TypeDescription
MapField
Overrides

internalGetMutableMapField(int number)

protected MapField internalGetMutableMapField(int number)
Parameter
NameDescription
numberint
Returns
TypeDescription
MapField
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeFrom(LabelStats other)

public LabelStats.Builder mergeFrom(LabelStats other)
Parameter
NameDescription
otherLabelStats
Returns
TypeDescription
LabelStats.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

mergeUnknownFields(UnknownFieldSet unknownFields)

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

putAllExampleCount(Map<String,Long> values)

public LabelStats.Builder putAllExampleCount(Map<String,Long> values)

Map of each annotation spec's example count. Key is the annotation spec name and value is the number of examples for that annotation spec. If the annotated dataset does not have annotation spec, the map will return a pair where the key is empty string and value is the total number of annotations.

map<string, int64> example_count = 1;

Parameter
NameDescription
valuesMap<String,java.lang.Long>
Returns
TypeDescription
LabelStats.Builder

putExampleCount(String key, long value)

public LabelStats.Builder putExampleCount(String key, long value)

Map of each annotation spec's example count. Key is the annotation spec name and value is the number of examples for that annotation spec. If the annotated dataset does not have annotation spec, the map will return a pair where the key is empty string and value is the total number of annotations.

map<string, int64> example_count = 1;

Parameters
NameDescription
keyString
valuelong
Returns
TypeDescription
LabelStats.Builder

removeExampleCount(String key)

public LabelStats.Builder removeExampleCount(String key)

Map of each annotation spec's example count. Key is the annotation spec name and value is the number of examples for that annotation spec. If the annotated dataset does not have annotation spec, the map will return a pair where the key is empty string and value is the total number of annotations.

map<string, int64> example_count = 1;

Parameter
NameDescription
keyString
Returns
TypeDescription
LabelStats.Builder

setField(Descriptors.FieldDescriptor field, Object value)

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

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

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

setUnknownFields(UnknownFieldSet unknownFields)

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