1
22
23 package com.liferay.portal.service.persistence;
24
25 import com.liferay.portal.NoSuchPortletItemException;
26 import com.liferay.portal.SystemException;
27 import com.liferay.portal.kernel.annotation.BeanReference;
28 import com.liferay.portal.kernel.cache.CacheRegistry;
29 import com.liferay.portal.kernel.dao.orm.DynamicQuery;
30 import com.liferay.portal.kernel.dao.orm.EntityCacheUtil;
31 import com.liferay.portal.kernel.dao.orm.FinderCacheUtil;
32 import com.liferay.portal.kernel.dao.orm.FinderPath;
33 import com.liferay.portal.kernel.dao.orm.Query;
34 import com.liferay.portal.kernel.dao.orm.QueryPos;
35 import com.liferay.portal.kernel.dao.orm.QueryUtil;
36 import com.liferay.portal.kernel.dao.orm.Session;
37 import com.liferay.portal.kernel.log.Log;
38 import com.liferay.portal.kernel.log.LogFactoryUtil;
39 import com.liferay.portal.kernel.util.GetterUtil;
40 import com.liferay.portal.kernel.util.OrderByComparator;
41 import com.liferay.portal.kernel.util.StringPool;
42 import com.liferay.portal.kernel.util.StringUtil;
43 import com.liferay.portal.kernel.util.Validator;
44 import com.liferay.portal.model.ModelListener;
45 import com.liferay.portal.model.PortletItem;
46 import com.liferay.portal.model.impl.PortletItemImpl;
47 import com.liferay.portal.model.impl.PortletItemModelImpl;
48 import com.liferay.portal.service.persistence.impl.BasePersistenceImpl;
49
50 import java.util.ArrayList;
51 import java.util.Collections;
52 import java.util.List;
53
54
60 public class PortletItemPersistenceImpl extends BasePersistenceImpl
61 implements PortletItemPersistence {
62 public static final String FINDER_CLASS_NAME_ENTITY = PortletItemImpl.class.getName();
63 public static final String FINDER_CLASS_NAME_LIST = FINDER_CLASS_NAME_ENTITY +
64 ".List";
65 public static final FinderPath FINDER_PATH_FIND_BY_G_C = new FinderPath(PortletItemModelImpl.ENTITY_CACHE_ENABLED,
66 PortletItemModelImpl.FINDER_CACHE_ENABLED, FINDER_CLASS_NAME_LIST,
67 "findByG_C",
68 new String[] { Long.class.getName(), Long.class.getName() });
69 public static final FinderPath FINDER_PATH_FIND_BY_OBC_G_C = new FinderPath(PortletItemModelImpl.ENTITY_CACHE_ENABLED,
70 PortletItemModelImpl.FINDER_CACHE_ENABLED, FINDER_CLASS_NAME_LIST,
71 "findByG_C",
72 new String[] {
73 Long.class.getName(), Long.class.getName(),
74
75 "java.lang.Integer", "java.lang.Integer",
76 "com.liferay.portal.kernel.util.OrderByComparator"
77 });
78 public static final FinderPath FINDER_PATH_COUNT_BY_G_C = new FinderPath(PortletItemModelImpl.ENTITY_CACHE_ENABLED,
79 PortletItemModelImpl.FINDER_CACHE_ENABLED, FINDER_CLASS_NAME_LIST,
80 "countByG_C",
81 new String[] { Long.class.getName(), Long.class.getName() });
82 public static final FinderPath FINDER_PATH_FIND_BY_G_P_C = new FinderPath(PortletItemModelImpl.ENTITY_CACHE_ENABLED,
83 PortletItemModelImpl.FINDER_CACHE_ENABLED, FINDER_CLASS_NAME_LIST,
84 "findByG_P_C",
85 new String[] {
86 Long.class.getName(), String.class.getName(),
87 Long.class.getName()
88 });
89 public static final FinderPath FINDER_PATH_FIND_BY_OBC_G_P_C = new FinderPath(PortletItemModelImpl.ENTITY_CACHE_ENABLED,
90 PortletItemModelImpl.FINDER_CACHE_ENABLED, FINDER_CLASS_NAME_LIST,
91 "findByG_P_C",
92 new String[] {
93 Long.class.getName(), String.class.getName(),
94 Long.class.getName(),
95
96 "java.lang.Integer", "java.lang.Integer",
97 "com.liferay.portal.kernel.util.OrderByComparator"
98 });
99 public static final FinderPath FINDER_PATH_COUNT_BY_G_P_C = new FinderPath(PortletItemModelImpl.ENTITY_CACHE_ENABLED,
100 PortletItemModelImpl.FINDER_CACHE_ENABLED, FINDER_CLASS_NAME_LIST,
101 "countByG_P_C",
102 new String[] {
103 Long.class.getName(), String.class.getName(),
104 Long.class.getName()
105 });
106 public static final FinderPath FINDER_PATH_FETCH_BY_G_N_P_C = new FinderPath(PortletItemModelImpl.ENTITY_CACHE_ENABLED,
107 PortletItemModelImpl.FINDER_CACHE_ENABLED,
108 FINDER_CLASS_NAME_ENTITY, "fetchByG_N_P_C",
109 new String[] {
110 Long.class.getName(), String.class.getName(),
111 String.class.getName(), Long.class.getName()
112 });
113 public static final FinderPath FINDER_PATH_COUNT_BY_G_N_P_C = new FinderPath(PortletItemModelImpl.ENTITY_CACHE_ENABLED,
114 PortletItemModelImpl.FINDER_CACHE_ENABLED, FINDER_CLASS_NAME_LIST,
115 "countByG_N_P_C",
116 new String[] {
117 Long.class.getName(), String.class.getName(),
118 String.class.getName(), Long.class.getName()
119 });
120 public static final FinderPath FINDER_PATH_FIND_ALL = new FinderPath(PortletItemModelImpl.ENTITY_CACHE_ENABLED,
121 PortletItemModelImpl.FINDER_CACHE_ENABLED, FINDER_CLASS_NAME_LIST,
122 "findAll", new String[0]);
123 public static final FinderPath FINDER_PATH_COUNT_ALL = new FinderPath(PortletItemModelImpl.ENTITY_CACHE_ENABLED,
124 PortletItemModelImpl.FINDER_CACHE_ENABLED, FINDER_CLASS_NAME_LIST,
125 "countAll", new String[0]);
126
127 public void cacheResult(PortletItem portletItem) {
128 EntityCacheUtil.putResult(PortletItemModelImpl.ENTITY_CACHE_ENABLED,
129 PortletItemImpl.class, portletItem.getPrimaryKey(), portletItem);
130
131 FinderCacheUtil.putResult(FINDER_PATH_FETCH_BY_G_N_P_C,
132 new Object[] {
133 new Long(portletItem.getGroupId()),
134
135 portletItem.getName(),
136
137 portletItem.getPortletId(), new Long(portletItem.getClassNameId())
138 }, portletItem);
139 }
140
141 public void cacheResult(List<PortletItem> portletItems) {
142 for (PortletItem portletItem : portletItems) {
143 if (EntityCacheUtil.getResult(
144 PortletItemModelImpl.ENTITY_CACHE_ENABLED,
145 PortletItemImpl.class, portletItem.getPrimaryKey(), this) == null) {
146 cacheResult(portletItem);
147 }
148 }
149 }
150
151 public void clearCache() {
152 CacheRegistry.clear(PortletItemImpl.class.getName());
153 EntityCacheUtil.clearCache(PortletItemImpl.class.getName());
154 FinderCacheUtil.clearCache(FINDER_CLASS_NAME_ENTITY);
155 FinderCacheUtil.clearCache(FINDER_CLASS_NAME_LIST);
156 }
157
158 public PortletItem create(long portletItemId) {
159 PortletItem portletItem = new PortletItemImpl();
160
161 portletItem.setNew(true);
162 portletItem.setPrimaryKey(portletItemId);
163
164 return portletItem;
165 }
166
167 public PortletItem remove(long portletItemId)
168 throws NoSuchPortletItemException, SystemException {
169 Session session = null;
170
171 try {
172 session = openSession();
173
174 PortletItem portletItem = (PortletItem)session.get(PortletItemImpl.class,
175 new Long(portletItemId));
176
177 if (portletItem == null) {
178 if (_log.isWarnEnabled()) {
179 _log.warn("No PortletItem exists with the primary key " +
180 portletItemId);
181 }
182
183 throw new NoSuchPortletItemException(
184 "No PortletItem exists with the primary key " +
185 portletItemId);
186 }
187
188 return remove(portletItem);
189 }
190 catch (NoSuchPortletItemException nsee) {
191 throw nsee;
192 }
193 catch (Exception e) {
194 throw processException(e);
195 }
196 finally {
197 closeSession(session);
198 }
199 }
200
201 public PortletItem remove(PortletItem portletItem)
202 throws SystemException {
203 for (ModelListener<PortletItem> listener : listeners) {
204 listener.onBeforeRemove(portletItem);
205 }
206
207 portletItem = removeImpl(portletItem);
208
209 for (ModelListener<PortletItem> listener : listeners) {
210 listener.onAfterRemove(portletItem);
211 }
212
213 return portletItem;
214 }
215
216 protected PortletItem removeImpl(PortletItem portletItem)
217 throws SystemException {
218 Session session = null;
219
220 try {
221 session = openSession();
222
223 if (portletItem.isCachedModel() || BatchSessionUtil.isEnabled()) {
224 Object staleObject = session.get(PortletItemImpl.class,
225 portletItem.getPrimaryKeyObj());
226
227 if (staleObject != null) {
228 session.evict(staleObject);
229 }
230 }
231
232 session.delete(portletItem);
233
234 session.flush();
235 }
236 catch (Exception e) {
237 throw processException(e);
238 }
239 finally {
240 closeSession(session);
241 }
242
243 FinderCacheUtil.clearCache(FINDER_CLASS_NAME_LIST);
244
245 PortletItemModelImpl portletItemModelImpl = (PortletItemModelImpl)portletItem;
246
247 FinderCacheUtil.removeResult(FINDER_PATH_FETCH_BY_G_N_P_C,
248 new Object[] {
249 new Long(portletItemModelImpl.getOriginalGroupId()),
250
251 portletItemModelImpl.getOriginalName(),
252
253 portletItemModelImpl.getOriginalPortletId(),
254 new Long(portletItemModelImpl.getOriginalClassNameId())
255 });
256
257 EntityCacheUtil.removeResult(PortletItemModelImpl.ENTITY_CACHE_ENABLED,
258 PortletItemImpl.class, portletItem.getPrimaryKey());
259
260 return portletItem;
261 }
262
263
266 public PortletItem update(PortletItem portletItem)
267 throws SystemException {
268 if (_log.isWarnEnabled()) {
269 _log.warn(
270 "Using the deprecated update(PortletItem portletItem) method. Use update(PortletItem portletItem, boolean merge) instead.");
271 }
272
273 return update(portletItem, false);
274 }
275
276
289 public PortletItem update(PortletItem portletItem, boolean merge)
290 throws SystemException {
291 boolean isNew = portletItem.isNew();
292
293 for (ModelListener<PortletItem> listener : listeners) {
294 if (isNew) {
295 listener.onBeforeCreate(portletItem);
296 }
297 else {
298 listener.onBeforeUpdate(portletItem);
299 }
300 }
301
302 portletItem = updateImpl(portletItem, merge);
303
304 for (ModelListener<PortletItem> listener : listeners) {
305 if (isNew) {
306 listener.onAfterCreate(portletItem);
307 }
308 else {
309 listener.onAfterUpdate(portletItem);
310 }
311 }
312
313 return portletItem;
314 }
315
316 public PortletItem updateImpl(
317 com.liferay.portal.model.PortletItem portletItem, boolean merge)
318 throws SystemException {
319 boolean isNew = portletItem.isNew();
320
321 PortletItemModelImpl portletItemModelImpl = (PortletItemModelImpl)portletItem;
322
323 Session session = null;
324
325 try {
326 session = openSession();
327
328 BatchSessionUtil.update(session, portletItem, merge);
329
330 portletItem.setNew(false);
331 }
332 catch (Exception e) {
333 throw processException(e);
334 }
335 finally {
336 closeSession(session);
337 }
338
339 FinderCacheUtil.clearCache(FINDER_CLASS_NAME_LIST);
340
341 EntityCacheUtil.putResult(PortletItemModelImpl.ENTITY_CACHE_ENABLED,
342 PortletItemImpl.class, portletItem.getPrimaryKey(), portletItem);
343
344 if (!isNew &&
345 ((portletItem.getGroupId() != portletItemModelImpl.getOriginalGroupId()) ||
346 !Validator.equals(portletItem.getName(),
347 portletItemModelImpl.getOriginalName()) ||
348 !Validator.equals(portletItem.getPortletId(),
349 portletItemModelImpl.getOriginalPortletId()) ||
350 (portletItem.getClassNameId() != portletItemModelImpl.getOriginalClassNameId()))) {
351 FinderCacheUtil.removeResult(FINDER_PATH_FETCH_BY_G_N_P_C,
352 new Object[] {
353 new Long(portletItemModelImpl.getOriginalGroupId()),
354
355 portletItemModelImpl.getOriginalName(),
356
357 portletItemModelImpl.getOriginalPortletId(),
358 new Long(portletItemModelImpl.getOriginalClassNameId())
359 });
360 }
361
362 if (isNew ||
363 ((portletItem.getGroupId() != portletItemModelImpl.getOriginalGroupId()) ||
364 !Validator.equals(portletItem.getName(),
365 portletItemModelImpl.getOriginalName()) ||
366 !Validator.equals(portletItem.getPortletId(),
367 portletItemModelImpl.getOriginalPortletId()) ||
368 (portletItem.getClassNameId() != portletItemModelImpl.getOriginalClassNameId()))) {
369 FinderCacheUtil.putResult(FINDER_PATH_FETCH_BY_G_N_P_C,
370 new Object[] {
371 new Long(portletItem.getGroupId()),
372
373 portletItem.getName(),
374
375 portletItem.getPortletId(),
376 new Long(portletItem.getClassNameId())
377 }, portletItem);
378 }
379
380 return portletItem;
381 }
382
383 public PortletItem findByPrimaryKey(long portletItemId)
384 throws NoSuchPortletItemException, SystemException {
385 PortletItem portletItem = fetchByPrimaryKey(portletItemId);
386
387 if (portletItem == null) {
388 if (_log.isWarnEnabled()) {
389 _log.warn("No PortletItem exists with the primary key " +
390 portletItemId);
391 }
392
393 throw new NoSuchPortletItemException(
394 "No PortletItem exists with the primary key " + portletItemId);
395 }
396
397 return portletItem;
398 }
399
400 public PortletItem fetchByPrimaryKey(long portletItemId)
401 throws SystemException {
402 PortletItem portletItem = (PortletItem)EntityCacheUtil.getResult(PortletItemModelImpl.ENTITY_CACHE_ENABLED,
403 PortletItemImpl.class, portletItemId, this);
404
405 if (portletItem == null) {
406 Session session = null;
407
408 try {
409 session = openSession();
410
411 portletItem = (PortletItem)session.get(PortletItemImpl.class,
412 new Long(portletItemId));
413 }
414 catch (Exception e) {
415 throw processException(e);
416 }
417 finally {
418 if (portletItem != null) {
419 cacheResult(portletItem);
420 }
421
422 closeSession(session);
423 }
424 }
425
426 return portletItem;
427 }
428
429 public List<PortletItem> findByG_C(long groupId, long classNameId)
430 throws SystemException {
431 Object[] finderArgs = new Object[] {
432 new Long(groupId), new Long(classNameId)
433 };
434
435 List<PortletItem> list = (List<PortletItem>)FinderCacheUtil.getResult(FINDER_PATH_FIND_BY_G_C,
436 finderArgs, this);
437
438 if (list == null) {
439 Session session = null;
440
441 try {
442 session = openSession();
443
444 StringBuilder query = new StringBuilder();
445
446 query.append("FROM com.liferay.portal.model.PortletItem WHERE ");
447
448 query.append("groupId = ?");
449
450 query.append(" AND ");
451
452 query.append("classNameId = ?");
453
454 query.append(" ");
455
456 Query q = session.createQuery(query.toString());
457
458 QueryPos qPos = QueryPos.getInstance(q);
459
460 qPos.add(groupId);
461
462 qPos.add(classNameId);
463
464 list = q.list();
465 }
466 catch (Exception e) {
467 throw processException(e);
468 }
469 finally {
470 if (list == null) {
471 list = new ArrayList<PortletItem>();
472 }
473
474 cacheResult(list);
475
476 FinderCacheUtil.putResult(FINDER_PATH_FIND_BY_G_C, finderArgs,
477 list);
478
479 closeSession(session);
480 }
481 }
482
483 return list;
484 }
485
486 public List<PortletItem> findByG_C(long groupId, long classNameId,
487 int start, int end) throws SystemException {
488 return findByG_C(groupId, classNameId, start, end, null);
489 }
490
491 public List<PortletItem> findByG_C(long groupId, long classNameId,
492 int start, int end, OrderByComparator obc) throws SystemException {
493 Object[] finderArgs = new Object[] {
494 new Long(groupId), new Long(classNameId),
495
496 String.valueOf(start), String.valueOf(end), String.valueOf(obc)
497 };
498
499 List<PortletItem> list = (List<PortletItem>)FinderCacheUtil.getResult(FINDER_PATH_FIND_BY_OBC_G_C,
500 finderArgs, this);
501
502 if (list == null) {
503 Session session = null;
504
505 try {
506 session = openSession();
507
508 StringBuilder query = new StringBuilder();
509
510 query.append("FROM com.liferay.portal.model.PortletItem WHERE ");
511
512 query.append("groupId = ?");
513
514 query.append(" AND ");
515
516 query.append("classNameId = ?");
517
518 query.append(" ");
519
520 if (obc != null) {
521 query.append("ORDER BY ");
522 query.append(obc.getOrderBy());
523 }
524
525 Query q = session.createQuery(query.toString());
526
527 QueryPos qPos = QueryPos.getInstance(q);
528
529 qPos.add(groupId);
530
531 qPos.add(classNameId);
532
533 list = (List<PortletItem>)QueryUtil.list(q, getDialect(),
534 start, end);
535 }
536 catch (Exception e) {
537 throw processException(e);
538 }
539 finally {
540 if (list == null) {
541 list = new ArrayList<PortletItem>();
542 }
543
544 cacheResult(list);
545
546 FinderCacheUtil.putResult(FINDER_PATH_FIND_BY_OBC_G_C,
547 finderArgs, list);
548
549 closeSession(session);
550 }
551 }
552
553 return list;
554 }
555
556 public PortletItem findByG_C_First(long groupId, long classNameId,
557 OrderByComparator obc)
558 throws NoSuchPortletItemException, SystemException {
559 List<PortletItem> list = findByG_C(groupId, classNameId, 0, 1, obc);
560
561 if (list.isEmpty()) {
562 StringBuilder msg = new StringBuilder();
563
564 msg.append("No PortletItem exists with the key {");
565
566 msg.append("groupId=" + groupId);
567
568 msg.append(", ");
569 msg.append("classNameId=" + classNameId);
570
571 msg.append(StringPool.CLOSE_CURLY_BRACE);
572
573 throw new NoSuchPortletItemException(msg.toString());
574 }
575 else {
576 return list.get(0);
577 }
578 }
579
580 public PortletItem findByG_C_Last(long groupId, long classNameId,
581 OrderByComparator obc)
582 throws NoSuchPortletItemException, SystemException {
583 int count = countByG_C(groupId, classNameId);
584
585 List<PortletItem> list = findByG_C(groupId, classNameId, count - 1,
586 count, obc);
587
588 if (list.isEmpty()) {
589 StringBuilder msg = new StringBuilder();
590
591 msg.append("No PortletItem exists with the key {");
592
593 msg.append("groupId=" + groupId);
594
595 msg.append(", ");
596 msg.append("classNameId=" + classNameId);
597
598 msg.append(StringPool.CLOSE_CURLY_BRACE);
599
600 throw new NoSuchPortletItemException(msg.toString());
601 }
602 else {
603 return list.get(0);
604 }
605 }
606
607 public PortletItem[] findByG_C_PrevAndNext(long portletItemId,
608 long groupId, long classNameId, OrderByComparator obc)
609 throws NoSuchPortletItemException, SystemException {
610 PortletItem portletItem = findByPrimaryKey(portletItemId);
611
612 int count = countByG_C(groupId, classNameId);
613
614 Session session = null;
615
616 try {
617 session = openSession();
618
619 StringBuilder query = new StringBuilder();
620
621 query.append("FROM com.liferay.portal.model.PortletItem WHERE ");
622
623 query.append("groupId = ?");
624
625 query.append(" AND ");
626
627 query.append("classNameId = ?");
628
629 query.append(" ");
630
631 if (obc != null) {
632 query.append("ORDER BY ");
633 query.append(obc.getOrderBy());
634 }
635
636 Query q = session.createQuery(query.toString());
637
638 QueryPos qPos = QueryPos.getInstance(q);
639
640 qPos.add(groupId);
641
642 qPos.add(classNameId);
643
644 Object[] objArray = QueryUtil.getPrevAndNext(q, count, obc,
645 portletItem);
646
647 PortletItem[] array = new PortletItemImpl[3];
648
649 array[0] = (PortletItem)objArray[0];
650 array[1] = (PortletItem)objArray[1];
651 array[2] = (PortletItem)objArray[2];
652
653 return array;
654 }
655 catch (Exception e) {
656 throw processException(e);
657 }
658 finally {
659 closeSession(session);
660 }
661 }
662
663 public List<PortletItem> findByG_P_C(long groupId, String portletId,
664 long classNameId) throws SystemException {
665 Object[] finderArgs = new Object[] {
666 new Long(groupId),
667
668 portletId, new Long(classNameId)
669 };
670
671 List<PortletItem> list = (List<PortletItem>)FinderCacheUtil.getResult(FINDER_PATH_FIND_BY_G_P_C,
672 finderArgs, this);
673
674 if (list == null) {
675 Session session = null;
676
677 try {
678 session = openSession();
679
680 StringBuilder query = new StringBuilder();
681
682 query.append("FROM com.liferay.portal.model.PortletItem WHERE ");
683
684 query.append("groupId = ?");
685
686 query.append(" AND ");
687
688 if (portletId == null) {
689 query.append("portletId IS NULL");
690 }
691 else {
692 query.append("portletId = ?");
693 }
694
695 query.append(" AND ");
696
697 query.append("classNameId = ?");
698
699 query.append(" ");
700
701 Query q = session.createQuery(query.toString());
702
703 QueryPos qPos = QueryPos.getInstance(q);
704
705 qPos.add(groupId);
706
707 if (portletId != null) {
708 qPos.add(portletId);
709 }
710
711 qPos.add(classNameId);
712
713 list = q.list();
714 }
715 catch (Exception e) {
716 throw processException(e);
717 }
718 finally {
719 if (list == null) {
720 list = new ArrayList<PortletItem>();
721 }
722
723 cacheResult(list);
724
725 FinderCacheUtil.putResult(FINDER_PATH_FIND_BY_G_P_C,
726 finderArgs, list);
727
728 closeSession(session);
729 }
730 }
731
732 return list;
733 }
734
735 public List<PortletItem> findByG_P_C(long groupId, String portletId,
736 long classNameId, int start, int end) throws SystemException {
737 return findByG_P_C(groupId, portletId, classNameId, start, end, null);
738 }
739
740 public List<PortletItem> findByG_P_C(long groupId, String portletId,
741 long classNameId, int start, int end, OrderByComparator obc)
742 throws SystemException {
743 Object[] finderArgs = new Object[] {
744 new Long(groupId),
745
746 portletId, new Long(classNameId),
747
748 String.valueOf(start), String.valueOf(end), String.valueOf(obc)
749 };
750
751 List<PortletItem> list = (List<PortletItem>)FinderCacheUtil.getResult(FINDER_PATH_FIND_BY_OBC_G_P_C,
752 finderArgs, this);
753
754 if (list == null) {
755 Session session = null;
756
757 try {
758 session = openSession();
759
760 StringBuilder query = new StringBuilder();
761
762 query.append("FROM com.liferay.portal.model.PortletItem WHERE ");
763
764 query.append("groupId = ?");
765
766 query.append(" AND ");
767
768 if (portletId == null) {
769 query.append("portletId IS NULL");
770 }
771 else {
772 query.append("portletId = ?");
773 }
774
775 query.append(" AND ");
776
777 query.append("classNameId = ?");
778
779 query.append(" ");
780
781 if (obc != null) {
782 query.append("ORDER BY ");
783 query.append(obc.getOrderBy());
784 }
785
786 Query q = session.createQuery(query.toString());
787
788 QueryPos qPos = QueryPos.getInstance(q);
789
790 qPos.add(groupId);
791
792 if (portletId != null) {
793 qPos.add(portletId);
794 }
795
796 qPos.add(classNameId);
797
798 list = (List<PortletItem>)QueryUtil.list(q, getDialect(),
799 start, end);
800 }
801 catch (Exception e) {
802 throw processException(e);
803 }
804 finally {
805 if (list == null) {
806 list = new ArrayList<PortletItem>();
807 }
808
809 cacheResult(list);
810
811 FinderCacheUtil.putResult(FINDER_PATH_FIND_BY_OBC_G_P_C,
812 finderArgs, list);
813
814 closeSession(session);
815 }
816 }
817
818 return list;
819 }
820
821 public PortletItem findByG_P_C_First(long groupId, String portletId,
822 long classNameId, OrderByComparator obc)
823 throws NoSuchPortletItemException, SystemException {
824 List<PortletItem> list = findByG_P_C(groupId, portletId, classNameId,
825 0, 1, obc);
826
827 if (list.isEmpty()) {
828 StringBuilder msg = new StringBuilder();
829
830 msg.append("No PortletItem exists with the key {");
831
832 msg.append("groupId=" + groupId);
833
834 msg.append(", ");
835 msg.append("portletId=" + portletId);
836
837 msg.append(", ");
838 msg.append("classNameId=" + classNameId);
839
840 msg.append(StringPool.CLOSE_CURLY_BRACE);
841
842 throw new NoSuchPortletItemException(msg.toString());
843 }
844 else {
845 return list.get(0);
846 }
847 }
848
849 public PortletItem findByG_P_C_Last(long groupId, String portletId,
850 long classNameId, OrderByComparator obc)
851 throws NoSuchPortletItemException, SystemException {
852 int count = countByG_P_C(groupId, portletId, classNameId);
853
854 List<PortletItem> list = findByG_P_C(groupId, portletId, classNameId,
855 count - 1, count, obc);
856
857 if (list.isEmpty()) {
858 StringBuilder msg = new StringBuilder();
859
860 msg.append("No PortletItem exists with the key {");
861
862 msg.append("groupId=" + groupId);
863
864 msg.append(", ");
865 msg.append("portletId=" + portletId);
866
867 msg.append(", ");
868 msg.append("classNameId=" + classNameId);
869
870 msg.append(StringPool.CLOSE_CURLY_BRACE);
871
872 throw new NoSuchPortletItemException(msg.toString());
873 }
874 else {
875 return list.get(0);
876 }
877 }
878
879 public PortletItem[] findByG_P_C_PrevAndNext(long portletItemId,
880 long groupId, String portletId, long classNameId, OrderByComparator obc)
881 throws NoSuchPortletItemException, SystemException {
882 PortletItem portletItem = findByPrimaryKey(portletItemId);
883
884 int count = countByG_P_C(groupId, portletId, classNameId);
885
886 Session session = null;
887
888 try {
889 session = openSession();
890
891 StringBuilder query = new StringBuilder();
892
893 query.append("FROM com.liferay.portal.model.PortletItem WHERE ");
894
895 query.append("groupId = ?");
896
897 query.append(" AND ");
898
899 if (portletId == null) {
900 query.append("portletId IS NULL");
901 }
902 else {
903 query.append("portletId = ?");
904 }
905
906 query.append(" AND ");
907
908 query.append("classNameId = ?");
909
910 query.append(" ");
911
912 if (obc != null) {
913 query.append("ORDER BY ");
914 query.append(obc.getOrderBy());
915 }
916
917 Query q = session.createQuery(query.toString());
918
919 QueryPos qPos = QueryPos.getInstance(q);
920
921 qPos.add(groupId);
922
923 if (portletId != null) {
924 qPos.add(portletId);
925 }
926
927 qPos.add(classNameId);
928
929 Object[] objArray = QueryUtil.getPrevAndNext(q, count, obc,
930 portletItem);
931
932 PortletItem[] array = new PortletItemImpl[3];
933
934 array[0] = (PortletItem)objArray[0];
935 array[1] = (PortletItem)objArray[1];
936 array[2] = (PortletItem)objArray[2];
937
938 return array;
939 }
940 catch (Exception e) {
941 throw processException(e);
942 }
943 finally {
944 closeSession(session);
945 }
946 }
947
948 public PortletItem findByG_N_P_C(long groupId, String name,
949 String portletId, long classNameId)
950 throws NoSuchPortletItemException, SystemException {
951 PortletItem portletItem = fetchByG_N_P_C(groupId, name, portletId,
952 classNameId);
953
954 if (portletItem == null) {
955 StringBuilder msg = new StringBuilder();
956
957 msg.append("No PortletItem exists with the key {");
958
959 msg.append("groupId=" + groupId);
960
961 msg.append(", ");
962 msg.append("name=" + name);
963
964 msg.append(", ");
965 msg.append("portletId=" + portletId);
966
967 msg.append(", ");
968 msg.append("classNameId=" + classNameId);
969
970 msg.append(StringPool.CLOSE_CURLY_BRACE);
971
972 if (_log.isWarnEnabled()) {
973 _log.warn(msg.toString());
974 }
975
976 throw new NoSuchPortletItemException(msg.toString());
977 }
978
979 return portletItem;
980 }
981
982 public PortletItem fetchByG_N_P_C(long groupId, String name,
983 String portletId, long classNameId) throws SystemException {
984 return fetchByG_N_P_C(groupId, name, portletId, classNameId, true);
985 }
986
987 public PortletItem fetchByG_N_P_C(long groupId, String name,
988 String portletId, long classNameId, boolean retrieveFromCache)
989 throws SystemException {
990 Object[] finderArgs = new Object[] {
991 new Long(groupId),
992
993 name,
994
995 portletId, new Long(classNameId)
996 };
997
998 Object result = null;
999
1000 if (retrieveFromCache) {
1001 result = FinderCacheUtil.getResult(FINDER_PATH_FETCH_BY_G_N_P_C,
1002 finderArgs, this);
1003 }
1004
1005 if (result == null) {
1006 Session session = null;
1007
1008 try {
1009 session = openSession();
1010
1011 StringBuilder query = new StringBuilder();
1012
1013 query.append("FROM com.liferay.portal.model.PortletItem WHERE ");
1014
1015 query.append("groupId = ?");
1016
1017 query.append(" AND ");
1018
1019 if (name == null) {
1020 query.append("name IS NULL");
1021 }
1022 else {
1023 query.append("lower(name) = ?");
1024 }
1025
1026 query.append(" AND ");
1027
1028 if (portletId == null) {
1029 query.append("portletId IS NULL");
1030 }
1031 else {
1032 query.append("portletId = ?");
1033 }
1034
1035 query.append(" AND ");
1036
1037 query.append("classNameId = ?");
1038
1039 query.append(" ");
1040
1041 Query q = session.createQuery(query.toString());
1042
1043 QueryPos qPos = QueryPos.getInstance(q);
1044
1045 qPos.add(groupId);
1046
1047 if (name != null) {
1048 qPos.add(name);
1049 }
1050
1051 if (portletId != null) {
1052 qPos.add(portletId);
1053 }
1054
1055 qPos.add(classNameId);
1056
1057 List<PortletItem> list = q.list();
1058
1059 result = list;
1060
1061 PortletItem portletItem = null;
1062
1063 if (list.isEmpty()) {
1064 FinderCacheUtil.putResult(FINDER_PATH_FETCH_BY_G_N_P_C,
1065 finderArgs, list);
1066 }
1067 else {
1068 portletItem = list.get(0);
1069
1070 cacheResult(portletItem);
1071
1072 if ((portletItem.getGroupId() != groupId) ||
1073 (portletItem.getName() == null) ||
1074 !portletItem.getName().equals(name) ||
1075 (portletItem.getPortletId() == null) ||
1076 !portletItem.getPortletId().equals(portletId) ||
1077 (portletItem.getClassNameId() != classNameId)) {
1078 FinderCacheUtil.putResult(FINDER_PATH_FETCH_BY_G_N_P_C,
1079 finderArgs, portletItem);
1080 }
1081 }
1082
1083 return portletItem;
1084 }
1085 catch (Exception e) {
1086 throw processException(e);
1087 }
1088 finally {
1089 if (result == null) {
1090 FinderCacheUtil.putResult(FINDER_PATH_FETCH_BY_G_N_P_C,
1091 finderArgs, new ArrayList<PortletItem>());
1092 }
1093
1094 closeSession(session);
1095 }
1096 }
1097 else {
1098 if (result instanceof List) {
1099 return null;
1100 }
1101 else {
1102 return (PortletItem)result;
1103 }
1104 }
1105 }
1106
1107 public List<Object> findWithDynamicQuery(DynamicQuery dynamicQuery)
1108 throws SystemException {
1109 Session session = null;
1110
1111 try {
1112 session = openSession();
1113
1114 dynamicQuery.compile(session);
1115
1116 return dynamicQuery.list();
1117 }
1118 catch (Exception e) {
1119 throw processException(e);
1120 }
1121 finally {
1122 closeSession(session);
1123 }
1124 }
1125
1126 public List<Object> findWithDynamicQuery(DynamicQuery dynamicQuery,
1127 int start, int end) throws SystemException {
1128 Session session = null;
1129
1130 try {
1131 session = openSession();
1132
1133 dynamicQuery.setLimit(start, end);
1134
1135 dynamicQuery.compile(session);
1136
1137 return dynamicQuery.list();
1138 }
1139 catch (Exception e) {
1140 throw processException(e);
1141 }
1142 finally {
1143 closeSession(session);
1144 }
1145 }
1146
1147 public List<PortletItem> findAll() throws SystemException {
1148 return findAll(QueryUtil.ALL_POS, QueryUtil.ALL_POS, null);
1149 }
1150
1151 public List<PortletItem> findAll(int start, int end)
1152 throws SystemException {
1153 return findAll(start, end, null);
1154 }
1155
1156 public List<PortletItem> findAll(int start, int end, OrderByComparator obc)
1157 throws SystemException {
1158 Object[] finderArgs = new Object[] {
1159 String.valueOf(start), String.valueOf(end), String.valueOf(obc)
1160 };
1161
1162 List<PortletItem> list = (List<PortletItem>)FinderCacheUtil.getResult(FINDER_PATH_FIND_ALL,
1163 finderArgs, this);
1164
1165 if (list == null) {
1166 Session session = null;
1167
1168 try {
1169 session = openSession();
1170
1171 StringBuilder query = new StringBuilder();
1172
1173 query.append("FROM com.liferay.portal.model.PortletItem ");
1174
1175 if (obc != null) {
1176 query.append("ORDER BY ");
1177 query.append(obc.getOrderBy());
1178 }
1179
1180 Query q = session.createQuery(query.toString());
1181
1182 if (obc == null) {
1183 list = (List<PortletItem>)QueryUtil.list(q, getDialect(),
1184 start, end, false);
1185
1186 Collections.sort(list);
1187 }
1188 else {
1189 list = (List<PortletItem>)QueryUtil.list(q, getDialect(),
1190 start, end);
1191 }
1192 }
1193 catch (Exception e) {
1194 throw processException(e);
1195 }
1196 finally {
1197 if (list == null) {
1198 list = new ArrayList<PortletItem>();
1199 }
1200
1201 cacheResult(list);
1202
1203 FinderCacheUtil.putResult(FINDER_PATH_FIND_ALL, finderArgs, list);
1204
1205 closeSession(session);
1206 }
1207 }
1208
1209 return list;
1210 }
1211
1212 public void removeByG_C(long groupId, long classNameId)
1213 throws SystemException {
1214 for (PortletItem portletItem : findByG_C(groupId, classNameId)) {
1215 remove(portletItem);
1216 }
1217 }
1218
1219 public void removeByG_P_C(long groupId, String portletId, long classNameId)
1220 throws SystemException {
1221 for (PortletItem portletItem : findByG_P_C(groupId, portletId,
1222 classNameId)) {
1223 remove(portletItem);
1224 }
1225 }
1226
1227 public void removeByG_N_P_C(long groupId, String name, String portletId,
1228 long classNameId) throws NoSuchPortletItemException, SystemException {
1229 PortletItem portletItem = findByG_N_P_C(groupId, name, portletId,
1230 classNameId);
1231
1232 remove(portletItem);
1233 }
1234
1235 public void removeAll() throws SystemException {
1236 for (PortletItem portletItem : findAll()) {
1237 remove(portletItem);
1238 }
1239 }
1240
1241 public int countByG_C(long groupId, long classNameId)
1242 throws SystemException {
1243 Object[] finderArgs = new Object[] {
1244 new Long(groupId), new Long(classNameId)
1245 };
1246
1247 Long count = (Long)FinderCacheUtil.getResult(FINDER_PATH_COUNT_BY_G_C,
1248 finderArgs, this);
1249
1250 if (count == null) {
1251 Session session = null;
1252
1253 try {
1254 session = openSession();
1255
1256 StringBuilder query = new StringBuilder();
1257
1258 query.append("SELECT COUNT(*) ");
1259 query.append("FROM com.liferay.portal.model.PortletItem WHERE ");
1260
1261 query.append("groupId = ?");
1262
1263 query.append(" AND ");
1264
1265 query.append("classNameId = ?");
1266
1267 query.append(" ");
1268
1269 Query q = session.createQuery(query.toString());
1270
1271 QueryPos qPos = QueryPos.getInstance(q);
1272
1273 qPos.add(groupId);
1274
1275 qPos.add(classNameId);
1276
1277 count = (Long)q.uniqueResult();
1278 }
1279 catch (Exception e) {
1280 throw processException(e);
1281 }
1282 finally {
1283 if (count == null) {
1284 count = Long.valueOf(0);
1285 }
1286
1287 FinderCacheUtil.putResult(FINDER_PATH_COUNT_BY_G_C, finderArgs,
1288 count);
1289
1290 closeSession(session);
1291 }
1292 }
1293
1294 return count.intValue();
1295 }
1296
1297 public int countByG_P_C(long groupId, String portletId, long classNameId)
1298 throws SystemException {
1299 Object[] finderArgs = new Object[] {
1300 new Long(groupId),
1301
1302 portletId, new Long(classNameId)
1303 };
1304
1305 Long count = (Long)FinderCacheUtil.getResult(FINDER_PATH_COUNT_BY_G_P_C,
1306 finderArgs, this);
1307
1308 if (count == null) {
1309 Session session = null;
1310
1311 try {
1312 session = openSession();
1313
1314 StringBuilder query = new StringBuilder();
1315
1316 query.append("SELECT COUNT(*) ");
1317 query.append("FROM com.liferay.portal.model.PortletItem WHERE ");
1318
1319 query.append("groupId = ?");
1320
1321 query.append(" AND ");
1322
1323 if (portletId == null) {
1324 query.append("portletId IS NULL");
1325 }
1326 else {
1327 query.append("portletId = ?");
1328 }
1329
1330 query.append(" AND ");
1331
1332 query.append("classNameId = ?");
1333
1334 query.append(" ");
1335
1336 Query q = session.createQuery(query.toString());
1337
1338 QueryPos qPos = QueryPos.getInstance(q);
1339
1340 qPos.add(groupId);
1341
1342 if (portletId != null) {
1343 qPos.add(portletId);
1344 }
1345
1346 qPos.add(classNameId);
1347
1348 count = (Long)q.uniqueResult();
1349 }
1350 catch (Exception e) {
1351 throw processException(e);
1352 }
1353 finally {
1354 if (count == null) {
1355 count = Long.valueOf(0);
1356 }
1357
1358 FinderCacheUtil.putResult(FINDER_PATH_COUNT_BY_G_P_C,
1359 finderArgs, count);
1360
1361 closeSession(session);
1362 }
1363 }
1364
1365 return count.intValue();
1366 }
1367
1368 public int countByG_N_P_C(long groupId, String name, String portletId,
1369 long classNameId) throws SystemException {
1370 Object[] finderArgs = new Object[] {
1371 new Long(groupId),
1372
1373 name,
1374
1375 portletId, new Long(classNameId)
1376 };
1377
1378 Long count = (Long)FinderCacheUtil.getResult(FINDER_PATH_COUNT_BY_G_N_P_C,
1379 finderArgs, this);
1380
1381 if (count == null) {
1382 Session session = null;
1383
1384 try {
1385 session = openSession();
1386
1387 StringBuilder query = new StringBuilder();
1388
1389 query.append("SELECT COUNT(*) ");
1390 query.append("FROM com.liferay.portal.model.PortletItem WHERE ");
1391
1392 query.append("groupId = ?");
1393
1394 query.append(" AND ");
1395
1396 if (name == null) {
1397 query.append("name IS NULL");
1398 }
1399 else {
1400 query.append("lower(name) = ?");
1401 }
1402
1403 query.append(" AND ");
1404
1405 if (portletId == null) {
1406 query.append("portletId IS NULL");
1407 }
1408 else {
1409 query.append("portletId = ?");
1410 }
1411
1412 query.append(" AND ");
1413
1414 query.append("classNameId = ?");
1415
1416 query.append(" ");
1417
1418 Query q = session.createQuery(query.toString());
1419
1420 QueryPos qPos = QueryPos.getInstance(q);
1421
1422 qPos.add(groupId);
1423
1424 if (name != null) {
1425 qPos.add(name);
1426 }
1427
1428 if (portletId != null) {
1429 qPos.add(portletId);
1430 }
1431
1432 qPos.add(classNameId);
1433
1434 count = (Long)q.uniqueResult();
1435 }
1436 catch (Exception e) {
1437 throw processException(e);
1438 }
1439 finally {
1440 if (count == null) {
1441 count = Long.valueOf(0);
1442 }
1443
1444 FinderCacheUtil.putResult(FINDER_PATH_COUNT_BY_G_N_P_C,
1445 finderArgs, count);
1446
1447 closeSession(session);
1448 }
1449 }
1450
1451 return count.intValue();
1452 }
1453
1454 public int countAll() throws SystemException {
1455 Object[] finderArgs = new Object[0];
1456
1457 Long count = (Long)FinderCacheUtil.getResult(FINDER_PATH_COUNT_ALL,
1458 finderArgs, this);
1459
1460 if (count == null) {
1461 Session session = null;
1462
1463 try {
1464 session = openSession();
1465
1466 Query q = session.createQuery(
1467 "SELECT COUNT(*) FROM com.liferay.portal.model.PortletItem");
1468
1469 count = (Long)q.uniqueResult();
1470 }
1471 catch (Exception e) {
1472 throw processException(e);
1473 }
1474 finally {
1475 if (count == null) {
1476 count = Long.valueOf(0);
1477 }
1478
1479 FinderCacheUtil.putResult(FINDER_PATH_COUNT_ALL, finderArgs,
1480 count);
1481
1482 closeSession(session);
1483 }
1484 }
1485
1486 return count.intValue();
1487 }
1488
1489 public void afterPropertiesSet() {
1490 String[] listenerClassNames = StringUtil.split(GetterUtil.getString(
1491 com.liferay.portal.util.PropsUtil.get(
1492 "value.object.listener.com.liferay.portal.model.PortletItem")));
1493
1494 if (listenerClassNames.length > 0) {
1495 try {
1496 List<ModelListener<PortletItem>> listenersList = new ArrayList<ModelListener<PortletItem>>();
1497
1498 for (String listenerClassName : listenerClassNames) {
1499 listenersList.add((ModelListener<PortletItem>)Class.forName(
1500 listenerClassName).newInstance());
1501 }
1502
1503 listeners = listenersList.toArray(new ModelListener[listenersList.size()]);
1504 }
1505 catch (Exception e) {
1506 _log.error(e);
1507 }
1508 }
1509 }
1510
1511 @BeanReference(name = "com.liferay.portal.service.persistence.AccountPersistence.impl")
1512 protected com.liferay.portal.service.persistence.AccountPersistence accountPersistence;
1513 @BeanReference(name = "com.liferay.portal.service.persistence.AddressPersistence.impl")
1514 protected com.liferay.portal.service.persistence.AddressPersistence addressPersistence;
1515 @BeanReference(name = "com.liferay.portal.service.persistence.BrowserTrackerPersistence.impl")
1516 protected com.liferay.portal.service.persistence.BrowserTrackerPersistence browserTrackerPersistence;
1517 @BeanReference(name = "com.liferay.portal.service.persistence.ClassNamePersistence.impl")
1518 protected com.liferay.portal.service.persistence.ClassNamePersistence classNamePersistence;
1519 @BeanReference(name = "com.liferay.portal.service.persistence.CompanyPersistence.impl")
1520 protected com.liferay.portal.service.persistence.CompanyPersistence companyPersistence;
1521 @BeanReference(name = "com.liferay.portal.service.persistence.ContactPersistence.impl")
1522 protected com.liferay.portal.service.persistence.ContactPersistence contactPersistence;
1523 @BeanReference(name = "com.liferay.portal.service.persistence.CountryPersistence.impl")
1524 protected com.liferay.portal.service.persistence.CountryPersistence countryPersistence;
1525 @BeanReference(name = "com.liferay.portal.service.persistence.EmailAddressPersistence.impl")
1526 protected com.liferay.portal.service.persistence.EmailAddressPersistence emailAddressPersistence;
1527 @BeanReference(name = "com.liferay.portal.service.persistence.GroupPersistence.impl")
1528 protected com.liferay.portal.service.persistence.GroupPersistence groupPersistence;
1529 @BeanReference(name = "com.liferay.portal.service.persistence.ImagePersistence.impl")
1530 protected com.liferay.portal.service.persistence.ImagePersistence imagePersistence;
1531 @BeanReference(name = "com.liferay.portal.service.persistence.LayoutPersistence.impl")
1532 protected com.liferay.portal.service.persistence.LayoutPersistence layoutPersistence;
1533 @BeanReference(name = "com.liferay.portal.service.persistence.LayoutSetPersistence.impl")
1534 protected com.liferay.portal.service.persistence.LayoutSetPersistence layoutSetPersistence;
1535 @BeanReference(name = "com.liferay.portal.service.persistence.ListTypePersistence.impl")
1536 protected com.liferay.portal.service.persistence.ListTypePersistence listTypePersistence;
1537 @BeanReference(name = "com.liferay.portal.service.persistence.MembershipRequestPersistence.impl")
1538 protected com.liferay.portal.service.persistence.MembershipRequestPersistence membershipRequestPersistence;
1539 @BeanReference(name = "com.liferay.portal.service.persistence.OrganizationPersistence.impl")
1540 protected com.liferay.portal.service.persistence.OrganizationPersistence organizationPersistence;
1541 @BeanReference(name = "com.liferay.portal.service.persistence.OrgGroupPermissionPersistence.impl")
1542 protected com.liferay.portal.service.persistence.OrgGroupPermissionPersistence orgGroupPermissionPersistence;
1543 @BeanReference(name = "com.liferay.portal.service.persistence.OrgGroupRolePersistence.impl")
1544 protected com.liferay.portal.service.persistence.OrgGroupRolePersistence orgGroupRolePersistence;
1545 @BeanReference(name = "com.liferay.portal.service.persistence.OrgLaborPersistence.impl")
1546 protected com.liferay.portal.service.persistence.OrgLaborPersistence orgLaborPersistence;
1547 @BeanReference(name = "com.liferay.portal.service.persistence.PasswordPolicyPersistence.impl")
1548 protected com.liferay.portal.service.persistence.PasswordPolicyPersistence passwordPolicyPersistence;
1549 @BeanReference(name = "com.liferay.portal.service.persistence.PasswordPolicyRelPersistence.impl")
1550 protected com.liferay.portal.service.persistence.PasswordPolicyRelPersistence passwordPolicyRelPersistence;
1551 @BeanReference(name = "com.liferay.portal.service.persistence.PasswordTrackerPersistence.impl")
1552 protected com.liferay.portal.service.persistence.PasswordTrackerPersistence passwordTrackerPersistence;
1553 @BeanReference(name = "com.liferay.portal.service.persistence.PermissionPersistence.impl")
1554 protected com.liferay.portal.service.persistence.PermissionPersistence permissionPersistence;
1555 @BeanReference(name = "com.liferay.portal.service.persistence.PhonePersistence.impl")
1556 protected com.liferay.portal.service.persistence.PhonePersistence phonePersistence;
1557 @BeanReference(name = "com.liferay.portal.service.persistence.PluginSettingPersistence.impl")
1558 protected com.liferay.portal.service.persistence.PluginSettingPersistence pluginSettingPersistence;
1559 @BeanReference(name = "com.liferay.portal.service.persistence.PortletPersistence.impl")
1560 protected com.liferay.portal.service.persistence.PortletPersistence portletPersistence;
1561 @BeanReference(name = "com.liferay.portal.service.persistence.PortletItemPersistence.impl")
1562 protected com.liferay.portal.service.persistence.PortletItemPersistence portletItemPersistence;
1563 @BeanReference(name = "com.liferay.portal.service.persistence.PortletPreferencesPersistence.impl")
1564 protected com.liferay.portal.service.persistence.PortletPreferencesPersistence portletPreferencesPersistence;
1565 @BeanReference(name = "com.liferay.portal.service.persistence.RegionPersistence.impl")
1566 protected com.liferay.portal.service.persistence.RegionPersistence regionPersistence;
1567 @BeanReference(name = "com.liferay.portal.service.persistence.ReleasePersistence.impl")
1568 protected com.liferay.portal.service.persistence.ReleasePersistence releasePersistence;
1569 @BeanReference(name = "com.liferay.portal.service.persistence.ResourcePersistence.impl")
1570 protected com.liferay.portal.service.persistence.ResourcePersistence resourcePersistence;
1571 @BeanReference(name = "com.liferay.portal.service.persistence.ResourceActionPersistence.impl")
1572 protected com.liferay.portal.service.persistence.ResourceActionPersistence resourceActionPersistence;
1573 @BeanReference(name = "com.liferay.portal.service.persistence.ResourceCodePersistence.impl")
1574 protected com.liferay.portal.service.persistence.ResourceCodePersistence resourceCodePersistence;
1575 @BeanReference(name = "com.liferay.portal.service.persistence.ResourcePermissionPersistence.impl")
1576 protected com.liferay.portal.service.persistence.ResourcePermissionPersistence resourcePermissionPersistence;
1577 @BeanReference(name = "com.liferay.portal.service.persistence.RolePersistence.impl")
1578 protected com.liferay.portal.service.persistence.RolePersistence rolePersistence;
1579 @BeanReference(name = "com.liferay.portal.service.persistence.ServiceComponentPersistence.impl")
1580 protected com.liferay.portal.service.persistence.ServiceComponentPersistence serviceComponentPersistence;
1581 @BeanReference(name = "com.liferay.portal.service.persistence.ShardPersistence.impl")
1582 protected com.liferay.portal.service.persistence.ShardPersistence shardPersistence;
1583 @BeanReference(name = "com.liferay.portal.service.persistence.SubscriptionPersistence.impl")
1584 protected com.liferay.portal.service.persistence.SubscriptionPersistence subscriptionPersistence;
1585 @BeanReference(name = "com.liferay.portal.service.persistence.UserPersistence.impl")
1586 protected com.liferay.portal.service.persistence.UserPersistence userPersistence;
1587 @BeanReference(name = "com.liferay.portal.service.persistence.UserGroupPersistence.impl")
1588 protected com.liferay.portal.service.persistence.UserGroupPersistence userGroupPersistence;
1589 @BeanReference(name = "com.liferay.portal.service.persistence.UserGroupRolePersistence.impl")
1590 protected com.liferay.portal.service.persistence.UserGroupRolePersistence userGroupRolePersistence;
1591 @BeanReference(name = "com.liferay.portal.service.persistence.UserIdMapperPersistence.impl")
1592 protected com.liferay.portal.service.persistence.UserIdMapperPersistence userIdMapperPersistence;
1593 @BeanReference(name = "com.liferay.portal.service.persistence.UserTrackerPersistence.impl")
1594 protected com.liferay.portal.service.persistence.UserTrackerPersistence userTrackerPersistence;
1595 @BeanReference(name = "com.liferay.portal.service.persistence.UserTrackerPathPersistence.impl")
1596 protected com.liferay.portal.service.persistence.UserTrackerPathPersistence userTrackerPathPersistence;
1597 @BeanReference(name = "com.liferay.portal.service.persistence.WebDAVPropsPersistence.impl")
1598 protected com.liferay.portal.service.persistence.WebDAVPropsPersistence webDAVPropsPersistence;
1599 @BeanReference(name = "com.liferay.portal.service.persistence.WebsitePersistence.impl")
1600 protected com.liferay.portal.service.persistence.WebsitePersistence websitePersistence;
1601 private static Log _log = LogFactoryUtil.getLog(PortletItemPersistenceImpl.class);
1602}