Liferay 7.0-ce-b4

com.liferay.portal.service.persistence
Interface UserGroupRolePersistence

All Superinterfaces:
BasePersistence<UserGroupRole>

@ProviderType
public interface UserGroupRolePersistence
extends BasePersistence<UserGroupRole>

The persistence interface for the user group role service.

Caching information and settings can be found in portal.properties

See Also:
UserGroupRolePersistenceImpl, UserGroupRoleUtil

Method Summary
 void cacheResult(List<UserGroupRole> userGroupRoles)
          Caches the user group roles in the entity cache if it is enabled.
 void cacheResult(UserGroupRole userGroupRole)
          Caches the user group role in the entity cache if it is enabled.
 int countAll()
          Returns the number of user group roles.
 int countByG_R(long groupId, long roleId)
          Returns the number of user group roles where groupId = ? and roleId = ?.
 int countByGroupId(long groupId)
          Returns the number of user group roles where groupId = ?.
 int countByRoleId(long roleId)
          Returns the number of user group roles where roleId = ?.
 int countByU_G(long userId, long groupId)
          Returns the number of user group roles where userId = ? and groupId = ?.
 int countByUserId(long userId)
          Returns the number of user group roles where userId = ?.
 UserGroupRole create(UserGroupRolePK userGroupRolePK)
          Creates a new user group role with the primary key.
 UserGroupRole fetchByG_R_First(long groupId, long roleId, OrderByComparator<UserGroupRole> orderByComparator)
          Returns the first user group role in the ordered set where groupId = ? and roleId = ?.
 UserGroupRole fetchByG_R_Last(long groupId, long roleId, OrderByComparator<UserGroupRole> orderByComparator)
          Returns the last user group role in the ordered set where groupId = ? and roleId = ?.
 UserGroupRole fetchByGroupId_First(long groupId, OrderByComparator<UserGroupRole> orderByComparator)
          Returns the first user group role in the ordered set where groupId = ?.
 UserGroupRole fetchByGroupId_Last(long groupId, OrderByComparator<UserGroupRole> orderByComparator)
          Returns the last user group role in the ordered set where groupId = ?.
 UserGroupRole fetchByPrimaryKey(UserGroupRolePK userGroupRolePK)
          Returns the user group role with the primary key or returns null if it could not be found.
 Map<Serializable,UserGroupRole> fetchByPrimaryKeys(Set<Serializable> primaryKeys)
           
 UserGroupRole fetchByRoleId_First(long roleId, OrderByComparator<UserGroupRole> orderByComparator)
          Returns the first user group role in the ordered set where roleId = ?.
 UserGroupRole fetchByRoleId_Last(long roleId, OrderByComparator<UserGroupRole> orderByComparator)
          Returns the last user group role in the ordered set where roleId = ?.
 UserGroupRole fetchByU_G_First(long userId, long groupId, OrderByComparator<UserGroupRole> orderByComparator)
          Returns the first user group role in the ordered set where userId = ? and groupId = ?.
 UserGroupRole fetchByU_G_Last(long userId, long groupId, OrderByComparator<UserGroupRole> orderByComparator)
          Returns the last user group role in the ordered set where userId = ? and groupId = ?.
 UserGroupRole fetchByUserId_First(long userId, OrderByComparator<UserGroupRole> orderByComparator)
          Returns the first user group role in the ordered set where userId = ?.
 UserGroupRole fetchByUserId_Last(long userId, OrderByComparator<UserGroupRole> orderByComparator)
          Returns the last user group role in the ordered set where userId = ?.
 List<UserGroupRole> findAll()
          Returns all the user group roles.
 List<UserGroupRole> findAll(int start, int end)
          Returns a range of all the user group roles.
 List<UserGroupRole> findAll(int start, int end, OrderByComparator<UserGroupRole> orderByComparator)
          Returns an ordered range of all the user group roles.
 List<UserGroupRole> findAll(int start, int end, OrderByComparator<UserGroupRole> orderByComparator, boolean retrieveFromCache)
          Returns an ordered range of all the user group roles.
 UserGroupRole findByG_R_First(long groupId, long roleId, OrderByComparator<UserGroupRole> orderByComparator)
          Returns the first user group role in the ordered set where groupId = ? and roleId = ?.
 UserGroupRole findByG_R_Last(long groupId, long roleId, OrderByComparator<UserGroupRole> orderByComparator)
          Returns the last user group role in the ordered set where groupId = ? and roleId = ?.
 UserGroupRole[] findByG_R_PrevAndNext(UserGroupRolePK userGroupRolePK, long groupId, long roleId, OrderByComparator<UserGroupRole> orderByComparator)
          Returns the user group roles before and after the current user group role in the ordered set where groupId = ? and roleId = ?.
 List<UserGroupRole> findByG_R(long groupId, long roleId)
          Returns all the user group roles where groupId = ? and roleId = ?.
 List<UserGroupRole> findByG_R(long groupId, long roleId, int start, int end)
          Returns a range of all the user group roles where groupId = ? and roleId = ?.
 List<UserGroupRole> findByG_R(long groupId, long roleId, int start, int end, OrderByComparator<UserGroupRole> orderByComparator)
          Returns an ordered range of all the user group roles where groupId = ? and roleId = ?.
 List<UserGroupRole> findByG_R(long groupId, long roleId, int start, int end, OrderByComparator<UserGroupRole> orderByComparator, boolean retrieveFromCache)
          Returns an ordered range of all the user group roles where groupId = ? and roleId = ?.
 UserGroupRole findByGroupId_First(long groupId, OrderByComparator<UserGroupRole> orderByComparator)
          Returns the first user group role in the ordered set where groupId = ?.
 UserGroupRole findByGroupId_Last(long groupId, OrderByComparator<UserGroupRole> orderByComparator)
          Returns the last user group role in the ordered set where groupId = ?.
 UserGroupRole[] findByGroupId_PrevAndNext(UserGroupRolePK userGroupRolePK, long groupId, OrderByComparator<UserGroupRole> orderByComparator)
          Returns the user group roles before and after the current user group role in the ordered set where groupId = ?.
 List<UserGroupRole> findByGroupId(long groupId)
          Returns all the user group roles where groupId = ?.
 List<UserGroupRole> findByGroupId(long groupId, int start, int end)
          Returns a range of all the user group roles where groupId = ?.
 List<UserGroupRole> findByGroupId(long groupId, int start, int end, OrderByComparator<UserGroupRole> orderByComparator)
          Returns an ordered range of all the user group roles where groupId = ?.
 List<UserGroupRole> findByGroupId(long groupId, int start, int end, OrderByComparator<UserGroupRole> orderByComparator, boolean retrieveFromCache)
          Returns an ordered range of all the user group roles where groupId = ?.
 UserGroupRole findByPrimaryKey(UserGroupRolePK userGroupRolePK)
          Returns the user group role with the primary key or throws a NoSuchUserGroupRoleException if it could not be found.
 UserGroupRole findByRoleId_First(long roleId, OrderByComparator<UserGroupRole> orderByComparator)
          Returns the first user group role in the ordered set where roleId = ?.
 UserGroupRole findByRoleId_Last(long roleId, OrderByComparator<UserGroupRole> orderByComparator)
          Returns the last user group role in the ordered set where roleId = ?.
 UserGroupRole[] findByRoleId_PrevAndNext(UserGroupRolePK userGroupRolePK, long roleId, OrderByComparator<UserGroupRole> orderByComparator)
          Returns the user group roles before and after the current user group role in the ordered set where roleId = ?.
 List<UserGroupRole> findByRoleId(long roleId)
          Returns all the user group roles where roleId = ?.
 List<UserGroupRole> findByRoleId(long roleId, int start, int end)
          Returns a range of all the user group roles where roleId = ?.
 List<UserGroupRole> findByRoleId(long roleId, int start, int end, OrderByComparator<UserGroupRole> orderByComparator)
          Returns an ordered range of all the user group roles where roleId = ?.
 List<UserGroupRole> findByRoleId(long roleId, int start, int end, OrderByComparator<UserGroupRole> orderByComparator, boolean retrieveFromCache)
          Returns an ordered range of all the user group roles where roleId = ?.
 UserGroupRole findByU_G_First(long userId, long groupId, OrderByComparator<UserGroupRole> orderByComparator)
          Returns the first user group role in the ordered set where userId = ? and groupId = ?.
 UserGroupRole findByU_G_Last(long userId, long groupId, OrderByComparator<UserGroupRole> orderByComparator)
          Returns the last user group role in the ordered set where userId = ? and groupId = ?.
 UserGroupRole[] findByU_G_PrevAndNext(UserGroupRolePK userGroupRolePK, long userId, long groupId, OrderByComparator<UserGroupRole> orderByComparator)
          Returns the user group roles before and after the current user group role in the ordered set where userId = ? and groupId = ?.
 List<UserGroupRole> findByU_G(long userId, long groupId)
          Returns all the user group roles where userId = ? and groupId = ?.
 List<UserGroupRole> findByU_G(long userId, long groupId, int start, int end)
          Returns a range of all the user group roles where userId = ? and groupId = ?.
 List<UserGroupRole> findByU_G(long userId, long groupId, int start, int end, OrderByComparator<UserGroupRole> orderByComparator)
          Returns an ordered range of all the user group roles where userId = ? and groupId = ?.
 List<UserGroupRole> findByU_G(long userId, long groupId, int start, int end, OrderByComparator<UserGroupRole> orderByComparator, boolean retrieveFromCache)
          Returns an ordered range of all the user group roles where userId = ? and groupId = ?.
 UserGroupRole findByUserId_First(long userId, OrderByComparator<UserGroupRole> orderByComparator)
          Returns the first user group role in the ordered set where userId = ?.
 UserGroupRole findByUserId_Last(long userId, OrderByComparator<UserGroupRole> orderByComparator)
          Returns the last user group role in the ordered set where userId = ?.
 UserGroupRole[] findByUserId_PrevAndNext(UserGroupRolePK userGroupRolePK, long userId, OrderByComparator<UserGroupRole> orderByComparator)
          Returns the user group roles before and after the current user group role in the ordered set where userId = ?.
 List<UserGroupRole> findByUserId(long userId)
          Returns all the user group roles where userId = ?.
 List<UserGroupRole> findByUserId(long userId, int start, int end)
          Returns a range of all the user group roles where userId = ?.
 List<UserGroupRole> findByUserId(long userId, int start, int end, OrderByComparator<UserGroupRole> orderByComparator)
          Returns an ordered range of all the user group roles where userId = ?.
 List<UserGroupRole> findByUserId(long userId, int start, int end, OrderByComparator<UserGroupRole> orderByComparator, boolean retrieveFromCache)
          Returns an ordered range of all the user group roles where userId = ?.
 UserGroupRole remove(UserGroupRolePK userGroupRolePK)
          Removes the user group role with the primary key from the database.
 void removeAll()
          Removes all the user group roles from the database.
 void removeByG_R(long groupId, long roleId)
          Removes all the user group roles where groupId = ? and roleId = ? from the database.
 void removeByGroupId(long groupId)
          Removes all the user group roles where groupId = ? from the database.
 void removeByRoleId(long roleId)
          Removes all the user group roles where roleId = ? from the database.
 void removeByU_G(long userId, long groupId)
          Removes all the user group roles where userId = ? and groupId = ? from the database.
 void removeByUserId(long userId)
          Removes all the user group roles where userId = ? from the database.
 UserGroupRole updateImpl(UserGroupRole userGroupRole)
           
 
