1
22
23 package com.liferay.portlet.messageboards.service;
24
25
26
47 public class MBThreadLocalServiceUtil {
48 public static com.liferay.portlet.messageboards.model.MBThread addMBThread(
49 com.liferay.portlet.messageboards.model.MBThread mbThread)
50 throws com.liferay.portal.SystemException {
51 return getService().addMBThread(mbThread);
52 }
53
54 public static com.liferay.portlet.messageboards.model.MBThread createMBThread(
55 long threadId) {
56 return getService().createMBThread(threadId);
57 }
58
59 public static void deleteMBThread(long threadId)
60 throws com.liferay.portal.PortalException,
61 com.liferay.portal.SystemException {
62 getService().deleteMBThread(threadId);
63 }
64
65 public static void deleteMBThread(
66 com.liferay.portlet.messageboards.model.MBThread mbThread)
67 throws com.liferay.portal.SystemException {
68 getService().deleteMBThread(mbThread);
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.messageboards.model.MBThread getMBThread(
84 long threadId)
85 throws com.liferay.portal.PortalException,
86 com.liferay.portal.SystemException {
87 return getService().getMBThread(threadId);
88 }
89
90 public static java.util.List<com.liferay.portlet.messageboards.model.MBThread> getMBThreads(
91 int start, int end) throws com.liferay.portal.SystemException {
92 return getService().getMBThreads(start, end);
93 }
94
95 public static int getMBThreadsCount()
96 throws com.liferay.portal.SystemException {
97 return getService().getMBThreadsCount();
98 }
99
100 public static com.liferay.portlet.messageboards.model.MBThread updateMBThread(
101 com.liferay.portlet.messageboards.model.MBThread mbThread)
102 throws com.liferay.portal.SystemException {
103 return getService().updateMBThread(mbThread);
104 }
105
106 public static com.liferay.portlet.messageboards.model.MBThread updateMBThread(
107 com.liferay.portlet.messageboards.model.MBThread mbThread, boolean merge)
108 throws com.liferay.portal.SystemException {
109 return getService().updateMBThread(mbThread, merge);
110 }
111
112 public static void deleteThread(long threadId)
113 throws com.liferay.portal.PortalException,
114 com.liferay.portal.SystemException {
115 getService().deleteThread(threadId);
116 }
117
118 public static void deleteThread(
119 com.liferay.portlet.messageboards.model.MBThread thread)
120 throws com.liferay.portal.PortalException,
121 com.liferay.portal.SystemException {
122 getService().deleteThread(thread);
123 }
124
125 public static void deleteThreads(long categoryId)
126 throws com.liferay.portal.PortalException,
127 com.liferay.portal.SystemException {
128 getService().deleteThreads(categoryId);
129 }
130
131 public static int getCategoriesThreadsCount(
132 java.util.List<Long> categoryIds)
133 throws com.liferay.portal.SystemException {
134 return getService().getCategoriesThreadsCount(categoryIds);
135 }
136
137 public static int getCategoryThreadsCount(long categoryId)
138 throws com.liferay.portal.SystemException {
139 return getService().getCategoryThreadsCount(categoryId);
140 }
141
142 public static java.util.List<com.liferay.portlet.messageboards.model.MBThread> getGroupThreads(
143 long groupId, int start, int end)
144 throws com.liferay.portal.SystemException {
145 return getService().getGroupThreads(groupId, start, end);
146 }
147
148 public static java.util.List<com.liferay.portlet.messageboards.model.MBThread> getGroupThreads(
149 long groupId, long userId, int start, int end)
150 throws com.liferay.portal.PortalException,
151 com.liferay.portal.SystemException {
152 return getService().getGroupThreads(groupId, userId, start, end);
153 }
154
155 public static java.util.List<com.liferay.portlet.messageboards.model.MBThread> getGroupThreads(
156 long groupId, long userId, boolean subscribed, int start, int end)
157 throws com.liferay.portal.PortalException,
158 com.liferay.portal.SystemException {
159 return getService()
160 .getGroupThreads(groupId, userId, subscribed, start, end);
161 }
162
163 public static java.util.List<com.liferay.portlet.messageboards.model.MBThread> getGroupThreads(
164 long groupId, long userId, boolean subscribed,
165 boolean includeAnonymous, int start, int end)
166 throws com.liferay.portal.PortalException,
167 com.liferay.portal.SystemException {
168 return getService()
169 .getGroupThreads(groupId, userId, subscribed,
170 includeAnonymous, start, end);
171 }
172
173 public static int getGroupThreadsCount(long groupId)
174 throws com.liferay.portal.SystemException {
175 return getService().getGroupThreadsCount(groupId);
176 }
177
178 public static int getGroupThreadsCount(long groupId, long userId)
179 throws com.liferay.portal.SystemException {
180 return getService().getGroupThreadsCount(groupId, userId);
181 }
182
183 public static int getGroupThreadsCount(long groupId, long userId,
184 boolean subscribed) throws com.liferay.portal.SystemException {
185 return getService().getGroupThreadsCount(groupId, userId, subscribed);
186 }
187
188 public static int getGroupThreadsCount(long groupId, long userId,
189 boolean subscribed, boolean includeAnonymous)
190 throws com.liferay.portal.SystemException {
191 return getService()
192 .getGroupThreadsCount(groupId, userId, subscribed,
193 includeAnonymous);
194 }
195
196 public static com.liferay.portlet.messageboards.model.MBThread getThread(
197 long threadId)
198 throws com.liferay.portal.PortalException,
199 com.liferay.portal.SystemException {
200 return getService().getThread(threadId);
201 }
202
203 public static java.util.List<com.liferay.portlet.messageboards.model.MBThread> getThreads(
204 long categoryId, int start, int end)
205 throws com.liferay.portal.SystemException {
206 return getService().getThreads(categoryId, start, end);
207 }
208
209 public static int getThreadsCount(long categoryId)
210 throws com.liferay.portal.SystemException {
211 return getService().getThreadsCount(categoryId);
212 }
213
214 public static boolean hasReadThread(long userId, long threadId)
215 throws com.liferay.portal.PortalException,
216 com.liferay.portal.SystemException {
217 return getService().hasReadThread(userId, threadId);
218 }
219
220 public static com.liferay.portlet.messageboards.model.MBThread moveThread(
221 long categoryId, long threadId)
222 throws com.liferay.portal.PortalException,
223 com.liferay.portal.SystemException {
224 return getService().moveThread(categoryId, threadId);
225 }
226
227 public static com.liferay.portlet.messageboards.model.MBThread splitThread(
228 long messageId, javax.portlet.PortletPreferences prefs,
229 com.liferay.portal.theme.ThemeDisplay themeDisplay)
230 throws com.liferay.portal.PortalException,
231 com.liferay.portal.SystemException {
232 return getService().splitThread(messageId, prefs, themeDisplay);
233 }
234
235 public static com.liferay.portlet.messageboards.model.MBThread updateThread(
236 long threadId, int viewCount)
237 throws com.liferay.portal.PortalException,
238 com.liferay.portal.SystemException {
239 return getService().updateThread(threadId, viewCount);
240 }
241
242 public static MBThreadLocalService getService() {
243 if (_service == null) {
244 throw new RuntimeException("MBThreadLocalService is not set");
245 }
246
247 return _service;
248 }
249
250 public void setService(MBThreadLocalService service) {
251 _service = service;
252 }
253
254 private static MBThreadLocalService _service;
255 }