クラス LdapAuthority

java.lang.ObjectSE
org.springframework.security.ldap.userdetails.LdapAuthority
実装されたすべてのインターフェース:
SerializableSEGrantedAuthority

public class LdapAuthority extends ObjectSE implements GrantedAuthority
LDAP エントリの少なくとも DN とロール名を含むが、LDAP 権限の検索中にフェッチされる他の必要な属性も含むことができる権限。
関連事項:
  • コンストラクターの詳細

    • LdapAuthority

      public LdapAuthority(StringSE role, StringSE dn)
      ロールと DN はあるが、他の属性はない LdapAuthority を構築します
      パラメーター:
      role -
      dn -
    • LdapAuthority

      public LdapAuthority(StringSE role, StringSE dn, MapSE<StringSE,ListSE<StringSE>> attributes)
      指定されたロール、DN、その他の LDAP 属性を使用して LdapAuthority を構築します
      パラメーター:
      role -
      dn -
      attributes -
  • メソッドの詳細

    • getAttributes

      public MapSE<StringSE,ListSE<StringSE>> getAttributes()
      LDAP 属性を返します
      戻り値:
      LDAP 属性、マップは null にすることができます
    • getDn

      public StringSE getDn()
      この LDAP 権限の DN を返します
      戻り値:
    • getAttributeValues

      public ListSE<StringSE> getAttributeValues(StringSE name)
      特定の属性の値を返します
      パラメーター:
      name - 属性名
      戻り値:
      文字列配列。null になることはありませんが、長さがゼロの場合があります。
    • getFirstAttributeValue

      public StringSE getFirstAttributeValue(StringSE name)
      指定された属性の最初の属性値を返します
      パラメーター:
      name -
      戻り値:
      指定された属性の最初の属性値は null の場合があります
    • getAuthority

      public StringSE getAuthority()
      インターフェースからコピーされた説明: GrantedAuthority
      GrantedAuthority を String として表現でき、String が AccessDecisionManager(またはデリゲート)によるアクセス制御の決定に依存する精度で十分である場合、このメソッドはそのような String を返す必要があります。

      GrantedAuthority を String として十分な精度で表現できない場合、null を返す必要があります。null を返すには、GrantedAuthority 実装を具体的にサポートするために AccessDecisionManager (またはデリゲート)が必要になるため、実際に必要でない限り、null を返すことは避けてください。

      次で指定:
      インターフェース GrantedAuthoritygetAuthority 
      戻り値:
      付与された権限の表現(または付与された権限が十分な精度で String として表現できない場合は null)。
    • equals

      public boolean equals(ObjectSE obj)
      getAuthority()getDn() の値に基づいて LdapAuthority を比較します。
      オーバーライド:
      クラス ObjectSEequalsSE 
    • hashCode

      public int hashCode()
      オーバーライド:
      クラス ObjectSEhashCode 
    • toString

      public StringSE toString()
      オーバーライド:
      クラス ObjectSEtoString