Methods inherited from interface com.liferay.portal.service.persistence.BasePersistence
clearCache, clearCache, clearCache, closeSession, countWithDynamicQuery, countWithDynamicQuery, fetchByPrimaryKey, findByPrimaryKey, findWithDynamicQuery, findWithDynamicQuery, findWithDynamicQuery, flush, getBadColumnNames, getCurrentSession, getDataSource, getListeners, getModelClass, openSession, processException, registerListener, remove, remove, setDataSource, unregisterListener, update, update, update, update
 

Method Detail

findByUserId

List<UserGroupRole> findByUserId(long userId)
Returns all the user group roles where userId = ?.

Parameters:
userId - the user ID
Returns:
the matching user group roles

findByUserId

List<UserGroupRole> findByUserId(long userId,
                                 int start,
                                 int end)
Returns a range of all the user group roles where userId = ?.

Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil#ALL_POS will return the full result set. If orderByComparator is specified, then the query will include the given ORDER BY logic. If orderByComparator is absent and pagination is required (start and end are not QueryUtil#ALL_POS), then the query will include the default ORDER BY logic from UserGroupRoleModelImpl. If both orderByComparator and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.

Parameters:
userId - the user ID
start - the lower bound of the range of user group roles
end - the upper bound of the range of user group roles (not inclusive)
Returns:
the range of matching user group roles

