Module org.elasticsearch.xcore
Record Class RoleDescriptor.Parser
java.lang.Object
java.lang.Record
org.elasticsearch.xpack.core.security.authz.RoleDescriptor.Parser
- Enclosing class:
RoleDescriptor
public static record RoleDescriptor.Parser(boolean allow2xFormat, boolean allowRestriction, boolean allowDescription)
extends Record
-
Nested Class Summary
Nested Classes -
Constructor Summary
ConstructorsConstructorDescriptionParser(boolean allow2xFormat, boolean allowRestriction, boolean allowDescription) Creates an instance of aParserrecord class. -
Method Summary
Modifier and TypeMethodDescriptionbooleanReturns the value of theallow2xFormatrecord component.booleanReturns the value of theallowDescriptionrecord component.booleanReturns the value of theallowRestrictionrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.parse(String name, BytesReference source, org.elasticsearch.xcontent.XContentType xContentType) final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
Parser
public Parser(boolean allow2xFormat, boolean allowRestriction, boolean allowDescription) Creates an instance of aParserrecord class.- Parameters:
allow2xFormat- the value for theallow2xFormatrecord componentallowRestriction- the value for theallowRestrictionrecord componentallowDescription- the value for theallowDescriptionrecord component
-
-
Method Details
-
parse
public RoleDescriptor parse(String name, BytesReference source, org.elasticsearch.xcontent.XContentType xContentType) throws IOException - Throws:
IOException
-
parse
public RoleDescriptor parse(String name, org.elasticsearch.xcontent.XContentParser parser) throws IOException - Throws:
IOException
-
parse
public RoleDescriptor parse(String name, org.elasticsearch.xcontent.XContentParser parser, boolean validate) throws IOException - Throws:
IOException
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with '=='. -
allow2xFormat
public boolean allow2xFormat()Returns the value of theallow2xFormatrecord component.- Returns:
- the value of the
allow2xFormatrecord component
-
allowRestriction
public boolean allowRestriction()Returns the value of theallowRestrictionrecord component.- Returns:
- the value of the
allowRestrictionrecord component
-
allowDescription
public boolean allowDescription()Returns the value of theallowDescriptionrecord component.- Returns:
- the value of the
allowDescriptionrecord component
-