1
22
23 package com.liferay.portlet.journal.service.http;
24
25 import com.liferay.portlet.journal.service.JournalFeedServiceUtil;
26
27 import org.json.JSONObject;
28
29
73 public class JournalFeedServiceJSON {
74 public static JSONObject addFeed(long plid, java.lang.String feedId,
75 boolean autoFeedId, java.lang.String name,
76 java.lang.String description, java.lang.String type,
77 java.lang.String structureId, java.lang.String templateId,
78 java.lang.String rendererTemplateId, int delta,
79 java.lang.String orderByCol, java.lang.String orderByType,
80 java.lang.String targetLayoutFriendlyUrl,
81 java.lang.String targetPortletId, java.lang.String contentField,
82 java.lang.String feedType, double feedVersion,
83 boolean addCommunityPermissions, boolean addGuestPermissions)
84 throws java.rmi.RemoteException, com.liferay.portal.SystemException,
85 com.liferay.portal.PortalException {
86 com.liferay.portlet.journal.model.JournalFeed returnValue = JournalFeedServiceUtil.addFeed(plid,
87 feedId, autoFeedId, name, description, type, structureId,
88 templateId, rendererTemplateId, delta, orderByCol, orderByType,
89 targetLayoutFriendlyUrl, targetPortletId, contentField,
90 feedType, feedVersion, addCommunityPermissions,
91 addGuestPermissions);
92
93 return JournalFeedJSONSerializer.toJSONObject(returnValue);
94 }
95
96 public static JSONObject addFeed(long plid, java.lang.String feedId,
97 boolean autoFeedId, java.lang.String name,
98 java.lang.String description, java.lang.String type,
99 java.lang.String structureId, java.lang.String templateId,
100 java.lang.String rendererTemplateId, int delta,
101 java.lang.String orderByCol, java.lang.String orderByType,
102 java.lang.String targetLayoutFriendlyUrl,
103 java.lang.String targetPortletId, java.lang.String contentField,
104 java.lang.String feedType, double feedVersion,
105 java.lang.String[] communityPermissions,
106 java.lang.String[] guestPermissions)
107 throws java.rmi.RemoteException, com.liferay.portal.SystemException,
108 com.liferay.portal.PortalException {
109 com.liferay.portlet.journal.model.JournalFeed returnValue = JournalFeedServiceUtil.addFeed(plid,
110 feedId, autoFeedId, name, description, type, structureId,
111 templateId, rendererTemplateId, delta, orderByCol, orderByType,
112 targetLayoutFriendlyUrl, targetPortletId, contentField,
113 feedType, feedVersion, communityPermissions, guestPermissions);
114
115 return JournalFeedJSONSerializer.toJSONObject(returnValue);
116 }
117
118 public static void deleteFeed(long groupId, long feedId)
119 throws java.rmi.RemoteException, com.liferay.portal.SystemException,
120 com.liferay.portal.PortalException {
121 JournalFeedServiceUtil.deleteFeed(groupId, feedId);
122 }
123
124 public static void deleteFeed(long groupId, java.lang.String feedId)
125 throws java.rmi.RemoteException, com.liferay.portal.SystemException,
126 com.liferay.portal.PortalException {
127 JournalFeedServiceUtil.deleteFeed(groupId, feedId);
128 }
129
130 public static JSONObject getFeed(long groupId, long feedId)
131 throws java.rmi.RemoteException, com.liferay.portal.SystemException,
132 com.liferay.portal.PortalException {
133 com.liferay.portlet.journal.model.JournalFeed returnValue = JournalFeedServiceUtil.getFeed(groupId,
134 feedId);
135
136 return JournalFeedJSONSerializer.toJSONObject(returnValue);
137 }
138
139 public static JSONObject getFeed(long groupId, java.lang.String feedId)
140 throws java.rmi.RemoteException, com.liferay.portal.SystemException,
141 com.liferay.portal.PortalException {
142 com.liferay.portlet.journal.model.JournalFeed returnValue = JournalFeedServiceUtil.getFeed(groupId,
143 feedId);
144
145 return JournalFeedJSONSerializer.toJSONObject(returnValue);
146 }
147
148 public static JSONObject updateFeed(long groupId, java.lang.String feedId,
149 java.lang.String name, java.lang.String description,
150 java.lang.String type, java.lang.String structureId,
151 java.lang.String templateId, java.lang.String rendererTemplateId,
152 int delta, java.lang.String orderByCol, java.lang.String orderByType,
153 java.lang.String targetLayoutFriendlyUrl,
154 java.lang.String targetPortletId, java.lang.String contentField,
155 java.lang.String feedType, double feedVersion)
156 throws java.rmi.RemoteException, com.liferay.portal.SystemException,
157 com.liferay.portal.PortalException {
158 com.liferay.portlet.journal.model.JournalFeed returnValue = JournalFeedServiceUtil.updateFeed(groupId,
159 feedId, name, description, type, structureId, templateId,
160 rendererTemplateId, delta, orderByCol, orderByType,
161 targetLayoutFriendlyUrl, targetPortletId, contentField,
162 feedType, feedVersion);
163
164 return JournalFeedJSONSerializer.toJSONObject(returnValue);
165 }
166 }