findByUserId

List<UserGroupRole> findByUserId(long userId,
                                 int start,
                                 int end,
                                 OrderByComparator<UserGroupRole> orderByComparator)
Returns an ordered range of all the user group roles where userId = ?.

Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil#ALL_POS will return the full result set. If orderByComparator is specified, then the query will include the given ORDER BY logic. If orderByComparator is absent and pagination is required (start and end are not QueryUtil#ALL_POS), then the query will include the default ORDER BY logic from UserGroupRoleModelImpl. If both orderByComparator and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.

Parameters:
userId - the user ID
start - the lower bound of the range of user group roles
end - the upper bound of the range of user group roles (not inclusive)
orderByComparator - the comparator to order the results by (optionally null)
Returns:
the ordered range of matching user group roles

findByUserId

List<UserGroupRole> findByUserId(long userId,
                                 int start,
                                 int end,
                                 OrderByComparator<UserGroupRole> orderByComparator,
                                 boolean retrieveFromCache)
Returns an ordered range of all the user group roles where userId = ?.

Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil#ALL_POS will return the full result set. If orderByComparator is specified, then the query will include the given ORDER BY logic. If orderByComparator is absent and pagination is required (start and end are not QueryUtil#ALL_POS), then the query will include the default ORDER BY logic from UserGroupRoleModelImpl. If both orderByComparator and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.

Parameters:
userId - the user ID
start - the lower bound of the range of user group roles
end - the upper bound of the range of user group roles (not inclusive)
orderByComparator - the comparator to order the results by (optionally null)
retrieveFromCache - whether to retrieve from the finder cache
Returns:
the ordered range of matching user group roles

findByUserId_First

UserGroupRole findByUserId_First(long userId,
                                 OrderByComparator<UserGroupRole> orderByComparator)
                                 throws NoSuchUserGroupRoleException
Returns the first user group role in the ordered set where userId = ?.

Parameters:
userId - the user ID
orderByComparator - the comparator to order the set by (optionally null)
Returns:
the first matching user group role
Throws:
NoSuchUserGroupRoleException - if a matching user group role could not be found

fetchByUserId_First

UserGroupRole fetchByUserId_First(long userId,
                                  OrderByComparator<UserGroupRole> orderByComparator)
Returns the first user group role in the ordered set where userId = ?.

Parameters:
userId - the user ID
orderByComparator - the comparator to order the set by (optionally null)
Returns:
the first matching user group role, or null if a matching user group role could not be found

findByUserId_Last

UserGroupRole findByUserId_Last(long userId,
                                OrderByComparator<UserGroupRole> orderByComparator)
                                throws NoSuchUserGroupRoleException
Returns the last user group role in the ordered set where userId = ?.

Parameters:
userId - the user ID
orderByComparator - the comparator to order the set by (optionally null)
Returns:
the last matching user group role
Throws:
NoSuchUserGroupRoleException - if a matching user group role could not be found

fetchByUserId_Last

UserGroupRole fetchByUserId_Last(long userId,
                                 OrderByComparator<UserGroupRole> orderByComparator)
Returns the last user group role in the ordered set where userId = ?.

Parameters:
userId - the user ID
orderByComparator - the comparator to order the set by (optionally null)
Returns:
the last matching user group role, or null if a matching user group role could not be found

