Class RoleTemplateQuery

java.lang.Object
co.elastic.clients.elasticsearch.security.RoleTemplateQuery
All Implemented Interfaces:
JsonpSerializable

@JsonpDeserializable public class RoleTemplateQuery extends Object implements JsonpSerializable
See Also:
  • Field Details

  • Method Details

    • of

    • template

      @Nullable public final RoleTemplateScript 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

    • serialize

      public void serialize(jakarta.json.stream.JsonGenerator generator, JsonpMapper mapper)
      Serialize this object to JSON.
      Specified by:
      serialize in interface JsonpSerializable
    • serializeInternal

      protected void serializeInternal(jakarta.json.stream.JsonGenerator generator, JsonpMapper mapper)
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • setupRoleTemplateQueryDeserializer

      protected static void setupRoleTemplateQueryDeserializer(ObjectDeserializer<RoleTemplateQuery.Builder> op)