public interface UserOfGroupDao
UserOfGroup
Modifier and Type | Field and Description |
---|---|
static int |
TRANSFORM_NONE
This constant is used as a transformation flag; entities can be converted automatically into
value objects or other types, different methods in a class implementing this interface
support this feature: look for an
int parameter called transform . |
Modifier and Type | Method and Description |
---|---|
Collection<UserOfGroup> |
create(Collection<UserOfGroup> entities)
Creates a new instance of com.communote.server.persistence.user.group.UserOfGroup and adds
from the passed in
entities collection |
Collection<?> |
create(int transform,
Collection<UserOfGroup> entities)
Does the same thing as
create(com.communote.server.model.user.group.UserOfGroup)
with an additional flag called transform . |
Object |
create(int transform,
UserOfGroup userOfGroup)
Does the same thing as
create(com.communote.server.model.user.group.UserOfGroup)
with an additional flag called transform . |
UserOfGroup |
create(UserOfGroup userOfGroup)
Creates an instance of com.communote.server.persistence.user.group.UserOfGroup and adds it to
the persistent store.
|
void |
evict(UserOfGroup entity)
Evicts (removes) the entity from the hibernate cache
|
UserOfGroup |
findByUserIdGroupId(Long userId,
Long groupId)
Returns a UserOfGroup entity identified by the userId and groupId.
|
Collection<UserOfGroup> |
getUserOfGroupEntities(UserOfGroupModificationType modificationType)
Returns the UserOfGroup entities that have the provided UserOfGroupModificationType.
|
Collection<Long> |
getUsersOfGroup(Long groupId)
Returns for a given group all users participating in the UserOfGroup association.
|
boolean |
isUserOfGroup(Long userId,
Long groupId)
Tests wether there is an association between the user and the group.
|
Object |
load(int transform,
Long id)
Does the same thing as
load(Long) with an additional flag called
transform . |
UserOfGroup |
load(Long id)
Loads an instance of com.communote.server.persistence.user.group.UserOfGroup from the
persistent store.
|
Collection<UserOfGroup> |
loadAll()
Loads all entities of type
UserOfGroup . |
Collection<?> |
loadAll(int transform)
Does the same thing as
loadAll() with an additional flag called
transform . |
void |
remove(Collection<UserOfGroup> entities)
Removes all entities in the given
entities |
void |
remove(Long id)
Removes the instance of com.communote.server.persistence.user.group.UserOfGroup having the
given
identifier from the persistent store. |
void |
remove(UserOfGroup userOfGroup)
Removes the instance of com.communote.server.persistence.user.group.UserOfGroup from the
persistent store.
|
void |
update(Collection<UserOfGroup> entities)
Updates all instances in the
entities collection in the persistent store. |
void |
update(UserOfGroup userOfGroup)
Updates the
userOfGroup instance in the persistent store. |
static final int TRANSFORM_NONE
int
parameter called transform
.
This specific flag denotes no transformation will occur.UserOfGroup create(UserOfGroup userOfGroup)
Object create(int transform, UserOfGroup userOfGroup)
Does the same thing as create(com.communote.server.model.user.group.UserOfGroup)
with an additional flag called transform
. If this flag is set to
TRANSFORM_NONE
then the returned entity will NOT be
transformed. If this flag is any of the other constants defined here then the result
WILL BE passed through an operation which can optionally transform the
entity (into a value object for example). By default, transformation does not occur.
Collection<?> create(int transform, Collection<UserOfGroup> entities)
Does the same thing as create(com.communote.server.model.user.group.UserOfGroup)
with an additional flag called transform
. If this flag is set to
TRANSFORM_NONE
then the returned entity will NOT be
transformed. If this flag is any of the other constants defined here then the result
WILL BE passed through an operation which can optionally transform the
entities (into value objects for example). By default, transformation does not occur.
Collection<UserOfGroup> create(Collection<UserOfGroup> entities)
entities
collectionentities
- the collection of com.communote.server.persistence.user.group.UserOfGroup
instances to create.void evict(UserOfGroup entity)
entity
- the entity to evictUserOfGroup findByUserIdGroupId(Long userId, Long groupId)
Returns a UserOfGroup entity identified by the userId and groupId.
Collection<UserOfGroup> getUserOfGroupEntities(UserOfGroupModificationType modificationType)
Returns the UserOfGroup entities that have the provided UserOfGroupModificationType. If the modification type is null the entities having null as modification type value are retrieved.
Collection<Long> getUsersOfGroup(Long groupId)
Returns for a given group all users participating in the UserOfGroup association. The return value will be a collection of user IDs.
boolean isUserOfGroup(Long userId, Long groupId)
Tests wether there is an association between the user and the group.
Object load(int transform, Long id)
Does the same thing as load(Long)
with an additional flag called
transform
. If this flag is set to TRANSFORM_NONE
then the returned
entity will NOT be transformed. If this flag is any of the other constants
defined in this class then the result WILL BE passed through an operation
which can optionally transform the entity (into a value object for example). By default,
transformation does not occur.
id
- the identifier of the entity to load.UserOfGroup load(Long id)
Collection<UserOfGroup> loadAll()
UserOfGroup
.Collection<?> loadAll(int transform)
Does the same thing as loadAll()
with an additional flag called
transform
. If this flag is set to TRANSFORM_NONE
then the returned
entity will NOT be transformed. If this flag is any of the other constants
defined here then the result WILL BE passed through an operation which can
optionally transform the entity (into a value object for example). By default, transformation
does not occur.
transform
- the flag indicating what transformation to use.void remove(UserOfGroup userOfGroup)
void remove(Collection<UserOfGroup> entities)
entities collection.
void remove(Long id)
identifier
from the persistent store.void update(UserOfGroup userOfGroup)
userOfGroup
instance in the persistent store.void update(Collection<UserOfGroup> entities)
entities
collection in the persistent store.Copyright © 2019 Communote team. All rights reserved.