findByUserId_PrevAndNext

UserGroupRole[] findByUserId_PrevAndNext(UserGroupRolePK userGroupRolePK,
                                         long userId,
                                         OrderByComparator<UserGroupRole> orderByComparator)
                                         throws NoSuchUserGroupRoleException
Returns the user group roles before and after the current user group role in the ordered set where userId = ?.

Parameters:
userGroupRolePK - the primary key of the current user group role
userId - the user ID
orderByComparator - the comparator to order the set by (optionally null)
Returns:
the previous, current, and next user group role
Throws:
NoSuchUserGroupRoleException - if a user group role with the primary key could not be found

removeByUserId

void removeByUserId(long userId)
Removes all the user group roles where userId = ? from the database.

Parameters:
userId - the user ID

countByUserId

int countByUserId(long userId)
Returns the number of user group roles where userId = ?.

Parameters:
userId - the user ID
Returns:
the number of matching user group roles

findByGroupId

List<UserGroupRole> findByGroupId(long groupId)
Returns all the user group roles where groupId = ?.

Parameters:
groupId - the group ID
Returns:
the matching user group roles

findByGroupId

List<UserGroupRole> findByGroupId(long groupId,
                                  int start,
                                  int end)
Returns a range of all the user group roles where groupId = ?.

Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil#ALL_POS will return the full result set. If orderByComparator is specified, then the query will include the given ORDER BY logic. If orderByComparator is absent and pagination is required (start and end are not QueryUtil#ALL_POS), then the query will include the default ORDER BY logic from UserGroupRoleModelImpl. If both orderByComparator and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.

Parameters:
groupId - the group ID
start - the lower bound of the range of user group roles
end - the upper bound of the range of user group roles (not inclusive)
Returns:
the range of matching user group roles

findByGroupId

List<UserGroupRole> findByGroupId(long groupId,
                                  int start,
                                  int end,
                                  OrderByComparator<UserGroupRole> orderByComparator)
Returns an ordered range of all the user group roles where groupId = ?.

Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil#ALL_POS will return the full result set. If orderByComparator is specified, then the query will include the given ORDER BY logic. If orderByComparator is absent and pagination is required (start and end are not QueryUtil#ALL_POS), then the query will include the default ORDER BY logic from UserGroupRoleModelImpl. If both orderByComparator and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.

Parameters:
groupId - the group ID
start - the lower bound of the range of user group roles
end - the upper bound of the range of user group roles (not inclusive)
orderByComparator - the comparator to order the results by (optionally null)
Returns:
the ordered range of matching user group roles

findByGroupId

List<UserGroupRole> findByGroupId(long groupId,
                                  int start,
                                  int end,
                                  OrderByComparator<UserGroupRole> orderByComparator,
                                  boolean retrieveFromCache)
Returns an ordered range of all the user group roles where groupId = ?.

Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil#ALL_POS will return the full result set. If orderByComparator is specified, then the query will include the given ORDER BY logic. If orderByComparator is absent and pagination is required (start and end are not QueryUtil#ALL_POS), then the query will include the default ORDER BY logic from UserGroupRoleModelImpl. If both orderByComparator and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.

Parameters:
groupId - the group ID
start - the lower bound of the range of user group roles
end - the upper bound of the range of user group roles (not inclusive)
orderByComparator - the comparator to order the results by (optionally null)
retrieveFromCache - whether to retrieve from the finder cache
Returns:
the ordered range of matching user group roles

findByGroupId_First

UserGroupRole findByGroupId_First(long groupId,
                                  OrderByComparator<UserGroupRole> orderByComparator)
                                  throws NoSuchUserGroupRoleException
Returns the first user group role in the ordered set where groupId = ?.

Parameters:
groupId - the group ID
orderByComparator - the comparator to order the set by (optionally null)
Returns:
the first matching user group role
Throws:
NoSuchUserGroupRoleException - if a matching user group role could not be found

fetchByGroupId_First

UserGroupRole fetchByGroupId_First(long groupId,
                                   OrderByComparator<UserGroupRole> orderByComparator)
Returns the first user group role in the ordered set where groupId = ?.

Parameters:
groupId - the group ID
orderByComparator - the comparator to order the set by (optionally null)
Returns:
the first matching user group role, or null if a matching user group role could not be found

findByGroupId_Last

UserGroupRole findByGroupId_Last(long groupId,
                                 OrderByComparator<UserGroupRole> orderByComparator)
                                 throws NoSuchUserGroupRoleException
Returns the last user group role in the ordered set where groupId = ?.

Parameters:
groupId - the group ID
orderByComparator - the comparator to order the set by (optionally null)
Returns:
the last matching user group role
Throws:
NoSuchUserGroupRoleException - if a matching user group role could not be found

fetchByGroupId_Last

UserGroupRole fetchByGroupId_Last(long groupId,
                                  OrderByComparator<UserGroupRole> orderByComparator)
Returns the last user group role in the ordered set where groupId = ?.

Parameters:
groupId - the group ID
orderByComparator - the comparator to order the set by (optionally null)
Returns:
the last matching user group role, or null if a matching user group role could not be found

findByGroupId_PrevAndNext

UserGroupRole[] findByGroupId_PrevAndNext(UserGroupRolePK userGroupRolePK,
                                          long groupId,
                                          OrderByComparator<UserGroupRole> orderByComparator)
                                          throws NoSuchUserGroupRoleException
