1   /**
2    * Copyright (c) 2000-2010 Liferay, Inc. All rights reserved.
3    *
4    * This library is free software; you can redistribute it and/or modify it under
5    * the terms of the GNU Lesser General Public License as published by the Free
6    * Software Foundation; either version 2.1 of the License, or (at your option)
7    * any later version.
8    *
9    * This library is distributed in the hope that it will be useful, but WITHOUT
10   * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
11   * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
12   * details.
13   */
14  
15  package com.liferay.portal.service.persistence;
16  
17  /**
18   * <a href="RoleFinder.java.html"><b><i>View Source</i></b></a>
19   *
20   * @author Brian Wing Shun Chan
21   */
22  public interface RoleFinder {
23      public int countByR_U(long roleId, long userId)
24          throws com.liferay.portal.kernel.exception.SystemException;
25  
26      public int countByU_G_R(long userId, long groupId, long roleId)
27          throws com.liferay.portal.kernel.exception.SystemException;
28  
29      public int countByC_N_D_T(long companyId, java.lang.String name,
30          java.lang.String description, java.lang.Integer type,
31          java.util.LinkedHashMap<String, Object> params)
32          throws com.liferay.portal.kernel.exception.SystemException;
33  
34      public java.util.List<com.liferay.portal.model.Role> findBySystem(
35          long companyId)
36          throws com.liferay.portal.kernel.exception.SystemException;
37  
38      public java.util.List<com.liferay.portal.model.Role> findByUserGroupGroupRole(
39          long userId, long groupId)
40          throws com.liferay.portal.kernel.exception.SystemException;
41  
42      public java.util.List<com.liferay.portal.model.Role> findByUserGroupRole(
43          long userId, long groupId)
44          throws com.liferay.portal.kernel.exception.SystemException;
45  
46      public com.liferay.portal.model.Role findByC_N(long companyId,
47          java.lang.String name)
48          throws com.liferay.portal.NoSuchRoleException,
49              com.liferay.portal.kernel.exception.SystemException;
50  
51      public java.util.List<com.liferay.portal.model.Role> findByU_G(
52          long userId, long groupId)
53          throws com.liferay.portal.kernel.exception.SystemException;
54  
55      public java.util.List<com.liferay.portal.model.Role> findByU_G(
56          long userId, long[] groupIds)
57          throws com.liferay.portal.kernel.exception.SystemException;
58  
59      public java.util.List<com.liferay.portal.model.Role> findByU_G(
60          long userId, java.util.List<com.liferay.portal.model.Group> groups)
61          throws com.liferay.portal.kernel.exception.SystemException;
62  
63      public java.util.List<com.liferay.portal.model.Role> findByC_N_D_T(
64          long companyId, java.lang.String name, java.lang.String description,
65          java.lang.Integer type, java.util.LinkedHashMap<String, Object> params,
66          int start, int end, com.liferay.portal.kernel.util.OrderByComparator obc)
67          throws com.liferay.portal.kernel.exception.SystemException;
68  
69      public java.util.Map<String, java.util.List<String>> findByC_N_S_P(
70          long companyId, java.lang.String name, int scope,
71          java.lang.String primKey)
72          throws com.liferay.portal.kernel.exception.SystemException;
73  }