Enum Field.Cardinality (3.19.4)

public enum Field.Cardinality extends Enum<Field.Cardinality> implements Internal.EnumLite

Whether a field is optional, required, or repeated.

Protobuf enum google.protobuf.Field.Cardinality

Implements

Internal.EnumLite

Static Fields

NameDescription
CARDINALITY_OPTIONAL

For optional fields.

CARDINALITY_OPTIONAL = 1;

CARDINALITY_OPTIONAL_VALUE

For optional fields.

CARDINALITY_OPTIONAL = 1;

CARDINALITY_REPEATED

For repeated fields.

CARDINALITY_REPEATED = 3;

CARDINALITY_REPEATED_VALUE

For repeated fields.

CARDINALITY_REPEATED = 3;

CARDINALITY_REQUIRED

For required fields. Proto2 syntax only.

CARDINALITY_REQUIRED = 2;

CARDINALITY_REQUIRED_VALUE

For required fields. Proto2 syntax only.

CARDINALITY_REQUIRED = 2;

CARDINALITY_UNKNOWN

For fields with unknown cardinality.

CARDINALITY_UNKNOWN = 0;

CARDINALITY_UNKNOWN_VALUE

For fields with unknown cardinality.

CARDINALITY_UNKNOWN = 0;

UNRECOGNIZED

Static Methods

NameDescription
forNumber(int value)
internalGetValueMap()
internalGetVerifier()
valueOf(int value)

Deprecated. Use #forNumber(int) instead.

valueOf(String name)
values()

Methods

NameDescription
getNumber()