Returns the user group roles before and after the current user group role in the ordered set where groupId = ?.

Parameters:
userGroupRolePK - the primary key of the current user group role
groupId - the group ID
orderByComparator - the comparator to order the set by (optionally null)
Returns:
the previous, current, and next user group role
Throws:
NoSuchUserGroupRoleException - if a user group role with the primary key could not be found

removeByGroupId

void removeByGroupId(long groupId)
Removes all the user group roles where groupId = ? from the database.

Parameters:
groupId - the group ID

countByGroupId

int countByGroupId(long groupId)
Returns the number of user group roles where groupId = ?.

Parameters:
groupId - the group ID
Returns:
the number of matching user group roles

findByRoleId

List<UserGroupRole> findByRoleId(long roleId)
Returns all the user group roles where roleId = ?.

Parameters:
roleId - the role ID
Returns:
the matching user group roles

findByRoleId

List<UserGroupRole> findByRoleId(long roleId,
                                 int start,
                                 int end)
Returns a range of all the user group roles where roleId = ?.

Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil#ALL_POS will return the full result set. If orderByComparator is specified, then the query will include the given ORDER BY logic. If orderByComparator is absent and pagination is required (start and end are not QueryUtil#ALL_POS), then the query will include the default ORDER BY logic from UserGroupRoleModelImpl. If both orderByComparator and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.

Parameters:
roleId - the role ID
start - the lower bound of the range of user group roles
end - the upper bound of the range of user group roles (not inclusive)
Returns:
the range of matching user group roles

findByRoleId

List<UserGroupRole> findByRoleId(long roleId,
                                 int start,
                                 int end,
                                 OrderByComparator<UserGroupRole> orderByComparator)
Returns an ordered range of all the user group roles where roleId = ?.

Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil#ALL_POS will return the full result set. If orderByComparator is specified, then the query will include the given ORDER BY logic. If orderByComparator is absent and pagination is required (start and end are not QueryUtil#ALL_POS), then the query will include the default ORDER BY logic from UserGroupRoleModelImpl. If both orderByComparator and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.

Parameters:
roleId - the role ID
start - the lower bound of the range of user group roles
end - the upper bound of the range of user group roles (not inclusive)
orderByComparator - the comparator to order the results by (optionally null)
Returns:
the ordered range of matching user group roles

findByRoleId

List<UserGroupRole> findByRoleId(long roleId,
                                 int start,
                                 int end,
                                 OrderByComparator<UserGroupRole> orderByComparator,
                                 boolean retrieveFromCache)
Returns an ordered range of all the user group roles where roleId = ?.

Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil#ALL_POS will return the full result set. If orderByComparator is specified, then the query will include the given ORDER BY logic. If orderByComparator is absent and pagination is required (start and end are not QueryUtil#ALL_POS), then the query will include the default ORDER BY logic from UserGroupRoleModelImpl. If both orderByComparator and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.

Parameters:
roleId - the role ID
start - the lower bound of the range of user group roles
end - the upper bound of the range of user group roles (not inclusive)
orderByComparator - the comparator to order the results by (optionally null)
retrieveFromCache - whether to retrieve from the finder cache
Returns:
the ordered range of matching user group roles

findByRoleId_First

UserGroupRole findByRoleId_First(long roleId,
                                 OrderByComparator<UserGroupRole> orderByComparator)
                                 throws NoSuchUserGroupRoleException
Returns the first user group role in the ordered set where roleId = ?.

Parameters:
roleId - the role ID
orderByComparator - the comparator to order the set by (optionally null)
Returns:
the first matching user group role
Throws:
NoSuchUserGroupRoleException - if a matching user group role could not be found

fetchByRoleId_First

UserGroupRole fetchByRoleId_First(long roleId,
                                  OrderByComparator<UserGroupRole> orderByComparator)
Returns the first user group role in the ordered set where roleId = ?.

Parameters:
roleId - the role ID
orderByComparator - the comparator to order the set by (optionally null)
Returns:
the first matching user group role, or null if a matching user group role could not be found

findByRoleId_Last

UserGroupRole findByRoleId_Last(long roleId,
                                OrderByComparator<UserGroupRole> orderByComparator)
                                throws NoSuchUserGroupRoleException
Returns the last user group role in the ordered set where roleId = ?.

Parameters:
roleId - the role ID
orderByComparator - the comparator to order the set by (optionally null)
Returns:
the last matching user group role
Throws:
NoSuchUserGroupRoleException - if a matching user group role could not be found

fetchByRoleId_Last

UserGroupRole fetchByRoleId_Last(long roleId,
                                 OrderByComparator<UserGroupRole> orderByComparator)
Returns the last user group role in the ordered set where roleId = ?.

Parameters:
roleId - the role ID
orderByComparator - the comparator to order the set by (optionally null)
Returns:
the last matching user group role, or null if a matching user group role could not be found

findByRoleId_PrevAndNext

UserGroupRole[] findByRoleId_PrevAndNext(UserGroupRolePK userGroupRolePK,
                                         long roleId,
                                         OrderByComparator<UserGroupRole> orderByComparator)
                                         throws NoSuchUserGroupRoleException
Returns the user group roles before and after the current user group role in the ordered set where roleId = ?.

