001
014
015 package com.liferay.portlet.polls.service;
016
017 import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
018 import com.liferay.portal.kernel.util.ReferenceRegistry;
019
020
033 public class PollsQuestionServiceUtil {
034
039
040
045 public static java.lang.String getBeanIdentifier() {
046 return getService().getBeanIdentifier();
047 }
048
049
054 public static void setBeanIdentifier(java.lang.String beanIdentifier) {
055 getService().setBeanIdentifier(beanIdentifier);
056 }
057
058 public static com.liferay.portlet.polls.model.PollsQuestion addQuestion(
059 java.util.Map<java.util.Locale, java.lang.String> titleMap,
060 java.util.Map<java.util.Locale, java.lang.String> descriptionMap,
061 int expirationDateMonth, int expirationDateDay, int expirationDateYear,
062 int expirationDateHour, int expirationDateMinute, boolean neverExpire,
063 java.util.List<com.liferay.portlet.polls.model.PollsChoice> choices,
064 com.liferay.portal.service.ServiceContext serviceContext)
065 throws com.liferay.portal.kernel.exception.PortalException,
066 com.liferay.portal.kernel.exception.SystemException {
067 return getService()
068 .addQuestion(titleMap, descriptionMap, expirationDateMonth,
069 expirationDateDay, expirationDateYear, expirationDateHour,
070 expirationDateMinute, neverExpire, choices, serviceContext);
071 }
072
073 public static void deleteQuestion(long questionId)
074 throws com.liferay.portal.kernel.exception.PortalException,
075 com.liferay.portal.kernel.exception.SystemException {
076 getService().deleteQuestion(questionId);
077 }
078
079 public static com.liferay.portlet.polls.model.PollsQuestion getQuestion(
080 long questionId)
081 throws com.liferay.portal.kernel.exception.PortalException,
082 com.liferay.portal.kernel.exception.SystemException {
083 return getService().getQuestion(questionId);
084 }
085
086 public static com.liferay.portlet.polls.model.PollsQuestion updateQuestion(
087 long questionId,
088 java.util.Map<java.util.Locale, java.lang.String> titleMap,
089 java.util.Map<java.util.Locale, java.lang.String> descriptionMap,
090 int expirationDateMonth, int expirationDateDay, int expirationDateYear,
091 int expirationDateHour, int expirationDateMinute, boolean neverExpire,
092 java.util.List<com.liferay.portlet.polls.model.PollsChoice> choices,
093 com.liferay.portal.service.ServiceContext serviceContext)
094 throws com.liferay.portal.kernel.exception.PortalException,
095 com.liferay.portal.kernel.exception.SystemException {
096 return getService()
097 .updateQuestion(questionId, titleMap, descriptionMap,
098 expirationDateMonth, expirationDateDay, expirationDateYear,
099 expirationDateHour, expirationDateMinute, neverExpire, choices,
100 serviceContext);
101 }
102
103 public static PollsQuestionService getService() {
104 if (_service == null) {
105 _service = (PollsQuestionService)PortalBeanLocatorUtil.locate(PollsQuestionService.class.getName());
106
107 ReferenceRegistry.registerReference(PollsQuestionServiceUtil.class,
108 "_service");
109 }
110
111 return _service;
112 }
113
114
117 public void setService(PollsQuestionService service) {
118 }
119
120 private static PollsQuestionService _service;
121 }