1
22
23 package com.liferay.portlet.polls.service.http;
24
25 import com.liferay.portal.kernel.log.Log;
26 import com.liferay.portal.kernel.log.LogFactoryUtil;
27
28 import com.liferay.portlet.polls.service.PollsQuestionServiceUtil;
29
30 import java.rmi.RemoteException;
31
32
80 public class PollsQuestionServiceSoap {
81 public static com.liferay.portlet.polls.model.PollsQuestionSoap addQuestion(
82 long plid, java.lang.String title, java.lang.String description,
83 int expirationDateMonth, int expirationDateDay, int expirationDateYear,
84 int expirationDateHour, int expirationDateMinute, boolean neverExpire,
85 java.util.List choices, boolean addCommunityPermissions,
86 boolean addGuestPermissions) throws RemoteException {
87 try {
88 com.liferay.portlet.polls.model.PollsQuestion returnValue = PollsQuestionServiceUtil.addQuestion(plid,
89 title, description, expirationDateMonth, expirationDateDay,
90 expirationDateYear, expirationDateHour,
91 expirationDateMinute, neverExpire, choices,
92 addCommunityPermissions, addGuestPermissions);
93
94 return com.liferay.portlet.polls.model.PollsQuestionSoap.toSoapModel(returnValue);
95 }
96 catch (Exception e) {
97 _log.error(e, e);
98 throw new RemoteException(e.getMessage());
99 }
100 }
101
102 public static com.liferay.portlet.polls.model.PollsQuestionSoap addQuestion(
103 long plid, java.lang.String title, java.lang.String description,
104 int expirationDateMonth, int expirationDateDay, int expirationDateYear,
105 int expirationDateHour, int expirationDateMinute, boolean neverExpire,
106 java.util.List choices, java.lang.String[] communityPermissions,
107 java.lang.String[] guestPermissions) throws RemoteException {
108 try {
109 com.liferay.portlet.polls.model.PollsQuestion returnValue = PollsQuestionServiceUtil.addQuestion(plid,
110 title, description, expirationDateMonth, expirationDateDay,
111 expirationDateYear, expirationDateHour,
112 expirationDateMinute, neverExpire, choices,
113 communityPermissions, guestPermissions);
114
115 return com.liferay.portlet.polls.model.PollsQuestionSoap.toSoapModel(returnValue);
116 }
117 catch (Exception e) {
118 _log.error(e, e);
119 throw new RemoteException(e.getMessage());
120 }
121 }
122
123 public static void deleteQuestion(long questionId)
124 throws RemoteException {
125 try {
126 PollsQuestionServiceUtil.deleteQuestion(questionId);
127 }
128 catch (Exception e) {
129 _log.error(e, e);
130 throw new RemoteException(e.getMessage());
131 }
132 }
133
134 public static com.liferay.portlet.polls.model.PollsQuestionSoap getQuestion(
135 long questionId) throws RemoteException {
136 try {
137 com.liferay.portlet.polls.model.PollsQuestion returnValue = PollsQuestionServiceUtil.getQuestion(questionId);
138
139 return com.liferay.portlet.polls.model.PollsQuestionSoap.toSoapModel(returnValue);
140 }
141 catch (Exception e) {
142 _log.error(e, e);
143 throw new RemoteException(e.getMessage());
144 }
145 }
146
147 public static com.liferay.portlet.polls.model.PollsQuestionSoap updateQuestion(
148 long questionId, java.lang.String title, java.lang.String description,
149 int expirationDateMonth, int expirationDateDay, int expirationDateYear,
150 int expirationDateHour, int expirationDateMinute, boolean neverExpire,
151 java.util.List choices) throws RemoteException {
152 try {
153 com.liferay.portlet.polls.model.PollsQuestion returnValue = PollsQuestionServiceUtil.updateQuestion(questionId,
154 title, description, expirationDateMonth, expirationDateDay,
155 expirationDateYear, expirationDateHour,
156 expirationDateMinute, neverExpire, choices);
157
158 return com.liferay.portlet.polls.model.PollsQuestionSoap.toSoapModel(returnValue);
159 }
160 catch (Exception e) {
161 _log.error(e, e);
162 throw new RemoteException(e.getMessage());
163 }
164 }
165
166 private static Log _log = LogFactoryUtil.getLog(PollsQuestionServiceSoap.class);
167 }