Class RoleTemplateQuery.Builder
java.lang.Object
co.elastic.clients.util.ObjectBuilderBase
co.elastic.clients.util.WithJsonObjectBuilderBase<RoleTemplateQuery.Builder>
co.elastic.clients.elasticsearch.security.RoleTemplateQuery.Builder
- All Implemented Interfaces:
WithJson<RoleTemplateQuery.Builder>
,ObjectBuilder<RoleTemplateQuery>
- Enclosing class:
- RoleTemplateQuery
public static class RoleTemplateQuery.Builder
extends WithJsonObjectBuilderBase<RoleTemplateQuery.Builder>
implements ObjectBuilder<RoleTemplateQuery>
Builder for
RoleTemplateQuery
.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()
Builds aRoleTemplateQuery
.protected RoleTemplateQuery.Builder
self()
template
(RoleTemplateScript value) When you create a role, you can specify a query that defines the document level security permissions.When you create a role, you can specify a query that defines the document level security permissions.Methods inherited from class co.elastic.clients.util.WithJsonObjectBuilderBase
withJson
Methods inherited from class co.elastic.clients.util.ObjectBuilderBase
_checkSingleUse, _listAdd, _listAddAll, _mapPut, _mapPutAll
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
template
When you create a role, you can specify a query that defines the document level security permissions. You can optionally use Mustache templates in the role query to insert the username of the current authenticated user into the role. Like other places in Elasticsearch that support templating or scripting, you can specify inline, stored, or file-based templates and define custom parameters. You access the details for the current authenticated user through the _user parameter.API name:
template
-
template
public final RoleTemplateQuery.Builder template(Function<RoleTemplateScript.Builder, ObjectBuilder<RoleTemplateScript>> fn) When you create a role, you can specify a query that defines the document level security permissions. You can optionally use Mustache templates in the role query to insert the username of the current authenticated user into the role. Like other places in Elasticsearch that support templating or scripting, you can specify inline, stored, or file-based templates and define custom parameters. You access the details for the current authenticated user through the _user parameter.API name:
template
-
self
- Specified by:
self
in classWithJsonObjectBuilderBase<RoleTemplateQuery.Builder>
-
build
Builds aRoleTemplateQuery
.- Specified by:
build
in interfaceObjectBuilder<RoleTemplateQuery>
- Throws:
NullPointerException
- if some of the required fields are null.
-