001
014
015 package com.liferay.portlet.polls.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 PollsQuestionLocalService {
043 public com.liferay.portlet.polls.model.PollsQuestion addPollsQuestion(
044 com.liferay.portlet.polls.model.PollsQuestion pollsQuestion)
045 throws com.liferay.portal.kernel.exception.SystemException;
046
047 public com.liferay.portlet.polls.model.PollsQuestion createPollsQuestion(
048 long questionId);
049
050 public void deletePollsQuestion(long questionId)
051 throws com.liferay.portal.kernel.exception.PortalException,
052 com.liferay.portal.kernel.exception.SystemException;
053
054 public void deletePollsQuestion(
055 com.liferay.portlet.polls.model.PollsQuestion pollsQuestion)
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.polls.model.PollsQuestion getPollsQuestion(
081 long questionId)
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 com.liferay.portlet.polls.model.PollsQuestion getPollsQuestionByUuidAndGroupId(
087 java.lang.String uuid, long groupId)
088 throws com.liferay.portal.kernel.exception.PortalException,
089 com.liferay.portal.kernel.exception.SystemException;
090
091 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
092 public java.util.List<com.liferay.portlet.polls.model.PollsQuestion> getPollsQuestions(
093 int start, int end)
094 throws com.liferay.portal.kernel.exception.SystemException;
095
096 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
097 public int getPollsQuestionsCount()
098 throws com.liferay.portal.kernel.exception.SystemException;
099
100 public com.liferay.portlet.polls.model.PollsQuestion updatePollsQuestion(
101 com.liferay.portlet.polls.model.PollsQuestion pollsQuestion)
102 throws com.liferay.portal.kernel.exception.SystemException;
103
104 public com.liferay.portlet.polls.model.PollsQuestion updatePollsQuestion(
105 com.liferay.portlet.polls.model.PollsQuestion pollsQuestion,
106 boolean merge)
107 throws com.liferay.portal.kernel.exception.SystemException;
108
109 public com.liferay.portlet.polls.model.PollsQuestion addQuestion(
110 long userId,
111 java.util.Map<java.util.Locale, java.lang.String> titleMap,
112 java.util.Map<java.util.Locale, java.lang.String> descriptionMap,
113 int expirationDateMonth, int expirationDateDay, int expirationDateYear,
114 int expirationDateHour, int expirationDateMinute, boolean neverExpire,
115 java.util.List<com.liferay.portlet.polls.model.PollsChoice> choices,
116 com.liferay.portal.service.ServiceContext serviceContext)
117 throws com.liferay.portal.kernel.exception.PortalException,
118 com.liferay.portal.kernel.exception.SystemException;
119
120 public void addQuestionResources(long questionId,
121 boolean addCommunityPermissions, boolean addGuestPermissions)
122 throws com.liferay.portal.kernel.exception.PortalException,
123 com.liferay.portal.kernel.exception.SystemException;
124
125 public void addQuestionResources(long questionId,
126 java.lang.String[] communityPermissions,
127 java.lang.String[] guestPermissions)
128 throws com.liferay.portal.kernel.exception.PortalException,
129 com.liferay.portal.kernel.exception.SystemException;
130
131 public void addQuestionResources(
132 com.liferay.portlet.polls.model.PollsQuestion question,
133 boolean addCommunityPermissions, boolean addGuestPermissions)
134 throws com.liferay.portal.kernel.exception.PortalException,
135 com.liferay.portal.kernel.exception.SystemException;
136
137 public void addQuestionResources(
138 com.liferay.portlet.polls.model.PollsQuestion question,
139 java.lang.String[] communityPermissions,
140 java.lang.String[] guestPermissions)
141 throws com.liferay.portal.kernel.exception.PortalException,
142 com.liferay.portal.kernel.exception.SystemException;
143
144 public void deleteQuestion(long questionId)
145 throws com.liferay.portal.kernel.exception.PortalException,
146 com.liferay.portal.kernel.exception.SystemException;
147
148 public void deleteQuestion(
149 com.liferay.portlet.polls.model.PollsQuestion question)
150 throws com.liferay.portal.kernel.exception.PortalException,
151 com.liferay.portal.kernel.exception.SystemException;
152
153 public void deleteQuestions(long groupId)
154 throws com.liferay.portal.kernel.exception.PortalException,
155 com.liferay.portal.kernel.exception.SystemException;
156
157 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
158 public com.liferay.portlet.polls.model.PollsQuestion getQuestion(
159 long questionId)
160 throws com.liferay.portal.kernel.exception.PortalException,
161 com.liferay.portal.kernel.exception.SystemException;
162
163 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
164 public java.util.List<com.liferay.portlet.polls.model.PollsQuestion> getQuestions(
165 long groupId)
166 throws com.liferay.portal.kernel.exception.SystemException;
167
168 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
169 public java.util.List<com.liferay.portlet.polls.model.PollsQuestion> getQuestions(
170 long groupId, int start, int end)
171 throws com.liferay.portal.kernel.exception.SystemException;
172
173 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
174 public int getQuestionsCount(long groupId)
175 throws com.liferay.portal.kernel.exception.SystemException;
176
177 public com.liferay.portlet.polls.model.PollsQuestion updateQuestion(
178 long userId, long questionId,
179 java.util.Map<java.util.Locale, java.lang.String> titleMap,
180 java.util.Map<java.util.Locale, java.lang.String> descriptionMap,
181 int expirationDateMonth, int expirationDateDay, int expirationDateYear,
182 int expirationDateHour, int expirationDateMinute, boolean neverExpire,
183 java.util.List<com.liferay.portlet.polls.model.PollsChoice> choices,
184 com.liferay.portal.service.ServiceContext serviceContext)
185 throws com.liferay.portal.kernel.exception.PortalException,
186 com.liferay.portal.kernel.exception.SystemException;
187 }