public class WindowsPrincipal extends Object implements Principal, Serializable
| Constructor and Description |
|---|
WindowsPrincipal(IWindowsIdentity windowsIdentity)
A windows principal.
|
WindowsPrincipal(IWindowsIdentity windowsIdentity,
PrincipalFormat principalFormat,
PrincipalFormat roleFormat)
A windows principal.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object o) |
Map<String,WindowsAccount> |
getGroups()
Windows groups that the user is a member of.
|
IWindowsIdentity |
getIdentity()
Underlying identity.
|
String |
getName()
Fully qualified name.
|
String |
getRolesString()
Get an array of roles as a string.
|
byte[] |
getSid()
Byte representation of the SID.
|
String |
getSidString()
String representation of the SID.
|
int |
hashCode() |
boolean |
hasRole(String role)
Checks whether the principal has a given role.
|
String |
toString() |
public WindowsPrincipal(IWindowsIdentity windowsIdentity)
windowsIdentity - Windows identity.public WindowsPrincipal(IWindowsIdentity windowsIdentity, PrincipalFormat principalFormat, PrincipalFormat roleFormat)
windowsIdentity - Windows identity.principalFormat - Principal format.roleFormat - Role format.public byte[] getSid()
public String getSidString()
public Map<String,WindowsAccount> getGroups()
public String getRolesString()
public boolean hasRole(String role)
role - Role name.public String getName()
public IWindowsIdentity getIdentity()
public String toString()
public boolean equals(Object o)
Copyright © 2010–2020 com.github.waffle. All rights reserved.