Record Class LoginActingContributor.ActingLogin
java.lang.Object
java.lang.Record
io.leandev.appfuse.security.auth.LoginActingContributor.ActingLogin
- Record Components:
effectivePrincipal- 以合併後權限建立的 UserDetails(需保留原 subject)grantors- 授權人 stable subject 清單(寫入grantorsclaim)roles- 合併後的直接角色名(ROLE_前綴;ADR-024——角色階層展開是 wire 契約,由消費端 wire 組裝層執行,本結果不預先展開)- 合併後的權限名(供登入回應輸出)
- Enclosing interface:
LoginActingContributor
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of theauthoritiesrecord component.org.springframework.security.core.userdetails.UserDetailsReturns the value of theeffectivePrincipalrecord component.final booleanIndicates whether some other object is "equal to" this one.grantors()Returns the value of thegrantorsrecord component.final inthashCode()Returns a hash code value for this object.roles()Returns the value of therolesrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
ActingLogin
public ActingLogin(org.springframework.security.core.userdetails.UserDetails effectivePrincipal, List<String> grantors, List<String> roles, List<String> authorities) Creates an instance of aActingLoginrecord class.- Parameters:
effectivePrincipal- the value for theeffectivePrincipalrecord componentgrantors- the value for thegrantorsrecord componentroles- the value for therolesrecord componentauthorities- the value for theauthoritiesrecord component
-
-
Method Details
-
toString
-
hashCode
-
equals
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 withObjects::equals(Object,Object). -
effectivePrincipal
public org.springframework.security.core.userdetails.UserDetails effectivePrincipal()Returns the value of theeffectivePrincipalrecord component.- Returns:
- the value of the
effectivePrincipalrecord component
-
grantors
-
roles
-
authorities
Returns the value of theauthoritiesrecord component.- Returns:
- the value of the
authoritiesrecord component
-