Parameters:
userGroupRolePK - the primary key of the current user group role
roleId - the role ID
orderByComparator - the comparator to order the set by (optionally null)
Returns:
the previous, current, and next user group role
Throws:
NoSuchUserGroupRoleException - if a user group role with the primary key could not be found

removeByRoleId

void removeByRoleId(long roleId)
Removes all the user group roles where roleId = ? from the database.

Parameters:
roleId - the role ID

countByRoleId

int countByRoleId(long roleId)
Returns the number of user group roles where roleId = ?.

Parameters:
roleId - the role ID
Returns:
the number of matching user group roles

findByU_G

List<UserGroupRole> findByU_G(long userId,
                              long groupId)
Returns all the user group roles where userId = ? and groupId = ?.

Parameters:
userId - the user ID
groupId - the group ID
Returns:
the matching user group roles

findByU_G

List<UserGroupRole> findByU_G(long userId,
                              long groupId,
                              int start,
                              int end)
Returns a range of all the user group roles where userId = ? and groupId = ?.

Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil#ALL_POS will return the full result set. If orderByComparator is specified, then the query will include the given ORDER BY logic. If orderByComparator is absent and pagination is required (start and end are not QueryUtil#ALL_POS), then the query will include the default ORDER BY logic from UserGroupRoleModelImpl. If both orderByComparator and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.

Parameters:
userId - the user ID
groupId - the group ID
start - the lower bound of the range of user group roles
end - the upper bound of the range of user group roles (not inclusive)
Returns:
the range of matching user group roles

findByU_G

List<UserGroupRole> findByU_G(long userId,
                              long groupId,
                              int start,
                              int end,
                              OrderByComparator<UserGroupRole> orderByComparator)
Returns an ordered range of all the user group roles where userId = ? and groupId = ?.

Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil#ALL_POS will return the full result set. If orderByComparator is specified, then the query will include the given ORDER BY logic. If orderByComparator is absent and pagination is required (start and end are not QueryUtil#ALL_POS), then the query will include the default ORDER BY logic from UserGroupRoleModelImpl. If both orderByComparator and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.

Parameters:
userId - the user ID
groupId - the group ID
start - the lower bound of the range of user group roles
end - the upper bound of the range of user group roles (not inclusive)
orderByComparator - the comparator to order the results by (optionally null)
Returns:
the ordered range of matching user group roles

findByU_G

List<UserGroupRole> findByU_G(long userId,
                              long groupId,
                              int start,
                              int end,
                              OrderByComparator<UserGroupRole> orderByComparator,
                              boolean retrieveFromCache)
Returns an ordered range of all the user group roles where userId = ? and groupId = ?.

Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil#ALL_POS will return the full result set. If orderByComparator is specified, then the query will include the given ORDER BY logic. If orderByComparator is absent and pagination is required (start and end are not QueryUtil#ALL_POS), then the query will include the default ORDER BY logic from UserGroupRoleModelImpl. If both orderByComparator and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.

Parameters:
userId - the user ID
groupId - the group ID
start - the lower bound of the range of user group roles
end - the upper bound of the range of user group roles (not inclusive)
orderByComparator - the comparator to order the results by (optionally null)
retrieveFromCache - whether to retrieve from the finder cache
Returns:
the ordered range of matching user group roles

findByU_G_First

UserGroupRole findByU_G_First(long userId,
                              long groupId,
                              OrderByComparator<UserGroupRole> orderByComparator)
                              throws NoSuchUserGroupRoleException
Returns the first user group role in the ordered set where userId = ? and groupId = ?.

Parameters:
userId - the user ID
groupId - the group ID
orderByComparator - the comparator to order the set by (optionally null)
Returns:
the first matching user group role
Throws:
NoSuchUserGroupRoleException - if a matching user group role could not be found

fetchByU_G_First

UserGroupRole fetchByU_G_First(long userId,
                               long groupId,
                               OrderByComparator<UserGroupRole> orderByComparator)
Returns the first user group role in the ordered set where userId = ? and groupId = ?.

Parameters:
userId - the user ID
groupId - the group ID
orderByComparator - the comparator to order the set by (optionally null)
Returns:
the first matching user group role, or null if a matching user group role could not be found

findByU_G_Last

UserGroupRole findByU_G_Last(long userId,
                             long groupId,
                             OrderByComparator<UserGroupRole> orderByComparator)
                             throws NoSuchUserGroupRoleException
Returns the last user group role in the ordered set where userId = ? and groupId = ?.

Parameters:
userId - the user ID
groupId - the group ID
orderByComparator - the comparator to order the set by (optionally null)
Returns:
the last matching user group role
Throws:
NoSuchUserGroupRoleException - if a matching user group role could not be found

fetchByU_G_Last

UserGroupRole fetchByU_G_Last(long userId,
                              long groupId,
                              OrderByComparator<UserGroupRole> orderByComparator)
Returns the last user group role in the ordered set where userId = ? and groupId = ?.

Parameters:
userId - the user ID
groupId - the group ID
orderByComparator - the comparator to order the set by (optionally null)
Returns:
the last matching user group role, or null if a matching user group role could not be found

findByU_G_PrevAndNext

UserGroupRole[] findByU_G_PrevAndNext(UserGroupRolePK userGroupRolePK,
                                      long userId,
                                      long groupId,
                                      OrderByComparator<UserGroupRole> orderByComparator)
                                      throws NoSuchUserGroupRoleException
Returns the user group roles before and after the current user group role in the ordered set where userId = ? and groupId = ?.

