public static class EnumType._Builder extends net.morimekta.providence.PMessageBuilder<EnumType> implements Decl._Builder, EnumType_OrBuilder, net.morimekta.providence.serializer.binary.BinaryReader
Decl._Builder, Decl._FieldkDescriptor| Constructor and Description |
|---|
_Builder()
Make a p_model.EnumType builder instance.
|
_Builder(EnumType base)
Make a mutating builder off a base p_model.EnumType.
|
| Modifier and Type | Method and Description |
|---|---|
EnumType._Builder |
addTo(int key,
Object value) |
EnumType._Builder |
addToValues(EnumValue... values)
Adds entries to the
values list. |
EnumType |
build() |
EnumType._Builder |
clear(int key) |
EnumType._Builder |
clearAnnotations()
Clear the
annotations field. |
EnumType._Builder |
clearDocumentation()
Clear the
documentation field. |
EnumType._Builder |
clearName()
Clear the
name field. |
EnumType._Builder |
clearValues()
Clear the
values field. |
net.morimekta.providence.descriptor.PStructDescriptor<EnumType> |
descriptor() |
boolean |
equals(Object o) |
<T> T |
get(int key) |
Map<String,String> |
getAnnotations() |
String |
getDocumentation()
Documentation for the specific declaration.
|
String |
getName()
Name of the type, constant or service.
|
List<EnumValue> |
getValues() |
boolean |
has(int key) |
boolean |
hasAnnotations()
Checks for presence of the
annotations field. |
boolean |
hasDocumentation()
Checks for presence of the
documentation field. |
int |
hashCode() |
boolean |
hasName()
Checks for presence of the
name field. |
boolean |
hasValues()
Checks for presence of the
values field. |
boolean |
isModified(int key) |
boolean |
isModifiedAnnotations()
Checks if the
annotations field has been modified since the
builder was created. |
boolean |
isModifiedDocumentation()
Checks if the
documentation field has been modified since the
builder was created. |
boolean |
isModifiedName()
Checks if the
name field has been modified since the
builder was created. |
boolean |
isModifiedValues()
Checks if the
values field has been modified since the
builder was created. |
boolean |
isSet(int key) |
boolean |
isSetAnnotations()
Checks for explicit presence of the
annotations field. |
boolean |
isSetDocumentation()
Checks for explicit presence of the
documentation field. |
boolean |
isSetName()
Checks for explicit presence of the
name field. |
boolean |
isSetValues()
Checks for explicit presence of the
values field. |
EnumType._Builder |
merge(EnumType from) |
Map<String,String> |
mutableAnnotations() |
List<EnumValue> |
mutableValues() |
net.morimekta.providence.PMessageBuilder |
mutator(int key) |
int |
numAnnotations() |
int |
numValues() |
Optional<Map<String,String>> |
optionalAnnotations() |
Optional<String> |
optionalDocumentation()
Documentation for the specific declaration.
|
EnumType._Builder |
putInAnnotations(String key,
String value)
Adds a mapping to the
annotations map. |
void |
readBinary(net.morimekta.util.io.BigEndianBinaryReader reader,
boolean strict) |
EnumType._Builder |
set(int key,
Object value) |
EnumType._Builder |
setAnnotations(Map<String,String> value)
Set the
annotations field value. |
EnumType._Builder |
setDocumentation(String value)
Set the
documentation field value. |
EnumType._Builder |
setName(String value)
Set the
name field value. |
EnumType._Builder |
setValues(Collection<EnumValue> value)
Set the
values field value. |
boolean |
valid() |
EnumType._Builder |
validate() |
addTo, clear, isModified, isSet, modifiedFieldNames, modifiedFields, mutator, presentFieldNames, presentFields, setpublic _Builder()
public _Builder(EnumType base)
base - The base EnumType@Nonnull public EnumType._Builder merge(EnumType from)
merge in class net.morimekta.providence.PMessageBuilder<EnumType>@Nonnull public EnumType._Builder setDocumentation(String value)
documentation field value.setDocumentation in interface Decl._Buildervalue - The new valuepublic boolean isSetDocumentation()
documentation field.public boolean hasDocumentation()
documentation field.hasDocumentation in interface Declpublic boolean isModifiedDocumentation()
documentation field has been modified since the
builder was created.@Nonnull public EnumType._Builder clearDocumentation()
documentation field.clearDocumentation in interface Decl._Builderpublic String getDocumentation()
DeclgetDocumentation in interface Decldocumentation field value@Nonnull public Optional<String> optionalDocumentation()
DecloptionalDocumentation in interface Decldocumentation field value@Nonnull public EnumType._Builder setName(String value)
name field value.setName in interface Decl._Buildervalue - The new valuepublic boolean isSetName()
name field.public boolean hasName()
name field.public boolean isModifiedName()
name field has been modified since the
builder was created.@Nonnull public EnumType._Builder clearName()
name field.clearName in interface Decl._Builderpublic String getName()
Decl@Nonnull public EnumType._Builder setValues(Collection<EnumValue> value)
values field value.value - The new value@Nonnull public EnumType._Builder addToValues(EnumValue... values)
values list.values - The added valuepublic boolean isSetValues()
values field.public boolean hasValues()
values field.hasValues in interface EnumType_OrBuilderpublic boolean isModifiedValues()
values field has been modified since the
builder was created.@Nonnull public EnumType._Builder clearValues()
values field.public List<EnumValue> getValues()
getValues in interface EnumType_OrBuildervalues field valuepublic int numValues()
numValues in interface EnumType_OrBuildervalues.@Nonnull public EnumType._Builder setAnnotations(Map<String,String> value)
annotations field value.value - The new value@Nonnull public EnumType._Builder putInAnnotations(String key, String value)
annotations map.key - The inserted keyvalue - The inserted valuepublic boolean isSetAnnotations()
annotations field.public boolean hasAnnotations()
annotations field.hasAnnotations in interface EnumType_OrBuilderpublic boolean isModifiedAnnotations()
annotations field has been modified since the
builder was created.@Nonnull public EnumType._Builder clearAnnotations()
annotations field.public Map<String,String> mutableAnnotations()
annotations containerpublic Map<String,String> getAnnotations()
getAnnotations in interface EnumType_OrBuilderannotations field value@Nonnull public Optional<Map<String,String>> optionalAnnotations()
optionalAnnotations in interface EnumType_OrBuilderannotations field valuepublic int numAnnotations()
numAnnotations in interface EnumType_OrBuilderannotations.public net.morimekta.providence.PMessageBuilder mutator(int key)
mutator in class net.morimekta.providence.PMessageBuilder<EnumType>@Nonnull public EnumType._Builder set(int key, Object value)
set in class net.morimekta.providence.PMessageBuilder<EnumType>public boolean isSet(int key)
isSet in class net.morimekta.providence.PMessageBuilder<EnumType>public boolean isModified(int key)
isModified in class net.morimekta.providence.PMessageBuilder<EnumType>public <T> T get(int key)
get in interface net.morimekta.providence.PMessageOrBuilder<EnumType>public boolean has(int key)
has in interface net.morimekta.providence.PMessageOrBuilder<EnumType>@Nonnull public EnumType._Builder addTo(int key, Object value)
addTo in class net.morimekta.providence.PMessageBuilder<EnumType>@Nonnull public EnumType._Builder clear(int key)
clear in class net.morimekta.providence.PMessageBuilder<EnumType>public boolean valid()
valid in class net.morimekta.providence.PMessageBuilder<EnumType>public EnumType._Builder validate()
validate in class net.morimekta.providence.PMessageBuilder<EnumType>@Nonnull public net.morimekta.providence.descriptor.PStructDescriptor<EnumType> descriptor()
public void readBinary(net.morimekta.util.io.BigEndianBinaryReader reader,
boolean strict)
throws IOException
readBinary in interface net.morimekta.providence.serializer.binary.BinaryReaderIOException@Nonnull public EnumType build()
build in interface Decl._Builderbuild in class net.morimekta.providence.PMessageBuilder<EnumType>Copyright © 2015–2020 morimekta.net. All rights reserved.