001
014
015 package com.liferay.portlet.social.service;
016
017 import com.liferay.portal.kernel.annotation.Isolation;
018 import com.liferay.portal.kernel.annotation.Propagation;
019 import com.liferay.portal.kernel.annotation.Transactional;
020 import com.liferay.portal.kernel.exception.PortalException;
021 import com.liferay.portal.kernel.exception.SystemException;
022
023
040 @Transactional(isolation = Isolation.PORTAL, rollbackFor = {
041 PortalException.class, SystemException.class})
042 public interface SocialRelationLocalService {
043 public com.liferay.portlet.social.model.SocialRelation addSocialRelation(
044 com.liferay.portlet.social.model.SocialRelation socialRelation)
045 throws com.liferay.portal.kernel.exception.SystemException;
046
047 public com.liferay.portlet.social.model.SocialRelation createSocialRelation(
048 long relationId);
049
050 public void deleteSocialRelation(long relationId)
051 throws com.liferay.portal.kernel.exception.PortalException,
052 com.liferay.portal.kernel.exception.SystemException;
053
054 public void deleteSocialRelation(
055 com.liferay.portlet.social.model.SocialRelation socialRelation)
056 throws com.liferay.portal.kernel.exception.SystemException;
057
058 @SuppressWarnings("unchecked")
059 public java.util.List dynamicQuery(
060 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
061 throws com.liferay.portal.kernel.exception.SystemException;
062
063 @SuppressWarnings("unchecked")
064 public java.util.List dynamicQuery(
065 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
066 int end) throws com.liferay.portal.kernel.exception.SystemException;
067
068 @SuppressWarnings("unchecked")
069 public java.util.List dynamicQuery(
070 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
071 int end,
072 com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
073 throws com.liferay.portal.kernel.exception.SystemException;
074
075 public long dynamicQueryCount(
076 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
077 throws com.liferay.portal.kernel.exception.SystemException;
078
079 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
080 public com.liferay.portlet.social.model.SocialRelation getSocialRelation(
081 long relationId)
082 throws com.liferay.portal.kernel.exception.PortalException,
083 com.liferay.portal.kernel.exception.SystemException;
084
085 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
086 public java.util.List<com.liferay.portlet.social.model.SocialRelation> getSocialRelations(
087 int start, int end)
088 throws com.liferay.portal.kernel.exception.SystemException;
089
090 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
091 public int getSocialRelationsCount()
092 throws com.liferay.portal.kernel.exception.SystemException;
093
094 public com.liferay.portlet.social.model.SocialRelation updateSocialRelation(
095 com.liferay.portlet.social.model.SocialRelation socialRelation)
096 throws com.liferay.portal.kernel.exception.SystemException;
097
098 public com.liferay.portlet.social.model.SocialRelation updateSocialRelation(
099 com.liferay.portlet.social.model.SocialRelation socialRelation,
100 boolean merge)
101 throws com.liferay.portal.kernel.exception.SystemException;
102
103 public com.liferay.portlet.social.model.SocialRelation addRelation(
104 long userId1, long userId2, int type)
105 throws com.liferay.portal.kernel.exception.PortalException,
106 com.liferay.portal.kernel.exception.SystemException;
107
108 public void deleteRelation(long relationId)
109 throws com.liferay.portal.kernel.exception.PortalException,
110 com.liferay.portal.kernel.exception.SystemException;
111
112 public void deleteRelation(long userId1, long userId2, int type)
113 throws com.liferay.portal.kernel.exception.PortalException,
114 com.liferay.portal.kernel.exception.SystemException;
115
116 public void deleteRelation(
117 com.liferay.portlet.social.model.SocialRelation relation)
118 throws com.liferay.portal.kernel.exception.PortalException,
119 com.liferay.portal.kernel.exception.SystemException;
120
121 public void deleteRelations(long userId)
122 throws com.liferay.portal.kernel.exception.SystemException;
123
124 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
125 public com.liferay.portlet.social.model.SocialRelation getRelation(
126 long relationId)
127 throws com.liferay.portal.kernel.exception.PortalException,
128 com.liferay.portal.kernel.exception.SystemException;
129
130 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
131 public com.liferay.portlet.social.model.SocialRelation getRelation(
132 long userId1, long userId2, int type)
133 throws com.liferay.portal.kernel.exception.PortalException,
134 com.liferay.portal.kernel.exception.SystemException;
135
136 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
137 public java.util.List<com.liferay.portlet.social.model.SocialRelation> getRelations(
138 long userId, int type, int start, int end)
139 throws com.liferay.portal.kernel.exception.SystemException;
140
141 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
142 public int getRelationsCount(long userId, int type)
143 throws com.liferay.portal.kernel.exception.SystemException;
144
145 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
146 public boolean hasRelation(long userId1, long userId2, int type)
147 throws com.liferay.portal.kernel.exception.SystemException;
148
149 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
150 public boolean isRelatable(long userId1, long userId2, int type)
151 throws com.liferay.portal.kernel.exception.SystemException;
152 }