Parameters:
userGroupRolePK - the primary key of the current user group role
userId - the user ID
groupId - the group ID
orderByComparator - the comparator to order the set by (optionally null)
Returns:
the previous, current, and next user group role
Throws:
NoSuchUserGroupRoleException - if a user group role with the primary key could not be found

removeByU_G

void removeByU_G(long userId,
                 long groupId)
Removes all the user group roles where userId = ? and groupId = ? from the database.

Parameters:
userId - the user ID
groupId - the group ID

countByU_G

int countByU_G(long userId,
               long groupId)
Returns the number of user group roles where userId = ? and groupId = ?.

Parameters:
userId - the user ID
groupId - the group ID
Returns:
the number of matching user group roles

findByG_R

List<UserGroupRole> findByG_R(long groupId,
                              long roleId)
Returns all the user group roles where groupId = ? and roleId = ?.

Parameters:
groupId - the group ID
roleId - the role ID
Returns:
the matching user group roles

findByG_R

List<UserGroupRole> findByG_R(long groupId,
                              long roleId,
                              int start,
                              int end)
Returns a range of all the user group roles where groupId = ? and roleId = ?.

Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil#ALL_POS will return the full result set. If orderByComparator is specified, then the query will include the given ORDER BY logic. If orderByComparator is absent and pagination is required (start and end are not QueryUtil#ALL_POS), then the query will include the default ORDER BY logic from UserGroupRoleModelImpl. If both orderByComparator and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.

Parameters:
groupId - the group ID
roleId - the role ID
start - the lower bound of the range of user group roles
end - the upper bound of the range of user group roles (not inclusive)
Returns:
the range of matching user group roles

findByG_R

List<UserGroupRole> findByG_R(long groupId,
                              long roleId,
                              int start,
                              int end,
                              OrderByComparator<UserGroupRole> orderByComparator)
Returns an ordered range of all the user group roles where groupId = ? and roleId = ?.

Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil#ALL_POS will return the full result set. If orderByComparator is specified, then the query will include the given ORDER BY logic. If orderByComparator is absent and pagination is required (start and end are not QueryUtil#ALL_POS), then the query will include the default ORDER BY logic from UserGroupRoleModelImpl. If both orderByComparator and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.

Parameters:
groupId - the group ID
roleId - the role ID
start - the lower bound of the range of user group roles
end - the upper bound of the range of user group roles (not inclusive)
orderByComparator - the comparator to order the results by (optionally null)
Returns:
the ordered range of matching user group roles

findByG_R

List<UserGroupRole> findByG_R(long groupId,
                              long roleId,
                              int start,
                              int end,
                              OrderByComparator<UserGroupRole> orderByComparator,
                              boolean retrieveFromCache)
Returns an ordered range of all the user group roles where groupId = ? and roleId = ?.

Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil#ALL_POS will return the full result set. If orderByComparator is specified, then the query will include the given ORDER BY logic. If orderByComparator is absent and pagination is required (start and end are not QueryUtil#ALL_POS), then the query will include the default ORDER BY logic from UserGroupRoleModelImpl. If both orderByComparator and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.

Parameters:
groupId - the group ID
roleId - the role ID
start - the lower bound of the range of user group roles
end - the upper bound of the range of user group roles (not inclusive)
orderByComparator - the comparator to order the results by (optionally null)
retrieveFromCache - whether to retrieve from the finder cache
Returns:
the ordered range of matching user group roles

findByG_R_First

UserGroupRole findByG_R_First(long groupId,
                              long roleId,
                              OrderByComparator<UserGroupRole> orderByComparator)
                              throws NoSuchUserGroupRoleException
Returns the first user group role in the ordered set where groupId = ? and roleId = ?.

Parameters:
groupId - the group ID
roleId - the role ID
orderByComparator - the comparator to order the set by (optionally null)
Returns:
the first matching user group role
Throws:
NoSuchUserGroupRoleException - if a matching user group role could not be found

fetchByG_R_First

UserGroupRole fetchByG_R_First(long groupId,
                               long roleId,
                               OrderByComparator<UserGroupRole> orderByComparator)
Returns the first user group role in the ordered set where groupId = ? and roleId = ?.

Parameters:
groupId - the group ID
roleId - the role ID
orderByComparator - the comparator to order the set by (optionally null)
Returns:
the first matching user group role, or null if a matching user group role could not be found

findByG_R_Last

UserGroupRole findByG_R_Last(long groupId,
                             long roleId,
                             OrderByComparator<UserGroupRole> orderByComparator)
                             throws NoSuchUserGroupRoleException
Returns the last user group role in the ordered set where groupId = ? and roleId = ?.

Parameters:
groupId - the group ID
roleId - the role ID
orderByComparator - the comparator to order the set by (optionally null)
Returns:
the last matching user group role
Throws:
NoSuchUserGroupRoleException - if a matching user group role could not be found

fetchByG_R_Last

UserGroupRole fetchByG_R_Last(long groupId,
                              long roleId,
                              OrderByComparator<UserGroupRole> orderByComparator)
Returns the last user group role in the ordered set where groupId = ? and roleId = ?.

Parameters:
groupId - the group ID
roleId - the role ID
orderByComparator - the comparator to order the set by (optionally null)
Returns:
the last matching user group role, or null if a matching user group role could not be found

findByG_R_PrevAndNext

