Record Class Permission.Scope

java.lang.Object
java.lang.Record
zeroecho.pki.server.Permission.Scope
Record Components:
realmId - realm identity
authorityId - explicit logical authority when applicable
issuerId - explicit issuer generation when applicable
profileId - explicit profile when applicable
responderId - explicit OCSP responder when applicable
Enclosing class:
Permission

public static record Permission.Scope(RealmId realmId, Optional<PkiId> authorityId, Optional<PkiId> issuerId, Optional<String> profileId, Optional<String> responderId) extends Record
Canonical resource scope supplied independently of object contents.
  • Constructor Details

    • Scope

      public Scope(RealmId realmId, Optional<PkiId> authorityId, Optional<PkiId> issuerId, Optional<String> profileId, Optional<String> responderId)
      Validates the exact finite scope.
    • Scope

      public Scope(RealmId realmId, Optional<PkiId> authorityId, Optional<PkiId> issuerId, Optional<String> profileId)
      Creates a scope without an OCSP responder dimension.
      Parameters:
      realmId - realm identity
      authorityId - explicit logical authority when applicable
      issuerId - explicit issuer generation when applicable
      profileId - explicit profile when applicable
  • Method Details

    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with Objects::equals(Object,Object).
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • realmId

      public RealmId realmId()
      Returns the value of the realmId record component.
      Returns:
      the value of the realmId record component
    • authorityId

      public Optional<PkiId> authorityId()
      Returns the value of the authorityId record component.
      Returns:
      the value of the authorityId record component
    • issuerId

      public Optional<PkiId> issuerId()
      Returns the value of the issuerId record component.
      Returns:
      the value of the issuerId record component
    • profileId

      public Optional<String> profileId()
      Returns the value of the profileId record component.
      Returns:
      the value of the profileId record component
    • responderId

      public Optional<String> responderId()
      Returns the value of the responderId record component.
      Returns:
      the value of the responderId record component