public interface Group extends Principal
Modifier and Type | Method and Description |
---|---|
boolean |
addUser(User user)
Adds the given
user to this group. |
void |
addUsers(User[] users)
Adds the given
users to this group. |
String |
getEmail()
Gets email address of the group.
|
String |
getName()
Get name of the group
|
long |
getProjectID() |
User[] |
getUsers()
Get all users in this group
|
boolean |
isAdmin()
Is this an admin group.
|
boolean |
isEveryone()
Is this the everyone group
|
boolean |
isExternal() |
boolean |
isMember(User user) |
boolean |
removeUser(User user)
Remove user from group
|
void |
removeUsers(User[] users)
Remove the given
users from this group. |
void |
setAdmin(boolean admin)
Sets or clears the admin flag of this group.
|
void |
setEmail(String email)
Sets the email address of the group
|
void |
setName(String name)
Sets group's name.
|
compareTo
String getName()
void setName(String name)
name
- new name.IllegalArgumentException
- if a group with this name already exists.User[] getUsers()
boolean addUser(User user) throws IllegalArgumentException
user
to this group.user
- user to add.true
if the user was added, false
if the user is already member if this group.IllegalArgumentException
- if the user has no access rights
to the project.void addUsers(User[] users) throws IllegalArgumentException
users
to this group.users
- users to add.IllegalArgumentException
- if at least one user has no access rights
to the project.boolean removeUser(User user)
user
- the user to removevoid removeUsers(User[] users)
users
from this group.users
- to removeboolean isAdmin()
true
if this is an administrator group.void setAdmin(boolean admin)
admin
- admin flag.boolean isEveryone()
boolean isExternal()
boolean isMember(User user)
long getProjectID()
@Nullable String getEmail()
Copyright © 2014 e-Spirit AG. All Rights Reserved. Build 5.0_BETA.500