UserGroupRole[] findByG_R_PrevAndNext(UserGroupRolePK userGroupRolePK,
                                      long groupId,
                                      long roleId,
                                      OrderByComparator<UserGroupRole> orderByComparator)
                                      throws NoSuchUserGroupRoleException
Returns the user group roles before and after the current user group role in the ordered set where groupId = ? and roleId = ?.

Parameters:
userGroupRolePK - the primary key of the current user group role
groupId - the group ID
roleId - the role ID
orderByComparator - the comparator to order the set by (optionally null)
Returns:
the previous, current, and next user group role
Throws:
NoSuchUserGroupRoleException - if a user group role with the primary key could not be found

removeByG_R

void removeByG_R(long groupId,
                 long roleId)
Removes all the user group roles where groupId = ? and roleId = ? from the database.

Parameters:
groupId - the group ID
roleId - the role ID

countByG_R

int countByG_R(long groupId,
               long roleId)
Returns the number of user group roles where groupId = ? and roleId = ?.

Parameters:
groupId - the group ID
roleId - the role ID
Returns:
the number of matching user group roles

cacheResult

void cacheResult(UserGroupRole userGroupRole)
Caches the user group role in the entity cache if it is enabled.

Parameters:
userGroupRole - the user group role

cacheResult

void cacheResult(List<UserGroupRole> userGroupRoles)
Caches the user group roles in the entity cache if it is enabled.

Parameters:
userGroupRoles - the user group roles

create

UserGroupRole create(UserGroupRolePK userGroupRolePK)
Creates a new user group role with the primary key. Does not add the user group role to the database.

Parameters:
userGroupRolePK - the primary key for the new user group role
Returns:
the new user group role

remove

UserGroupRole remove(UserGroupRolePK userGroupRolePK)
                     throws NoSuchUserGroupRoleException
Removes the user group role with the primary key from the database. Also notifies the appropriate model listeners.

Parameters:
userGroupRolePK - the primary key of the user group role
Returns:
the user group role that was removed
Throws:
NoSuchUserGroupRoleException - if a user group role with the primary key could not be found

updateImpl

UserGroupRole updateImpl(UserGroupRole userGroupRole)

findByPrimaryKey

UserGroupRole findByPrimaryKey(UserGroupRolePK userGroupRolePK)
                               throws NoSuchUserGroupRoleException
Returns the user group role with the primary key or throws a NoSuchUserGroupRoleException if it could not be found.

Parameters:
userGroupRolePK - the primary key of the user group role
Returns:
the user group role
Throws:
NoSuchUserGroupRoleException - if a user group role with the primary key could not be found

fetchByPrimaryKey

UserGroupRole fetchByPrimaryKey(UserGroupRolePK userGroupRolePK)
Returns the user group role with the primary key or returns null if it could not be found.

Parameters:
userGroupRolePK - the primary key of the user group role
Returns:
the user group role, or null if a user group role with the primary key could not be found

fetchByPrimaryKeys

Map<Serializable,UserGroupRole> fetchByPrimaryKeys(Set<Serializable> primaryKeys)
Specified by:
fetchByPrimaryKeys in interface BasePersistence<UserGroupRole>

findAll

List<UserGroupRole> findAll()
Returns all the user group roles.

Returns:
the user group roles

findAll

List<UserGroupRole> findAll(int start,
                            int end)
Returns a range of all the user group roles.

Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil#ALL_POS will return the full result set. If orderByComparator is specified, then the query will include the given ORDER BY logic. If orderByComparator is absent and pagination is required (start and end are not QueryUtil#ALL_POS), then the query will include the default ORDER BY logic from UserGroupRoleModelImpl. If both orderByComparator and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.

Parameters:
start - the lower bound of the range of user group roles
end - the upper bound of the range of user group roles (not inclusive)
Returns:
the range of user group roles

findAll

List<UserGroupRole> findAll(int start,
                            int end,
                            OrderByComparator<UserGroupRole> orderByComparator)
Returns an ordered range of all the user group roles.

Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil#ALL_POS will return the full result set. If orderByComparator is specified, then the query will include the given ORDER BY logic. If orderByComparator is absent and pagination is required (start and end are not QueryUtil#ALL_POS), then the query will include the default ORDER BY logic from UserGroupRoleModelImpl. If both orderByComparator and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.

Parameters:
start - the lower bound of the range of user group roles
end - the upper bound of the range of user group roles (not inclusive)
orderByComparator - the comparator to order the results by (optionally null)
Returns:
the ordered range of user group roles

findAll

List<UserGroupRole> findAll(int start,
                            int end,
                            OrderByComparator<UserGroupRole> orderByComparator,
                            boolean retrieveFromCache)
Returns an ordered range of all the user group roles.

Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil#ALL_POS will return the full result set. If orderByComparator is specified, then the query will include the given ORDER BY logic. If orderByComparator is absent and pagination is required (start and end are not QueryUtil#ALL_POS), then the query will include the default ORDER BY logic from UserGroupRoleModelImpl. If both orderByComparator and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.

Parameters:
start - the lower bound of the range of user group roles
end - the upper bound of the range of user group roles (not inclusive)
orderByComparator - the comparator to order the results by (optionally null)
retrieveFromCache - whether to retrieve from the finder cache
Returns:
the ordered range of user group roles

removeAll

void removeAll()
Removes all the user group roles from the database.


countAll

int countAll()
Returns the number of user group roles.

Returns:
the number of user group roles

Liferay 7.0-ce-b4