Package net.morimekta.providence.model
Class ServiceType._Builder
- java.lang.Object
-
- net.morimekta.providence.PMessageBuilder<ServiceType,ServiceType._Field>
-
- net.morimekta.providence.model.ServiceType._Builder
-
- All Implemented Interfaces:
net.morimekta.providence.PBuilder<ServiceType>,net.morimekta.providence.serializer.binary.BinaryReader
- Enclosing class:
- ServiceType
public static class ServiceType._Builder extends net.morimekta.providence.PMessageBuilder<ServiceType,ServiceType._Field> implements net.morimekta.providence.serializer.binary.BinaryReader
service (extends <extend>)? { (<method> [;,]?)* }
-
-
Constructor Summary
Constructors Constructor Description _Builder()Make a providence_model.ServiceType builder._Builder(ServiceType base)Make a mutating builder off a base providence_model.ServiceType.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ServiceType._BuilderaddTo(int key, java.lang.Object value)ServiceType._BuilderaddToMethods(FunctionType... values)Adds entries to methods.ServiceTypebuild()ServiceType._Builderclear(int key)ServiceType._BuilderclearAnnotations()Clears the annotations field.ServiceType._BuilderclearDocumentation()Clears the documentation field.ServiceType._BuilderclearExtend()Clears the extend field.ServiceType._BuilderclearMethods()Clears the methods field.ServiceType._BuilderclearName()Clears the name field.net.morimekta.providence.descriptor.PStructDescriptor<ServiceType,ServiceType._Field>descriptor()booleanequals(java.lang.Object o)java.lang.StringgetDocumentation()Gets the value of the contained documentation.java.lang.StringgetExtend()Gets the value of the contained extend.java.lang.StringgetName()Gets the value of the contained name.inthashCode()booleanisModified(int key)booleanisModifiedAnnotations()Checks if annotations has been modified since the _Builder was created.booleanisModifiedDocumentation()Checks if documentation has been modified since the _Builder was created.booleanisModifiedExtend()Checks if extend has been modified since the _Builder was created.booleanisModifiedMethods()Checks if methods has been modified since the _Builder was created.booleanisModifiedName()Checks if name has been modified since the _Builder was created.booleanisSet(int key)booleanisSetAnnotations()Checks for presence of the annotations field.booleanisSetDocumentation()Checks for presence of the documentation field.booleanisSetExtend()Checks for presence of the extend field.booleanisSetMethods()Checks for presence of the methods field.booleanisSetName()Checks for presence of the name field.ServiceType._Buildermerge(ServiceType from)java.util.Map<java.lang.String,java.lang.String>mutableAnnotations()Gets the builder for the contained annotations.java.util.List<FunctionType>mutableMethods()Gets the builder for the contained methods.net.morimekta.providence.PMessageBuildermutator(int key)ServiceType._BuilderputInAnnotations(java.lang.String key, java.lang.String value)Adds a mapping to annotations.voidreadBinary(net.morimekta.util.io.BigEndianBinaryReader reader, boolean strict)ServiceType._Builderset(int key, java.lang.Object value)ServiceType._BuildersetAnnotations(java.util.Map<java.lang.String,java.lang.String> value)Sets the value of annotations.ServiceType._BuildersetDocumentation(java.lang.String value)Sets the value of documentation.ServiceType._BuildersetExtend(java.lang.String value)Sets the value of extend.ServiceType._BuildersetMethods(java.util.Collection<FunctionType> value)Sets the value of methods.ServiceType._BuildersetName(java.lang.String value)Sets the value of name.booleanvalid()voidvalidate()
-
-
-
Constructor Detail
-
_Builder
public _Builder()
Make a providence_model.ServiceType builder.
-
_Builder
public _Builder(ServiceType base)
Make a mutating builder off a base providence_model.ServiceType.- Parameters:
base- The base ServiceType
-
-
Method Detail
-
merge
@Nonnull public ServiceType._Builder merge(ServiceType from)
- Specified by:
mergein classnet.morimekta.providence.PMessageBuilder<ServiceType,ServiceType._Field>
-
setDocumentation
@Nonnull public ServiceType._Builder setDocumentation(java.lang.String value)
Sets the value of documentation.- Parameters:
value- The new value- Returns:
- The builder
-
isSetDocumentation
public boolean isSetDocumentation()
Checks for presence of the documentation field.- Returns:
- True if documentation has been set.
-
isModifiedDocumentation
public boolean isModifiedDocumentation()
Checks if documentation has been modified since the _Builder was created.- Returns:
- True if documentation has been modified.
-
clearDocumentation
@Nonnull public ServiceType._Builder clearDocumentation()
Clears the documentation field.- Returns:
- The builder
-
getDocumentation
public java.lang.String getDocumentation()
Gets the value of the contained documentation.- Returns:
- The field value
-
setName
@Nonnull public ServiceType._Builder setName(java.lang.String value)
Sets the value of name.- Parameters:
value- The new value- Returns:
- The builder
-
isSetName
public boolean isSetName()
Checks for presence of the name field.- Returns:
- True if name has been set.
-
isModifiedName
public boolean isModifiedName()
Checks if name has been modified since the _Builder was created.- Returns:
- True if name has been modified.
-
clearName
@Nonnull public ServiceType._Builder clearName()
Clears the name field.- Returns:
- The builder
-
getName
public java.lang.String getName()
Gets the value of the contained name.- Returns:
- The field value
-
setExtend
@Nonnull public ServiceType._Builder setExtend(java.lang.String value)
Sets the value of extend.- Parameters:
value- The new value- Returns:
- The builder
-
isSetExtend
public boolean isSetExtend()
Checks for presence of the extend field.- Returns:
- True if extend has been set.
-
isModifiedExtend
public boolean isModifiedExtend()
Checks if extend has been modified since the _Builder was created.- Returns:
- True if extend has been modified.
-
clearExtend
@Nonnull public ServiceType._Builder clearExtend()
Clears the extend field.- Returns:
- The builder
-
getExtend
public java.lang.String getExtend()
Gets the value of the contained extend.- Returns:
- The field value
-
setMethods
@Nonnull public ServiceType._Builder setMethods(java.util.Collection<FunctionType> value)
Sets the value of methods.- Parameters:
value- The new value- Returns:
- The builder
-
addToMethods
@Nonnull public ServiceType._Builder addToMethods(FunctionType... values)
Adds entries to methods.- Parameters:
values- The added value- Returns:
- The builder
-
isSetMethods
public boolean isSetMethods()
Checks for presence of the methods field.- Returns:
- True if methods has been set.
-
isModifiedMethods
public boolean isModifiedMethods()
Checks if methods has been modified since the _Builder was created.- Returns:
- True if methods has been modified.
-
clearMethods
@Nonnull public ServiceType._Builder clearMethods()
Clears the methods field.- Returns:
- The builder
-
mutableMethods
@Nonnull public java.util.List<FunctionType> mutableMethods()
Gets the builder for the contained methods.- Returns:
- The field builder
-
setAnnotations
@Nonnull public ServiceType._Builder setAnnotations(java.util.Map<java.lang.String,java.lang.String> value)
Sets the value of annotations.- Parameters:
value- The new value- Returns:
- The builder
-
putInAnnotations
@Nonnull public ServiceType._Builder putInAnnotations(java.lang.String key, java.lang.String value)
Adds a mapping to annotations.- Parameters:
key- The inserted keyvalue- The inserted value- Returns:
- The builder
-
isSetAnnotations
public boolean isSetAnnotations()
Checks for presence of the annotations field.- Returns:
- True if annotations has been set.
-
isModifiedAnnotations
public boolean isModifiedAnnotations()
Checks if annotations has been modified since the _Builder was created.- Returns:
- True if annotations has been modified.
-
clearAnnotations
@Nonnull public ServiceType._Builder clearAnnotations()
Clears the annotations field.- Returns:
- The builder
-
mutableAnnotations
@Nonnull public java.util.Map<java.lang.String,java.lang.String> mutableAnnotations()
Gets the builder for the contained annotations.- Returns:
- The field builder
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equalsin classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
mutator
public net.morimekta.providence.PMessageBuilder mutator(int key)
- Specified by:
mutatorin classnet.morimekta.providence.PMessageBuilder<ServiceType,ServiceType._Field>
-
set
@Nonnull public ServiceType._Builder set(int key, java.lang.Object value)
- Specified by:
setin classnet.morimekta.providence.PMessageBuilder<ServiceType,ServiceType._Field>
-
isSet
public boolean isSet(int key)
- Specified by:
isSetin classnet.morimekta.providence.PMessageBuilder<ServiceType,ServiceType._Field>
-
isModified
public boolean isModified(int key)
- Specified by:
isModifiedin classnet.morimekta.providence.PMessageBuilder<ServiceType,ServiceType._Field>
-
addTo
public ServiceType._Builder addTo(int key, java.lang.Object value)
- Specified by:
addToin classnet.morimekta.providence.PMessageBuilder<ServiceType,ServiceType._Field>
-
clear
@Nonnull public ServiceType._Builder clear(int key)
- Specified by:
clearin classnet.morimekta.providence.PMessageBuilder<ServiceType,ServiceType._Field>
-
valid
public boolean valid()
- Specified by:
validin classnet.morimekta.providence.PMessageBuilder<ServiceType,ServiceType._Field>
-
validate
public void validate()
- Specified by:
validatein classnet.morimekta.providence.PMessageBuilder<ServiceType,ServiceType._Field>
-
descriptor
@Nonnull public net.morimekta.providence.descriptor.PStructDescriptor<ServiceType,ServiceType._Field> descriptor()
- Specified by:
descriptorin classnet.morimekta.providence.PMessageBuilder<ServiceType,ServiceType._Field>
-
readBinary
public void readBinary(net.morimekta.util.io.BigEndianBinaryReader reader, boolean strict) throws java.io.IOException- Specified by:
readBinaryin interfacenet.morimekta.providence.serializer.binary.BinaryReader- Throws:
java.io.IOException
-
build
public ServiceType build()
- Specified by:
buildin interfacenet.morimekta.providence.PBuilder<ServiceType>
-
-