1   /**
2    * Copyright (c) 2000-2010 Liferay, Inc. All rights reserved.
3    *
4    * The contents of this file are subject to the terms of the Liferay Enterprise
5    * Subscription License ("License"). You may not use this file except in
6    * compliance with the License. You can obtain a copy of the License by
7    * contacting Liferay, Inc. See the License for the specific language governing
8    * permissions and limitations under the License, including but not limited to
9    * distribution rights of the Software.
10   *
11   *
12   *
13   */
14  
15  package com.liferay.portal.model.impl;
16  
17  import com.liferay.portal.PortalException;
18  import com.liferay.portal.SystemException;
19  import com.liferay.portal.model.Group;
20  import com.liferay.portal.model.Role;
21  import com.liferay.portal.model.User;
22  import com.liferay.portal.model.UserGroupRole;
23  import com.liferay.portal.service.GroupLocalServiceUtil;
24  import com.liferay.portal.service.RoleLocalServiceUtil;
25  import com.liferay.portal.service.UserLocalServiceUtil;
26  
27  /**
28   * <a href="UserGroupRoleImpl.java.html"><b><i>View Source</i></b></a>
29   *
30   * @author Brian Wing Shun Chan
31   */
32  public class UserGroupRoleImpl
33      extends UserGroupRoleModelImpl implements UserGroupRole {
34  
35      public UserGroupRoleImpl() {
36      }
37  
38      public Group getGroup() throws PortalException, SystemException {
39          return GroupLocalServiceUtil.getGroup(getGroupId());
40      }
41  
42      public Role getRole() throws PortalException, SystemException {
43          return RoleLocalServiceUtil.getRole(getRoleId());
44      }
45  
46      public User getUser() throws PortalException, SystemException {
47          return UserLocalServiceUtil.getUser(getUserId());
48      }
49  
50  }