Class PolicyCreateRequest
java.lang.Object
org.apache.gravitino.dto.requests.PolicyCreateRequest
- All Implemented Interfaces:
RESTMessage,RESTRequest
Represents a request to create a policy.
-
Constructor Summary
ConstructorsConstructorDescriptionPolicyCreateRequest(String name, String type, String comment, boolean enabled, PolicyContentDTO content) Creates a new PolicyCreateRequest. -
Method Summary
-
Constructor Details
-
PolicyCreateRequest
public PolicyCreateRequest(String name, String type, String comment, boolean enabled, PolicyContentDTO content) Creates a new PolicyCreateRequest.- Parameters:
name- The name of the policy.comment- The comment of the policy.type- The type of the policy.enabled- Whether the policy is enabled.content- The content of the policy.
-
-
Method Details
-
validate
Validates the request.- Specified by:
validatein interfaceRESTMessage- Throws:
IllegalArgumentException- If the request is invalid, this exception is thrown.
-