1
22
23 package com.liferay.portlet.polls.service;
24
25
26
47 public class PollsQuestionLocalServiceUtil {
48 public static com.liferay.portlet.polls.model.PollsQuestion addPollsQuestion(
49 com.liferay.portlet.polls.model.PollsQuestion pollsQuestion)
50 throws com.liferay.portal.SystemException {
51 return getService().addPollsQuestion(pollsQuestion);
52 }
53
54 public static com.liferay.portlet.polls.model.PollsQuestion createPollsQuestion(
55 long questionId) {
56 return getService().createPollsQuestion(questionId);
57 }
58
59 public static void deletePollsQuestion(long questionId)
60 throws com.liferay.portal.PortalException,
61 com.liferay.portal.SystemException {
62 getService().deletePollsQuestion(questionId);
63 }
64
65 public static void deletePollsQuestion(
66 com.liferay.portlet.polls.model.PollsQuestion pollsQuestion)
67 throws com.liferay.portal.SystemException {
68 getService().deletePollsQuestion(pollsQuestion);
69 }
70
71 public static java.util.List<Object> dynamicQuery(
72 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
73 throws com.liferay.portal.SystemException {
74 return getService().dynamicQuery(dynamicQuery);
75 }
76
77 public static java.util.List<Object> dynamicQuery(
78 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
79 int end) throws com.liferay.portal.SystemException {
80 return getService().dynamicQuery(dynamicQuery, start, end);
81 }
82
83 public static com.liferay.portlet.polls.model.PollsQuestion getPollsQuestion(
84 long questionId)
85 throws com.liferay.portal.PortalException,
86 com.liferay.portal.SystemException {
87 return getService().getPollsQuestion(questionId);
88 }
89
90 public static java.util.List<com.liferay.portlet.polls.model.PollsQuestion> getPollsQuestions(
91 int start, int end) throws com.liferay.portal.SystemException {
92 return getService().getPollsQuestions(start, end);
93 }
94
95 public static int getPollsQuestionsCount()
96 throws com.liferay.portal.SystemException {
97 return getService().getPollsQuestionsCount();
98 }
99
100 public static com.liferay.portlet.polls.model.PollsQuestion updatePollsQuestion(
101 com.liferay.portlet.polls.model.PollsQuestion pollsQuestion)
102 throws com.liferay.portal.SystemException {
103 return getService().updatePollsQuestion(pollsQuestion);
104 }
105
106 public static com.liferay.portlet.polls.model.PollsQuestion addQuestion(
107 long userId, java.lang.String title, java.lang.String description,
108 int expirationDateMonth, int expirationDateDay, int expirationDateYear,
109 int expirationDateHour, int expirationDateMinute, boolean neverExpire,
110 java.util.List<com.liferay.portlet.polls.model.PollsChoice> choices,
111 com.liferay.portal.service.ServiceContext serviceContext)
112 throws com.liferay.portal.PortalException,
113 com.liferay.portal.SystemException {
114 return getService()
115 .addQuestion(userId, title, description,
116 expirationDateMonth, expirationDateDay, expirationDateYear,
117 expirationDateHour, expirationDateMinute, neverExpire, choices,
118 serviceContext);
119 }
120
121 public static com.liferay.portlet.polls.model.PollsQuestion addQuestion(
122 java.lang.String uuid, long userId, java.lang.String title,
123 java.lang.String description, int expirationDateMonth,
124 int expirationDateDay, int expirationDateYear, int expirationDateHour,
125 int expirationDateMinute, boolean neverExpire,
126 java.util.List<com.liferay.portlet.polls.model.PollsChoice> choices,
127 com.liferay.portal.service.ServiceContext serviceContext)
128 throws com.liferay.portal.PortalException,
129 com.liferay.portal.SystemException {
130 return getService()
131 .addQuestion(uuid, userId, title, description,
132 expirationDateMonth, expirationDateDay, expirationDateYear,
133 expirationDateHour, expirationDateMinute, neverExpire, choices,
134 serviceContext);
135 }
136
137 public static void addQuestionResources(long questionId,
138 boolean addCommunityPermissions, boolean addGuestPermissions)
139 throws com.liferay.portal.PortalException,
140 com.liferay.portal.SystemException {
141 getService()
142 .addQuestionResources(questionId, addCommunityPermissions,
143 addGuestPermissions);
144 }
145
146 public static void addQuestionResources(
147 com.liferay.portlet.polls.model.PollsQuestion question,
148 boolean addCommunityPermissions, boolean addGuestPermissions)
149 throws com.liferay.portal.PortalException,
150 com.liferay.portal.SystemException {
151 getService()
152 .addQuestionResources(question, addCommunityPermissions,
153 addGuestPermissions);
154 }
155
156 public static void addQuestionResources(long questionId,
157 java.lang.String[] communityPermissions,
158 java.lang.String[] guestPermissions)
159 throws com.liferay.portal.PortalException,
160 com.liferay.portal.SystemException {
161 getService()
162 .addQuestionResources(questionId, communityPermissions,
163 guestPermissions);
164 }
165
166 public static void addQuestionResources(
167 com.liferay.portlet.polls.model.PollsQuestion question,
168 java.lang.String[] communityPermissions,
169 java.lang.String[] guestPermissions)
170 throws com.liferay.portal.PortalException,
171 com.liferay.portal.SystemException {
172 getService()
173 .addQuestionResources(question, communityPermissions,
174 guestPermissions);
175 }
176
177 public static void deleteQuestion(long questionId)
178 throws com.liferay.portal.PortalException,
179 com.liferay.portal.SystemException {
180 getService().deleteQuestion(questionId);
181 }
182
183 public static void deleteQuestion(
184 com.liferay.portlet.polls.model.PollsQuestion question)
185 throws com.liferay.portal.PortalException,
186 com.liferay.portal.SystemException {
187 getService().deleteQuestion(question);
188 }
189
190 public static void deleteQuestions(long groupId)
191 throws com.liferay.portal.PortalException,
192 com.liferay.portal.SystemException {
193 getService().deleteQuestions(groupId);
194 }
195
196 public static com.liferay.portlet.polls.model.PollsQuestion getQuestion(
197 long questionId)
198 throws com.liferay.portal.PortalException,
199 com.liferay.portal.SystemException {
200 return getService().getQuestion(questionId);
201 }
202
203 public static java.util.List<com.liferay.portlet.polls.model.PollsQuestion> getQuestions(
204 long groupId) throws com.liferay.portal.SystemException {
205 return getService().getQuestions(groupId);
206 }
207
208 public static java.util.List<com.liferay.portlet.polls.model.PollsQuestion> getQuestions(
209 long groupId, int start, int end)
210 throws com.liferay.portal.SystemException {
211 return getService().getQuestions(groupId, start, end);
212 }
213
214 public static int getQuestionsCount(long groupId)
215 throws com.liferay.portal.SystemException {
216 return getService().getQuestionsCount(groupId);
217 }
218
219 public static com.liferay.portlet.polls.model.PollsQuestion updateQuestion(
220 long userId, long questionId, java.lang.String title,
221 java.lang.String description, int expirationDateMonth,
222 int expirationDateDay, int expirationDateYear, int expirationDateHour,
223 int expirationDateMinute, boolean neverExpire)
224 throws com.liferay.portal.PortalException,
225 com.liferay.portal.SystemException {
226 return getService()
227 .updateQuestion(userId, questionId, title, description,
228 expirationDateMonth, expirationDateDay, expirationDateYear,
229 expirationDateHour, expirationDateMinute, neverExpire);
230 }
231
232 public static com.liferay.portlet.polls.model.PollsQuestion updateQuestion(
233 long userId, long questionId, java.lang.String title,
234 java.lang.String description, int expirationDateMonth,
235 int expirationDateDay, int expirationDateYear, int expirationDateHour,
236 int expirationDateMinute, boolean neverExpire,
237 java.util.List<com.liferay.portlet.polls.model.PollsChoice> choices,
238 com.liferay.portal.service.ServiceContext serviceContext)
239 throws com.liferay.portal.PortalException,
240 com.liferay.portal.SystemException {
241 return getService()
242 .updateQuestion(userId, questionId, title, description,
243 expirationDateMonth, expirationDateDay, expirationDateYear,
244 expirationDateHour, expirationDateMinute, neverExpire, choices,
245 serviceContext);
246 }
247
248 public static PollsQuestionLocalService getService() {
249 if (_service == null) {
250 throw new RuntimeException("PollsQuestionLocalService is not set");
251 }
252
253 return _service;
254 }
255
256 public void setService(PollsQuestionLocalService service) {
257 _service = service;
258 }
259
260 private static PollsQuestionLocalService _service;
261 }