Class FieldRoleMapperExpression
- java.lang.Object
-
- org.elasticsearch.client.security.support.expressiondsl.fields.FieldRoleMapperExpression
-
- All Implemented Interfaces:
RoleMapperExpression,ToXContent,ToXContentObject
public class FieldRoleMapperExpression extends Object implements RoleMapperExpression
An expression that evaluates totrueif a field (map element) matches the provided values. A field expression may have more than one provided value, in which case the expression is true if any of the values are matched.Expression builder example:
final RoleMapperExpression usernameExpression = FieldRoleMapperExpression.ofUsername("user1@example.org");
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.elasticsearch.common.xcontent.ToXContent
ToXContent.DelegatingMapParams, ToXContent.MapParams, ToXContent.Params
-
-
Field Summary
-
Fields inherited from interface org.elasticsearch.common.xcontent.ToXContent
EMPTY_PARAMS
-
-
Constructor Summary
Constructors Constructor Description FieldRoleMapperExpression(String field, Object... values)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object o)StringgetField()List<Object>getValues()inthashCode()static FieldRoleMapperExpressionofDN(Object... values)static FieldRoleMapperExpressionofGroups(Object... values)static FieldRoleMapperExpressionofKeyValues(String key, Object... values)static FieldRoleMapperExpressionofMetadata(String key, Object... values)static FieldRoleMapperExpressionofUsername(Object... values)XContentBuildertoXContent(XContentBuilder builder, ToXContent.Params params)-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.elasticsearch.common.xcontent.ToXContentObject
isFragment
-
-
-
-
Method Detail
-
getField
public String getField()
-
toXContent
public XContentBuilder toXContent(XContentBuilder builder, ToXContent.Params params) throws IOException
- Specified by:
toXContentin interfaceToXContent- Throws:
IOException
-
ofUsername
public static FieldRoleMapperExpression ofUsername(Object... values)
-
ofGroups
public static FieldRoleMapperExpression ofGroups(Object... values)
-
ofDN
public static FieldRoleMapperExpression ofDN(Object... values)
-
ofMetadata
public static FieldRoleMapperExpression ofMetadata(String key, Object... values)
-
ofKeyValues
public static FieldRoleMapperExpression ofKeyValues(String key, Object... values)
-
-