Class ThingAclValidator

  • All Implemented Interfaces:
    org.eclipse.ditto.model.base.common.Validator

    @Deprecated
    @Immutable
    public final class ThingAclValidator
    extends Object
    implements org.eclipse.ditto.model.base.common.Validator
    Deprecated.
    AccessControlLists belong to deprecated API version 1. Use API version 2 with policies instead.
    Instances of this class can be used to validate a specified AccessControlList with regard to the rules of a valid Thing.
    • Method Detail

      • newInstance

        public static ThingAclValidator newInstance​(AccessControlList accessControlList)
        Deprecated.
        Creates a new ThingAclValidator instance.
        Parameters:
        accessControlList - the ACL to be validated.
        Returns:
        a new ThingAclValidator object.
        Throws:
        NullPointerException - if any argument is null.
      • isValid

        public boolean isValid()
        Deprecated.
        Validates the AccessControlList which was provided to the static factory method of this class. Validation ensures that the ACL contains at least one Authorization Subject which has the permissions Permission.READ, Permission.WRITE and Permission.ADMINISTRATE.
        Specified by:
        isValid in interface org.eclipse.ditto.model.base.common.Validator
        Returns:
        false if the validated ACL does not contain at least one Authorization Subject with the minimum required permissions or else true.
      • getReason

        public Optional<String> getReason()
        Deprecated.
        Specified by:
        getReason in interface org.eclipse.ditto.model.base.common.Validator