Class PutPrivilegesResponse

java.lang.Object
org.elasticsearch.client.security.PutPrivilegesResponse

public final class PutPrivilegesResponse
extends java.lang.Object
Response when creating/updating one or more application privileges to the security index.
  • Constructor Summary

    Constructors 
    Constructor Description
    PutPrivilegesResponse​(java.util.Map<java.lang.String,​java.util.Map<java.lang.String,​java.lang.Boolean>> applicationPrivilegesCreatedOrUpdated)  
  • Method Summary

    Modifier and Type Method Description
    static PutPrivilegesResponse fromXContent​(org.elasticsearch.common.xcontent.XContentParser parser)  
    boolean wasCreated​(java.lang.String applicationName, java.lang.String privilegeName)
    Get response status for the request to create or update application privileges.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • PutPrivilegesResponse

      public PutPrivilegesResponse​(java.util.Map<java.lang.String,​java.util.Map<java.lang.String,​java.lang.Boolean>> applicationPrivilegesCreatedOrUpdated)
  • Method Details

    • wasCreated

      public boolean wasCreated​(java.lang.String applicationName, java.lang.String privilegeName)
      Get response status for the request to create or update application privileges.
      Parameters:
      applicationName - application name as specified in the request
      privilegeName - privilege name as specified in the request
      Returns:
      true if the privilege was created, false if the privilege was updated
      Throws:
      java.lang.IllegalArgumentException - thrown for unknown application name or privilege name.
    • fromXContent

      public static PutPrivilegesResponse fromXContent​(org.elasticsearch.common.xcontent.XContentParser parser) throws java.io.IOException
      Throws:
      java.io.IOException