001: /**
002: * Copyright (c) 2000-2008 Liferay, Inc. All rights reserved.
003: *
004: * Permission is hereby granted, free of charge, to any person obtaining a copy
005: * of this software and associated documentation files (the "Software"), to deal
006: * in the Software without restriction, including without limitation the rights
007: * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
008: * copies of the Software, and to permit persons to whom the Software is
009: * furnished to do so, subject to the following conditions:
010: *
011: * The above copyright notice and this permission notice shall be included in
012: * all copies or substantial portions of the Software.
013: *
014: * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
015: * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
016: * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
017: * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
018: * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
019: * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
020: * SOFTWARE.
021: */package com.liferay.portlet.bookmarks.service.base;
022:
023: import com.liferay.counter.service.CounterLocalService;
024: import com.liferay.counter.service.CounterLocalServiceFactory;
025: import com.liferay.counter.service.CounterService;
026: import com.liferay.counter.service.CounterServiceFactory;
027:
028: import com.liferay.portal.SystemException;
029: import com.liferay.portal.kernel.dao.DynamicQueryInitializer;
030: import com.liferay.portal.service.ResourceLocalService;
031: import com.liferay.portal.service.ResourceLocalServiceFactory;
032: import com.liferay.portal.service.ResourceService;
033: import com.liferay.portal.service.ResourceServiceFactory;
034: import com.liferay.portal.service.UserLocalService;
035: import com.liferay.portal.service.UserLocalServiceFactory;
036: import com.liferay.portal.service.UserService;
037: import com.liferay.portal.service.UserServiceFactory;
038: import com.liferay.portal.service.persistence.ResourceFinder;
039: import com.liferay.portal.service.persistence.ResourceFinderUtil;
040: import com.liferay.portal.service.persistence.ResourcePersistence;
041: import com.liferay.portal.service.persistence.ResourceUtil;
042: import com.liferay.portal.service.persistence.UserFinder;
043: import com.liferay.portal.service.persistence.UserFinderUtil;
044: import com.liferay.portal.service.persistence.UserPersistence;
045: import com.liferay.portal.service.persistence.UserUtil;
046:
047: import com.liferay.portlet.bookmarks.model.BookmarksEntry;
048: import com.liferay.portlet.bookmarks.model.impl.BookmarksEntryImpl;
049: import com.liferay.portlet.bookmarks.service.BookmarksEntryLocalService;
050: import com.liferay.portlet.bookmarks.service.BookmarksFolderLocalService;
051: import com.liferay.portlet.bookmarks.service.BookmarksFolderLocalServiceFactory;
052: import com.liferay.portlet.bookmarks.service.BookmarksFolderService;
053: import com.liferay.portlet.bookmarks.service.BookmarksFolderServiceFactory;
054: import com.liferay.portlet.bookmarks.service.persistence.BookmarksEntryFinder;
055: import com.liferay.portlet.bookmarks.service.persistence.BookmarksEntryFinderUtil;
056: import com.liferay.portlet.bookmarks.service.persistence.BookmarksEntryPersistence;
057: import com.liferay.portlet.bookmarks.service.persistence.BookmarksEntryUtil;
058: import com.liferay.portlet.bookmarks.service.persistence.BookmarksFolderPersistence;
059: import com.liferay.portlet.bookmarks.service.persistence.BookmarksFolderUtil;
060: import com.liferay.portlet.tags.service.TagsAssetLocalService;
061: import com.liferay.portlet.tags.service.TagsAssetLocalServiceFactory;
062: import com.liferay.portlet.tags.service.TagsAssetService;
063: import com.liferay.portlet.tags.service.TagsAssetServiceFactory;
064: import com.liferay.portlet.tags.service.persistence.TagsAssetFinder;
065: import com.liferay.portlet.tags.service.persistence.TagsAssetFinderUtil;
066: import com.liferay.portlet.tags.service.persistence.TagsAssetPersistence;
067: import com.liferay.portlet.tags.service.persistence.TagsAssetUtil;
068:
069: import org.springframework.beans.factory.InitializingBean;
070:
071: import java.util.List;
072:
073: /**
074: * <a href="BookmarksEntryLocalServiceBaseImpl.java.html"><b><i>View Source</i></b></a>
075: *
076: * @author Brian Wing Shun Chan
077: *
078: */
079: public abstract class BookmarksEntryLocalServiceBaseImpl implements
080: BookmarksEntryLocalService, InitializingBean {
081: public BookmarksEntry addBookmarksEntry(BookmarksEntry model)
082: throws SystemException {
083: BookmarksEntry bookmarksEntry = new BookmarksEntryImpl();
084:
085: bookmarksEntry.setNew(true);
086:
087: bookmarksEntry.setUuid(model.getUuid());
088: bookmarksEntry.setEntryId(model.getEntryId());
089: bookmarksEntry.setCompanyId(model.getCompanyId());
090: bookmarksEntry.setUserId(model.getUserId());
091: bookmarksEntry.setCreateDate(model.getCreateDate());
092: bookmarksEntry.setModifiedDate(model.getModifiedDate());
093: bookmarksEntry.setFolderId(model.getFolderId());
094: bookmarksEntry.setName(model.getName());
095: bookmarksEntry.setUrl(model.getUrl());
096: bookmarksEntry.setComments(model.getComments());
097: bookmarksEntry.setVisits(model.getVisits());
098: bookmarksEntry.setPriority(model.getPriority());
099:
100: return bookmarksEntryPersistence.update(bookmarksEntry);
101: }
102:
103: public List dynamicQuery(DynamicQueryInitializer queryInitializer)
104: throws SystemException {
105: return bookmarksEntryPersistence
106: .findWithDynamicQuery(queryInitializer);
107: }
108:
109: public List dynamicQuery(DynamicQueryInitializer queryInitializer,
110: int begin, int end) throws SystemException {
111: return bookmarksEntryPersistence.findWithDynamicQuery(
112: queryInitializer, begin, end);
113: }
114:
115: public BookmarksEntry updateBookmarksEntry(BookmarksEntry model)
116: throws SystemException {
117: return bookmarksEntryPersistence.update(model, true);
118: }
119:
120: public BookmarksEntryPersistence getBookmarksEntryPersistence() {
121: return bookmarksEntryPersistence;
122: }
123:
124: public void setBookmarksEntryPersistence(
125: BookmarksEntryPersistence bookmarksEntryPersistence) {
126: this .bookmarksEntryPersistence = bookmarksEntryPersistence;
127: }
128:
129: public BookmarksEntryFinder getBookmarksEntryFinder() {
130: return bookmarksEntryFinder;
131: }
132:
133: public void setBookmarksEntryFinder(
134: BookmarksEntryFinder bookmarksEntryFinder) {
135: this .bookmarksEntryFinder = bookmarksEntryFinder;
136: }
137:
138: public BookmarksFolderLocalService getBookmarksFolderLocalService() {
139: return bookmarksFolderLocalService;
140: }
141:
142: public void setBookmarksFolderLocalService(
143: BookmarksFolderLocalService bookmarksFolderLocalService) {
144: this .bookmarksFolderLocalService = bookmarksFolderLocalService;
145: }
146:
147: public BookmarksFolderService getBookmarksFolderService() {
148: return bookmarksFolderService;
149: }
150:
151: public void setBookmarksFolderService(
152: BookmarksFolderService bookmarksFolderService) {
153: this .bookmarksFolderService = bookmarksFolderService;
154: }
155:
156: public BookmarksFolderPersistence getBookmarksFolderPersistence() {
157: return bookmarksFolderPersistence;
158: }
159:
160: public void setBookmarksFolderPersistence(
161: BookmarksFolderPersistence bookmarksFolderPersistence) {
162: this .bookmarksFolderPersistence = bookmarksFolderPersistence;
163: }
164:
165: public CounterLocalService getCounterLocalService() {
166: return counterLocalService;
167: }
168:
169: public void setCounterLocalService(
170: CounterLocalService counterLocalService) {
171: this .counterLocalService = counterLocalService;
172: }
173:
174: public CounterService getCounterService() {
175: return counterService;
176: }
177:
178: public void setCounterService(CounterService counterService) {
179: this .counterService = counterService;
180: }
181:
182: public ResourceLocalService getResourceLocalService() {
183: return resourceLocalService;
184: }
185:
186: public void setResourceLocalService(
187: ResourceLocalService resourceLocalService) {
188: this .resourceLocalService = resourceLocalService;
189: }
190:
191: public ResourceService getResourceService() {
192: return resourceService;
193: }
194:
195: public void setResourceService(ResourceService resourceService) {
196: this .resourceService = resourceService;
197: }
198:
199: public ResourcePersistence getResourcePersistence() {
200: return resourcePersistence;
201: }
202:
203: public void setResourcePersistence(
204: ResourcePersistence resourcePersistence) {
205: this .resourcePersistence = resourcePersistence;
206: }
207:
208: public ResourceFinder getResourceFinder() {
209: return resourceFinder;
210: }
211:
212: public void setResourceFinder(ResourceFinder resourceFinder) {
213: this .resourceFinder = resourceFinder;
214: }
215:
216: public UserLocalService getUserLocalService() {
217: return userLocalService;
218: }
219:
220: public void setUserLocalService(UserLocalService userLocalService) {
221: this .userLocalService = userLocalService;
222: }
223:
224: public UserService getUserService() {
225: return userService;
226: }
227:
228: public void setUserService(UserService userService) {
229: this .userService = userService;
230: }
231:
232: public UserPersistence getUserPersistence() {
233: return userPersistence;
234: }
235:
236: public void setUserPersistence(UserPersistence userPersistence) {
237: this .userPersistence = userPersistence;
238: }
239:
240: public UserFinder getUserFinder() {
241: return userFinder;
242: }
243:
244: public void setUserFinder(UserFinder userFinder) {
245: this .userFinder = userFinder;
246: }
247:
248: public TagsAssetLocalService getTagsAssetLocalService() {
249: return tagsAssetLocalService;
250: }
251:
252: public void setTagsAssetLocalService(
253: TagsAssetLocalService tagsAssetLocalService) {
254: this .tagsAssetLocalService = tagsAssetLocalService;
255: }
256:
257: public TagsAssetService getTagsAssetService() {
258: return tagsAssetService;
259: }
260:
261: public void setTagsAssetService(TagsAssetService tagsAssetService) {
262: this .tagsAssetService = tagsAssetService;
263: }
264:
265: public TagsAssetPersistence getTagsAssetPersistence() {
266: return tagsAssetPersistence;
267: }
268:
269: public void setTagsAssetPersistence(
270: TagsAssetPersistence tagsAssetPersistence) {
271: this .tagsAssetPersistence = tagsAssetPersistence;
272: }
273:
274: public TagsAssetFinder getTagsAssetFinder() {
275: return tagsAssetFinder;
276: }
277:
278: public void setTagsAssetFinder(TagsAssetFinder tagsAssetFinder) {
279: this .tagsAssetFinder = tagsAssetFinder;
280: }
281:
282: public void afterPropertiesSet() {
283: if (bookmarksEntryPersistence == null) {
284: bookmarksEntryPersistence = BookmarksEntryUtil
285: .getPersistence();
286: }
287:
288: if (bookmarksEntryFinder == null) {
289: bookmarksEntryFinder = BookmarksEntryFinderUtil.getFinder();
290: }
291:
292: if (bookmarksFolderLocalService == null) {
293: bookmarksFolderLocalService = BookmarksFolderLocalServiceFactory
294: .getImpl();
295: }
296:
297: if (bookmarksFolderService == null) {
298: bookmarksFolderService = BookmarksFolderServiceFactory
299: .getImpl();
300: }
301:
302: if (bookmarksFolderPersistence == null) {
303: bookmarksFolderPersistence = BookmarksFolderUtil
304: .getPersistence();
305: }
306:
307: if (counterLocalService == null) {
308: counterLocalService = CounterLocalServiceFactory.getImpl();
309: }
310:
311: if (counterService == null) {
312: counterService = CounterServiceFactory.getImpl();
313: }
314:
315: if (resourceLocalService == null) {
316: resourceLocalService = ResourceLocalServiceFactory
317: .getImpl();
318: }
319:
320: if (resourceService == null) {
321: resourceService = ResourceServiceFactory.getImpl();
322: }
323:
324: if (resourcePersistence == null) {
325: resourcePersistence = ResourceUtil.getPersistence();
326: }
327:
328: if (resourceFinder == null) {
329: resourceFinder = ResourceFinderUtil.getFinder();
330: }
331:
332: if (userLocalService == null) {
333: userLocalService = UserLocalServiceFactory.getImpl();
334: }
335:
336: if (userService == null) {
337: userService = UserServiceFactory.getImpl();
338: }
339:
340: if (userPersistence == null) {
341: userPersistence = UserUtil.getPersistence();
342: }
343:
344: if (userFinder == null) {
345: userFinder = UserFinderUtil.getFinder();
346: }
347:
348: if (tagsAssetLocalService == null) {
349: tagsAssetLocalService = TagsAssetLocalServiceFactory
350: .getImpl();
351: }
352:
353: if (tagsAssetService == null) {
354: tagsAssetService = TagsAssetServiceFactory.getImpl();
355: }
356:
357: if (tagsAssetPersistence == null) {
358: tagsAssetPersistence = TagsAssetUtil.getPersistence();
359: }
360:
361: if (tagsAssetFinder == null) {
362: tagsAssetFinder = TagsAssetFinderUtil.getFinder();
363: }
364: }
365:
366: protected BookmarksEntryPersistence bookmarksEntryPersistence;
367: protected BookmarksEntryFinder bookmarksEntryFinder;
368: protected BookmarksFolderLocalService bookmarksFolderLocalService;
369: protected BookmarksFolderService bookmarksFolderService;
370: protected BookmarksFolderPersistence bookmarksFolderPersistence;
371: protected CounterLocalService counterLocalService;
372: protected CounterService counterService;
373: protected ResourceLocalService resourceLocalService;
374: protected ResourceService resourceService;
375: protected ResourcePersistence resourcePersistence;
376: protected ResourceFinder resourceFinder;
377: protected UserLocalService userLocalService;
378: protected UserService userService;
379: protected UserPersistence userPersistence;
380: protected UserFinder userFinder;
381: protected TagsAssetLocalService tagsAssetLocalService;
382: protected TagsAssetService tagsAssetService;
383: protected TagsAssetPersistence tagsAssetPersistence;
384: protected TagsAssetFinder tagsAssetFinder;
385: }
|