public class AdminFacility extends Facility
Facility
for handling admin issues, e.g. creating users, groups,
etc.Modifier and Type | Method and Description |
---|---|
ExperimenterData |
createExperimenter(SecurityContext ctx,
ExperimenterData exp,
String username,
String password,
List<GroupData> groups,
boolean isAdmin,
boolean isGroupOwner)
Creates an experimenter and returns it.
|
GroupData |
createGroup(SecurityContext ctx,
GroupData groupData,
ExperimenterData owner,
int permissions)
Creates a group and returns it.
|
ExperimenterData |
lookupExperimenter(SecurityContext ctx,
String name)
Returns the experimenter corresponding to the passed name or
null . |
GroupData |
lookupGroup(SecurityContext ctx,
String name)
Returns the group corresponding to the passed name or
null . |
addPropertyChangeListener, clear, firePropertyChanged, firePropertyChanged, getFacility, logDebug, logError, logInfo, logWarn, removePropertyChangeListener
public GroupData createGroup(SecurityContext ctx, GroupData groupData, ExperimenterData owner, int permissions) throws DSOutOfServiceException, DSAccessException
ctx
- The security context.groupData
- Host information about the group to create.owner
- The owner of the group.permissions
- The group's permissions.DSOutOfServiceException
- If the connection is broken, or not logged inDSAccessException
- If an error occurred while trying to retrieve data from OMERO
service.public ExperimenterData createExperimenter(SecurityContext ctx, ExperimenterData exp, String username, String password, List<GroupData> groups, boolean isAdmin, boolean isGroupOwner) throws DSOutOfServiceException, DSAccessException
ctx
- The security context.exp
- The experimenter to create.username
- The user name to use.password
- The password to use.groups
- The groups to add the user to.isAdmin
- Pass true
if the user is an administrator,
false
otherwise.isGroupOwner
- Pass true
if the user is a group owner,
false
otherwise.DSOutOfServiceException
- If the connection is broken, or not logged inDSAccessException
- If an error occurred while trying to retrieve data from OMERO
service.public GroupData lookupGroup(SecurityContext ctx, String name) throws DSOutOfServiceException, DSAccessException
null
.ctx
- The security context.name
- The name of the group.DSOutOfServiceException
- If the connection is broken, or not logged inDSAccessException
- If an error occurred while trying to retrieve data from OMERO
service.public ExperimenterData lookupExperimenter(SecurityContext ctx, String name) throws DSOutOfServiceException, DSAccessException
null
.ctx
- The security context.name
- The name of the experimenter.DSOutOfServiceException
- If the connection is broken, or not logged inDSAccessException
- If an error occurred while trying to retrieve data from OMERO
service.
Version: 5.3.3-ice35-b63
Copyright © 2017 The University of Dundee & Open Microscopy Environment. All Rights Reserved.