public class ExternalUserService extends java.lang.Object implements IInCoreExternalUser
Constructor and Description |
---|
ExternalUserService(BmContext context,
ItemValue<Domain> domain,
Container externalUserContainer) |
Modifier and Type | Method and Description |
---|---|
ItemValue<ExternalUser> |
byExtId(java.lang.String extId)
Fetch a
ExternalUser by its external id. |
void |
create(java.lang.String uid,
ExternalUser eu)
Creates a new
ExternalUser . |
void |
createWithExtId(java.lang.String uid,
java.lang.String extId,
ExternalUser externalUser)
Creates a new
ExternalUser with the given uid. |
void |
delete(java.lang.String externalUserUid)
Delete an external user.
|
ItemValue<ExternalUser> |
getComplete(java.lang.String uid)
Fetch a
ExternalUser by its uid. |
java.util.List<ItemValue<Group>> |
memberOf(java.lang.String uid)
Returns the list of
Group
net.bluemind.core.container.api.ItemValue the external user is member
of. |
java.util.List<java.lang.String> |
memberOfGroups(java.lang.String uid)
Retrieves a list of all
Group uids the
external user is member of. |
void |
update(java.lang.String uid,
ExternalUser externalUser)
Modify an existing external user.
|
ValidationResult |
validate(java.lang.String[] externalUserUids)
Check that every uid corresponds to an existing group member
|
public void create(java.lang.String uid, ExternalUser eu) throws ServerFault
IExternalUser
ExternalUser
.create
in interface IExternalUser
uid
- ExternalUser
's unique ideu
- ExternalUser
ServerFault
- standard error objectpublic void createWithExtId(java.lang.String uid, java.lang.String extId, ExternalUser externalUser) throws ServerFault
IExternalUser
ExternalUser
with the given uid. Associates an external
id to the ExternalUser
.createWithExtId
in interface IExternalUser
uid
- the ExternalUser
's unique idextId
- an external id. Usually used to link the
ExternalUser
to an external systemexternalUser
- ExternalUser
ServerFault
- standard error objectpublic void update(java.lang.String uid, ExternalUser externalUser) throws ServerFault
IExternalUser
update
in interface IExternalUser
uid
- ExternalUser
's unique idexternalUser
- updated ExternalUser
ServerFault
- standard error objectpublic void delete(java.lang.String externalUserUid) throws ServerFault
IExternalUser
delete
in interface IExternalUser
externalUserUid
- ExternalUser
's unique idServerFault
public ItemValue<ExternalUser> getComplete(java.lang.String uid) throws ServerFault
IExternalUser
ExternalUser
by its uid.getComplete
in interface IExternalUser
uid
- ExternalUser
's unique idExternalUser
net.bluemind.core.container.api.ItemValue
, or null if the
ExternalUser
does not existServerFault
- standard error objectpublic ValidationResult validate(java.lang.String[] externalUserUids) throws ServerFault
IInCoreGroupMember
validate
in interface IInCoreGroupMember
ServerFault
public java.util.List<ItemValue<Group>> memberOf(java.lang.String uid) throws ServerFault
IExternalUser
Group
net.bluemind.core.container.api.ItemValue
the external user is member
of.memberOf
in interface IExternalUser
uid
- the ExternalUser
's unique idGroup
net.bluemind.core.container.api.ItemValue
ServerFault
- standard error objectpublic java.util.List<java.lang.String> memberOfGroups(java.lang.String uid) throws ServerFault
IExternalUser
Group
uids the
external user is member of.memberOfGroups
in interface IExternalUser
uid
- the ExternalUser
's unique idGroup
uidsServerFault
- standard error objectpublic ItemValue<ExternalUser> byExtId(java.lang.String extId) throws ServerFault
IExternalUser
ExternalUser
by its external id.byExtId
in interface IExternalUser
extId
- the external user's external id. Usually used to link the
ExternalUser
to an external systemExternalUser
net.bluemind.core.container.api.ItemValue
, or null if the
ExternalUser
does not existServerFault
- standard error object (unchecked exception)Copyright © 2021. All Rights Reserved.