Package io.envoyproxy.pgv.validate
Class Validate.EnumRules.Builder
java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessage.Builder<Validate.EnumRules.Builder>
io.envoyproxy.pgv.validate.Validate.EnumRules.Builder
- All Implemented Interfaces:
com.google.protobuf.Message.Builder
,com.google.protobuf.MessageLite.Builder
,com.google.protobuf.MessageLiteOrBuilder
,com.google.protobuf.MessageOrBuilder
,Validate.EnumRulesOrBuilder
,Cloneable
- Enclosing class:
- Validate.EnumRules
public static final class Validate.EnumRules.Builder
extends com.google.protobuf.GeneratedMessage.Builder<Validate.EnumRules.Builder>
implements Validate.EnumRulesOrBuilder
EnumRules describe the constraints applied to enum valuesProtobuf type
validate.EnumRules
-
Method Summary
Modifier and TypeMethodDescriptionIn specifies that this field must be equal to one of the specified valuesaddAllNotIn
(Iterable<? extends Integer> values) NotIn specifies that this field cannot be equal to one of the specified valuesaddIn
(int value) In specifies that this field must be equal to one of the specified valuesaddNotIn
(int value) NotIn specifies that this field cannot be equal to one of the specified valuesbuild()
clear()
Const specifies that this field must be exactly the specified valueDefinedOnly specifies that this field must be only one of the defined values for this enum, failing on any undefined value.clearIn()
In specifies that this field must be equal to one of the specified valuesNotIn specifies that this field cannot be equal to one of the specified valuesint
getConst()
Const specifies that this field must be exactly the specified valueboolean
DefinedOnly specifies that this field must be only one of the defined values for this enum, failing on any undefined value.static final com.google.protobuf.Descriptors.Descriptor
com.google.protobuf.Descriptors.Descriptor
int
getIn
(int index) In specifies that this field must be equal to one of the specified valuesint
In specifies that this field must be equal to one of the specified valuesIn specifies that this field must be equal to one of the specified valuesint
getNotIn
(int index) NotIn specifies that this field cannot be equal to one of the specified valuesint
NotIn specifies that this field cannot be equal to one of the specified valuesNotIn specifies that this field cannot be equal to one of the specified valuesboolean
hasConst()
Const specifies that this field must be exactly the specified valueboolean
DefinedOnly specifies that this field must be only one of the defined values for this enum, failing on any undefined value.protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
final boolean
mergeFrom
(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) mergeFrom
(com.google.protobuf.Message other) mergeFrom
(Validate.EnumRules other) setConst
(int value) Const specifies that this field must be exactly the specified valuesetDefinedOnly
(boolean value) DefinedOnly specifies that this field must be only one of the defined values for this enum, failing on any undefined value.setIn
(int index, int value) In specifies that this field must be equal to one of the specified valuessetNotIn
(int index, int value) NotIn specifies that this field cannot be equal to one of the specified valuesMethods inherited from class com.google.protobuf.GeneratedMessage.Builder
addRepeatedField, clearField, clearOneof, clone, getAllFields, getField, getFieldBuilder, getOneofFieldDescriptor, getParentForChildren, getRepeatedField, getRepeatedFieldBuilder, getRepeatedFieldCount, getUnknownFields, getUnknownFieldSetBuilder, hasField, hasOneof, internalGetMapField, internalGetMapFieldReflection, internalGetMutableMapField, internalGetMutableMapFieldReflection, isClean, markClean, mergeUnknownFields, mergeUnknownLengthDelimitedField, mergeUnknownVarintField, newBuilderForField, onBuilt, onChanged, parseUnknownField, setField, setRepeatedField, setUnknownFields, setUnknownFieldSetBuilder, setUnknownFieldsProto3
Methods inherited from class com.google.protobuf.AbstractMessage.Builder
findInitializationErrors, getInitializationErrorString, internalMergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException, toString
Methods inherited from class com.google.protobuf.AbstractMessageLite.Builder
addAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, newUninitializedMessageException
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface com.google.protobuf.Message.Builder
mergeDelimitedFrom, mergeDelimitedFrom
Methods inherited from interface com.google.protobuf.MessageLite.Builder
mergeFrom
Methods inherited from interface com.google.protobuf.MessageOrBuilder
findInitializationErrors, getAllFields, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
-
Method Details
-
getDescriptor
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() -
internalGetFieldAccessorTable
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()- Specified by:
internalGetFieldAccessorTable
in classcom.google.protobuf.GeneratedMessage.Builder<Validate.EnumRules.Builder>
-
clear
- Specified by:
clear
in interfacecom.google.protobuf.Message.Builder
- Specified by:
clear
in interfacecom.google.protobuf.MessageLite.Builder
- Overrides:
clear
in classcom.google.protobuf.GeneratedMessage.Builder<Validate.EnumRules.Builder>
-
getDescriptorForType
public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()- Specified by:
getDescriptorForType
in interfacecom.google.protobuf.Message.Builder
- Specified by:
getDescriptorForType
in interfacecom.google.protobuf.MessageOrBuilder
- Overrides:
getDescriptorForType
in classcom.google.protobuf.GeneratedMessage.Builder<Validate.EnumRules.Builder>
-
getDefaultInstanceForType
- Specified by:
getDefaultInstanceForType
in interfacecom.google.protobuf.MessageLiteOrBuilder
- Specified by:
getDefaultInstanceForType
in interfacecom.google.protobuf.MessageOrBuilder
-
build
- Specified by:
build
in interfacecom.google.protobuf.Message.Builder
- Specified by:
build
in interfacecom.google.protobuf.MessageLite.Builder
-
buildPartial
- Specified by:
buildPartial
in interfacecom.google.protobuf.Message.Builder
- Specified by:
buildPartial
in interfacecom.google.protobuf.MessageLite.Builder
-
mergeFrom
- Specified by:
mergeFrom
in interfacecom.google.protobuf.Message.Builder
- Overrides:
mergeFrom
in classcom.google.protobuf.AbstractMessage.Builder<Validate.EnumRules.Builder>
-
mergeFrom
-
isInitialized
public final boolean isInitialized()- Specified by:
isInitialized
in interfacecom.google.protobuf.MessageLiteOrBuilder
- Overrides:
isInitialized
in classcom.google.protobuf.GeneratedMessage.Builder<Validate.EnumRules.Builder>
-
mergeFrom
public Validate.EnumRules.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Specified by:
mergeFrom
in interfacecom.google.protobuf.Message.Builder
- Specified by:
mergeFrom
in interfacecom.google.protobuf.MessageLite.Builder
- Overrides:
mergeFrom
in classcom.google.protobuf.AbstractMessage.Builder<Validate.EnumRules.Builder>
- Throws:
IOException
-
hasConst
public boolean hasConst()Const specifies that this field must be exactly the specified value
optional int32 const = 1;
- Specified by:
hasConst
in interfaceValidate.EnumRulesOrBuilder
- Returns:
- Whether the const field is set.
-
getConst
public int getConst()Const specifies that this field must be exactly the specified value
optional int32 const = 1;
- Specified by:
getConst
in interfaceValidate.EnumRulesOrBuilder
- Returns:
- The const.
-
setConst
Const specifies that this field must be exactly the specified value
optional int32 const = 1;
- Parameters:
value
- The const to set.- Returns:
- This builder for chaining.
-
clearConst
Const specifies that this field must be exactly the specified value
optional int32 const = 1;
- Returns:
- This builder for chaining.
-
hasDefinedOnly
public boolean hasDefinedOnly()DefinedOnly specifies that this field must be only one of the defined values for this enum, failing on any undefined value.
optional bool defined_only = 2;
- Specified by:
hasDefinedOnly
in interfaceValidate.EnumRulesOrBuilder
- Returns:
- Whether the definedOnly field is set.
-
getDefinedOnly
public boolean getDefinedOnly()DefinedOnly specifies that this field must be only one of the defined values for this enum, failing on any undefined value.
optional bool defined_only = 2;
- Specified by:
getDefinedOnly
in interfaceValidate.EnumRulesOrBuilder
- Returns:
- The definedOnly.
-
setDefinedOnly
DefinedOnly specifies that this field must be only one of the defined values for this enum, failing on any undefined value.
optional bool defined_only = 2;
- Parameters:
value
- The definedOnly to set.- Returns:
- This builder for chaining.
-
clearDefinedOnly
DefinedOnly specifies that this field must be only one of the defined values for this enum, failing on any undefined value.
optional bool defined_only = 2;
- Returns:
- This builder for chaining.
-
getInList
In specifies that this field must be equal to one of the specified values
repeated int32 in = 3;
- Specified by:
getInList
in interfaceValidate.EnumRulesOrBuilder
- Returns:
- A list containing the in.
-
getInCount
public int getInCount()In specifies that this field must be equal to one of the specified values
repeated int32 in = 3;
- Specified by:
getInCount
in interfaceValidate.EnumRulesOrBuilder
- Returns:
- The count of in.
-
getIn
public int getIn(int index) In specifies that this field must be equal to one of the specified values
repeated int32 in = 3;
- Specified by:
getIn
in interfaceValidate.EnumRulesOrBuilder
- Parameters:
index
- The index of the element to return.- Returns:
- The in at the given index.
-
setIn
In specifies that this field must be equal to one of the specified values
repeated int32 in = 3;
- Parameters:
index
- The index to set the value at.value
- The in to set.- Returns:
- This builder for chaining.
-
addIn
In specifies that this field must be equal to one of the specified values
repeated int32 in = 3;
- Parameters:
value
- The in to add.- Returns:
- This builder for chaining.
-
addAllIn
In specifies that this field must be equal to one of the specified values
repeated int32 in = 3;
- Parameters:
values
- The in to add.- Returns:
- This builder for chaining.
-
clearIn
In specifies that this field must be equal to one of the specified values
repeated int32 in = 3;
- Returns:
- This builder for chaining.
-
getNotInList
NotIn specifies that this field cannot be equal to one of the specified values
repeated int32 not_in = 4;
- Specified by:
getNotInList
in interfaceValidate.EnumRulesOrBuilder
- Returns:
- A list containing the notIn.
-
getNotInCount
public int getNotInCount()NotIn specifies that this field cannot be equal to one of the specified values
repeated int32 not_in = 4;
- Specified by:
getNotInCount
in interfaceValidate.EnumRulesOrBuilder
- Returns:
- The count of notIn.
-
getNotIn
public int getNotIn(int index) NotIn specifies that this field cannot be equal to one of the specified values
repeated int32 not_in = 4;
- Specified by:
getNotIn
in interfaceValidate.EnumRulesOrBuilder
- Parameters:
index
- The index of the element to return.- Returns:
- The notIn at the given index.
-
setNotIn
NotIn specifies that this field cannot be equal to one of the specified values
repeated int32 not_in = 4;
- Parameters:
index
- The index to set the value at.value
- The notIn to set.- Returns:
- This builder for chaining.
-
addNotIn
NotIn specifies that this field cannot be equal to one of the specified values
repeated int32 not_in = 4;
- Parameters:
value
- The notIn to add.- Returns:
- This builder for chaining.
-
addAllNotIn
NotIn specifies that this field cannot be equal to one of the specified values
repeated int32 not_in = 4;
- Parameters:
values
- The notIn to add.- Returns:
- This builder for chaining.
-
clearNotIn
NotIn specifies that this field cannot be equal to one of the specified values
repeated int32 not_in = 4;
- Returns:
- This builder for chaining.
-