public class ClaimsMgtUtil extends Object
Constructor and Description |
---|
ClaimsMgtUtil() |
Modifier and Type | Method and Description |
---|---|
static String |
getAdminUserNameFromTenantId(org.wso2.carbon.user.core.service.RealmService realmService,
int tenantId)
Method to get the name of the admin user given the tenant id
|
static String |
getClaimfromUserStoreManager(org.wso2.carbon.user.core.service.RealmService realmService,
int tenantId,
String claim)
Get the claims from the user store manager
|
static String |
getFirstName(org.wso2.carbon.user.core.service.RealmService realmService,
int tenantId)
gets first name
|
static String |
getFirstNamefromUserStoreManager(org.wso2.carbon.user.core.service.RealmService realmService,
int tenantId)
Gets first name from the user store manager
|
static String |
getLastName(org.wso2.carbon.user.core.service.RealmService realmService,
int tenantId)
gets last name
|
static String |
getLastNamefromUserStoreManager(org.wso2.carbon.user.core.service.RealmService realmService,
int tenantId)
Gets last name from the user store manager
|
static String[] |
getNames(org.wso2.carbon.user.core.service.RealmService realmService,
int tenantId)
Gets the first name of a tenant admin to address him/her in the
notifications
|
static String[] |
getNamesfromFullName(org.wso2.carbon.user.core.service.RealmService realmService,
String fullName)
Let's split the givenname into two.
|
public static String getFirstName(org.wso2.carbon.user.core.service.RealmService realmService, int tenantId) throws Exception
tenant
- tenanttenantId
- tenant idException
- if error in getting the first namepublic static String getLastName(org.wso2.carbon.user.core.service.RealmService realmService, int tenantId) throws Exception
tenant
- tenanttenantId
- tenant idException
- if error in getting the last namepublic static String[] getNames(org.wso2.carbon.user.core.service.RealmService realmService, int tenantId) throws Exception
tenant
- tenanttenantId
- tenant IdException
- if unable to retrieve the admin namepublic static String getAdminUserNameFromTenantId(org.wso2.carbon.user.core.service.RealmService realmService, int tenantId) throws Exception
tenantId
- tenant idException
- UserStoreExceptionpublic static String[] getNamesfromFullName(org.wso2.carbon.user.core.service.RealmService realmService, String fullName)
fullName
- full name of the tenant adminpublic static String getClaimfromUserStoreManager(org.wso2.carbon.user.core.service.RealmService realmService, int tenantId, String claim) throws org.wso2.carbon.user.core.UserStoreException
tenant
- tenant informationtenantId
- tenantIdclaim
- claim nameorg.wso2.carbon.user.core.UserStoreException
- exception in getting the user store managerpublic static String getFirstNamefromUserStoreManager(org.wso2.carbon.user.core.service.RealmService realmService, int tenantId) throws org.wso2.carbon.user.core.UserStoreException
tenant
- tenanttenantId
- tenant idorg.wso2.carbon.user.core.UserStoreException
- , if error in getting the claim GIVEN_NAMEpublic static String getLastNamefromUserStoreManager(org.wso2.carbon.user.core.service.RealmService realmService, int tenantId) throws org.wso2.carbon.user.core.UserStoreException
tenant
- tenanttenantId
- tenant idorg.wso2.carbon.user.core.UserStoreException
- , if error in getting the claim SURNAMECopyright © 2020 WSO2. All rights reserved.