1   /**
2    * Copyright (c) 2000-2009 Liferay, Inc. All rights reserved.
3    *
4    * Permission is hereby granted, free of charge, to any person obtaining a copy
5    * of this software and associated documentation files (the "Software"), to deal
6    * in the Software without restriction, including without limitation the rights
7    * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
8    * copies of the Software, and to permit persons to whom the Software is
9    * furnished to do so, subject to the following conditions:
10   *
11   * The above copyright notice and this permission notice shall be included in
12   * all copies or substantial portions of the Software.
13   *
14   * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
15   * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
16   * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
17   * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
18   * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
19   * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
20   * SOFTWARE.
21   */
22  
23  package com.liferay.portal.service.persistence;
24  
25  import com.liferay.portal.NoSuchImageException;
26  import com.liferay.portal.SystemException;
27  import com.liferay.portal.kernel.annotation.BeanReference;
28  import com.liferay.portal.kernel.dao.orm.DynamicQuery;
29  import com.liferay.portal.kernel.dao.orm.FinderCacheUtil;
30  import com.liferay.portal.kernel.dao.orm.Query;
31  import com.liferay.portal.kernel.dao.orm.QueryPos;
32  import com.liferay.portal.kernel.dao.orm.QueryUtil;
33  import com.liferay.portal.kernel.dao.orm.Session;
34  import com.liferay.portal.kernel.log.Log;
35  import com.liferay.portal.kernel.log.LogFactoryUtil;
36  import com.liferay.portal.kernel.util.GetterUtil;
37  import com.liferay.portal.kernel.util.OrderByComparator;
38  import com.liferay.portal.kernel.util.StringPool;
39  import com.liferay.portal.kernel.util.StringUtil;
40  import com.liferay.portal.model.Image;
41  import com.liferay.portal.model.ModelListener;
42  import com.liferay.portal.model.impl.ImageImpl;
43  import com.liferay.portal.model.impl.ImageModelImpl;
44  import com.liferay.portal.service.persistence.impl.BasePersistenceImpl;
45  
46  import java.util.ArrayList;
47  import java.util.Collections;
48  import java.util.Iterator;
49  import java.util.List;
50  
51  /**
52   * <a href="ImagePersistenceImpl.java.html"><b><i>View Source</i></b></a>
53   *
54   * @author Brian Wing Shun Chan
55   *
56   */
57  public class ImagePersistenceImpl extends BasePersistenceImpl
58      implements ImagePersistence {
59      public Image create(long imageId) {
60          Image image = new ImageImpl();
61  
62          image.setNew(true);
63          image.setPrimaryKey(imageId);
64  
65          return image;
66      }
67  
68      public Image remove(long imageId)
69          throws NoSuchImageException, SystemException {
70          Session session = null;
71  
72          try {
73              session = openSession();
74  
75              Image image = (Image)session.get(ImageImpl.class, new Long(imageId));
76  
77              if (image == null) {
78                  if (_log.isWarnEnabled()) {
79                      _log.warn("No Image exists with the primary key " +
80                          imageId);
81                  }
82  
83                  throw new NoSuchImageException(
84                      "No Image exists with the primary key " + imageId);
85              }
86  
87              return remove(image);
88          }
89          catch (NoSuchImageException nsee) {
90              throw nsee;
91          }
92          catch (Exception e) {
93              throw processException(e);
94          }
95          finally {
96              closeSession(session);
97          }
98      }
99  
100     public Image remove(Image image) throws SystemException {
101         for (ModelListener listener : listeners) {
102             listener.onBeforeRemove(image);
103         }
104 
105         image = removeImpl(image);
106 
107         for (ModelListener listener : listeners) {
108             listener.onAfterRemove(image);
109         }
110 
111         return image;
112     }
113 
114     protected Image removeImpl(Image image) throws SystemException {
115         Session session = null;
116 
117         try {
118             session = openSession();
119 
120             if (BatchSessionUtil.isEnabled()) {
121                 Object staleObject = session.get(ImageImpl.class,
122                         image.getPrimaryKeyObj());
123 
124                 if (staleObject != null) {
125                     session.evict(staleObject);
126                 }
127             }
128 
129             session.delete(image);
130 
131             session.flush();
132 
133             return image;
134         }
135         catch (Exception e) {
136             throw processException(e);
137         }
138         finally {
139             closeSession(session);
140 
141             FinderCacheUtil.clearCache(Image.class.getName());
142         }
143     }
144 
145     /**
146      * @deprecated Use <code>update(Image image, boolean merge)</code>.
147      */
148     public Image update(Image image) throws SystemException {
149         if (_log.isWarnEnabled()) {
150             _log.warn(
151                 "Using the deprecated update(Image image) method. Use update(Image image, boolean merge) instead.");
152         }
153 
154         return update(image, false);
155     }
156 
157     /**
158      * Add, update, or merge, the entity. This method also calls the model
159      * listeners to trigger the proper events associated with adding, deleting,
160      * or updating an entity.
161      *
162      * @param        image the entity to add, update, or merge
163      * @param        merge boolean value for whether to merge the entity. The
164      *                default value is false. Setting merge to true is more
165      *                expensive and should only be true when image is
166      *                transient. See LEP-5473 for a detailed discussion of this
167      *                method.
168      * @return        true if the portlet can be displayed via Ajax
169      */
170     public Image update(Image image, boolean merge) throws SystemException {
171         boolean isNew = image.isNew();
172 
173         for (ModelListener listener : listeners) {
174             if (isNew) {
175                 listener.onBeforeCreate(image);
176             }
177             else {
178                 listener.onBeforeUpdate(image);
179             }
180         }
181 
182         image = updateImpl(image, merge);
183 
184         for (ModelListener listener : listeners) {
185             if (isNew) {
186                 listener.onAfterCreate(image);
187             }
188             else {
189                 listener.onAfterUpdate(image);
190             }
191         }
192 
193         return image;
194     }
195 
196     public Image updateImpl(com.liferay.portal.model.Image image, boolean merge)
197         throws SystemException {
198         Session session = null;
199 
200         try {
201             session = openSession();
202 
203             BatchSessionUtil.update(session, image, merge);
204 
205             image.setNew(false);
206 
207             return image;
208         }
209         catch (Exception e) {
210             throw processException(e);
211         }
212         finally {
213             closeSession(session);
214 
215             FinderCacheUtil.clearCache(Image.class.getName());
216         }
217     }
218 
219     public Image findByPrimaryKey(long imageId)
220         throws NoSuchImageException, SystemException {
221         Image image = fetchByPrimaryKey(imageId);
222 
223         if (image == null) {
224             if (_log.isWarnEnabled()) {
225                 _log.warn("No Image exists with the primary key " + imageId);
226             }
227 
228             throw new NoSuchImageException(
229                 "No Image exists with the primary key " + imageId);
230         }
231 
232         return image;
233     }
234 
235     public Image fetchByPrimaryKey(long imageId) throws SystemException {
236         Session session = null;
237 
238         try {
239             session = openSession();
240 
241             return (Image)session.get(ImageImpl.class, new Long(imageId));
242         }
243         catch (Exception e) {
244             throw processException(e);
245         }
246         finally {
247             closeSession(session);
248         }
249     }
250 
251     public List<Image> findBySize(int size) throws SystemException {
252         boolean finderClassNameCacheEnabled = ImageModelImpl.CACHE_ENABLED;
253         String finderClassName = Image.class.getName();
254         String finderMethodName = "findBySize";
255         String[] finderParams = new String[] { Integer.class.getName() };
256         Object[] finderArgs = new Object[] { new Integer(size) };
257 
258         Object result = null;
259 
260         if (finderClassNameCacheEnabled) {
261             result = FinderCacheUtil.getResult(finderClassName,
262                     finderMethodName, finderParams, finderArgs, this);
263         }
264 
265         if (result == null) {
266             Session session = null;
267 
268             try {
269                 session = openSession();
270 
271                 StringBuilder query = new StringBuilder();
272 
273                 query.append("FROM com.liferay.portal.model.Image WHERE ");
274 
275                 query.append("size_ < ?");
276 
277                 query.append(" ");
278 
279                 query.append("ORDER BY ");
280 
281                 query.append("imageId ASC");
282 
283                 Query q = session.createQuery(query.toString());
284 
285                 QueryPos qPos = QueryPos.getInstance(q);
286 
287                 qPos.add(size);
288 
289                 List<Image> list = q.list();
290 
291                 FinderCacheUtil.putResult(finderClassNameCacheEnabled,
292                     finderClassName, finderMethodName, finderParams,
293                     finderArgs, list);
294 
295                 return list;
296             }
297             catch (Exception e) {
298                 throw processException(e);
299             }
300             finally {
301                 closeSession(session);
302             }
303         }
304         else {
305             return (List<Image>)result;
306         }
307     }
308 
309     public List<Image> findBySize(int size, int start, int end)
310         throws SystemException {
311         return findBySize(size, start, end, null);
312     }
313 
314     public List<Image> findBySize(int size, int start, int end,
315         OrderByComparator obc) throws SystemException {
316         boolean finderClassNameCacheEnabled = ImageModelImpl.CACHE_ENABLED;
317         String finderClassName = Image.class.getName();
318         String finderMethodName = "findBySize";
319         String[] finderParams = new String[] {
320                 Integer.class.getName(),
321                 
322                 "java.lang.Integer", "java.lang.Integer",
323                 "com.liferay.portal.kernel.util.OrderByComparator"
324             };
325         Object[] finderArgs = new Object[] {
326                 new Integer(size),
327                 
328                 String.valueOf(start), String.valueOf(end), String.valueOf(obc)
329             };
330 
331         Object result = null;
332 
333         if (finderClassNameCacheEnabled) {
334             result = FinderCacheUtil.getResult(finderClassName,
335                     finderMethodName, finderParams, finderArgs, this);
336         }
337 
338         if (result == null) {
339             Session session = null;
340 
341             try {
342                 session = openSession();
343 
344                 StringBuilder query = new StringBuilder();
345 
346                 query.append("FROM com.liferay.portal.model.Image WHERE ");
347 
348                 query.append("size_ < ?");
349 
350                 query.append(" ");
351 
352                 if (obc != null) {
353                     query.append("ORDER BY ");
354                     query.append(obc.getOrderBy());
355                 }
356 
357                 else {
358                     query.append("ORDER BY ");
359 
360                     query.append("imageId ASC");
361                 }
362 
363                 Query q = session.createQuery(query.toString());
364 
365                 QueryPos qPos = QueryPos.getInstance(q);
366 
367                 qPos.add(size);
368 
369                 List<Image> list = (List<Image>)QueryUtil.list(q, getDialect(),
370                         start, end);
371 
372                 FinderCacheUtil.putResult(finderClassNameCacheEnabled,
373                     finderClassName, finderMethodName, finderParams,
374                     finderArgs, list);
375 
376                 return list;
377             }
378             catch (Exception e) {
379                 throw processException(e);
380             }
381             finally {
382                 closeSession(session);
383             }
384         }
385         else {
386             return (List<Image>)result;
387         }
388     }
389 
390     public Image findBySize_First(int size, OrderByComparator obc)
391         throws NoSuchImageException, SystemException {
392         List<Image> list = findBySize(size, 0, 1, obc);
393 
394         if (list.size() == 0) {
395             StringBuilder msg = new StringBuilder();
396 
397             msg.append("No Image exists with the key {");
398 
399             msg.append("size=" + size);
400 
401             msg.append(StringPool.CLOSE_CURLY_BRACE);
402 
403             throw new NoSuchImageException(msg.toString());
404         }
405         else {
406             return list.get(0);
407         }
408     }
409 
410     public Image findBySize_Last(int size, OrderByComparator obc)
411         throws NoSuchImageException, SystemException {
412         int count = countBySize(size);
413 
414         List<Image> list = findBySize(size, count - 1, count, obc);
415 
416         if (list.size() == 0) {
417             StringBuilder msg = new StringBuilder();
418 
419             msg.append("No Image exists with the key {");
420 
421             msg.append("size=" + size);
422 
423             msg.append(StringPool.CLOSE_CURLY_BRACE);
424 
425             throw new NoSuchImageException(msg.toString());
426         }
427         else {
428             return list.get(0);
429         }
430     }
431 
432     public Image[] findBySize_PrevAndNext(long imageId, int size,
433         OrderByComparator obc) throws NoSuchImageException, SystemException {
434         Image image = findByPrimaryKey(imageId);
435 
436         int count = countBySize(size);
437 
438         Session session = null;
439 
440         try {
441             session = openSession();
442 
443             StringBuilder query = new StringBuilder();
444 
445             query.append("FROM com.liferay.portal.model.Image WHERE ");
446 
447             query.append("size_ < ?");
448 
449             query.append(" ");
450 
451             if (obc != null) {
452                 query.append("ORDER BY ");
453                 query.append(obc.getOrderBy());
454             }
455 
456             else {
457                 query.append("ORDER BY ");
458 
459                 query.append("imageId ASC");
460             }
461 
462             Query q = session.createQuery(query.toString());
463 
464             QueryPos qPos = QueryPos.getInstance(q);
465 
466             qPos.add(size);
467 
468             Object[] objArray = QueryUtil.getPrevAndNext(q, count, obc, image);
469 
470             Image[] array = new ImageImpl[3];
471 
472             array[0] = (Image)objArray[0];
473             array[1] = (Image)objArray[1];
474             array[2] = (Image)objArray[2];
475 
476             return array;
477         }
478         catch (Exception e) {
479             throw processException(e);
480         }
481         finally {
482             closeSession(session);
483         }
484     }
485 
486     public List<Object> findWithDynamicQuery(DynamicQuery dynamicQuery)
487         throws SystemException {
488         Session session = null;
489 
490         try {
491             session = openSession();
492 
493             dynamicQuery.compile(session);
494 
495             return dynamicQuery.list();
496         }
497         catch (Exception e) {
498             throw processException(e);
499         }
500         finally {
501             closeSession(session);
502         }
503     }
504 
505     public List<Object> findWithDynamicQuery(DynamicQuery dynamicQuery,
506         int start, int end) throws SystemException {
507         Session session = null;
508 
509         try {
510             session = openSession();
511 
512             dynamicQuery.setLimit(start, end);
513 
514             dynamicQuery.compile(session);
515 
516             return dynamicQuery.list();
517         }
518         catch (Exception e) {
519             throw processException(e);
520         }
521         finally {
522             closeSession(session);
523         }
524     }
525 
526     public List<Image> findAll() throws SystemException {
527         return findAll(QueryUtil.ALL_POS, QueryUtil.ALL_POS, null);
528     }
529 
530     public List<Image> findAll(int start, int end) throws SystemException {
531         return findAll(start, end, null);
532     }
533 
534     public List<Image> findAll(int start, int end, OrderByComparator obc)
535         throws SystemException {
536         boolean finderClassNameCacheEnabled = ImageModelImpl.CACHE_ENABLED;
537         String finderClassName = Image.class.getName();
538         String finderMethodName = "findAll";
539         String[] finderParams = new String[] {
540                 "java.lang.Integer", "java.lang.Integer",
541                 "com.liferay.portal.kernel.util.OrderByComparator"
542             };
543         Object[] finderArgs = new Object[] {
544                 String.valueOf(start), String.valueOf(end), String.valueOf(obc)
545             };
546 
547         Object result = null;
548 
549         if (finderClassNameCacheEnabled) {
550             result = FinderCacheUtil.getResult(finderClassName,
551                     finderMethodName, finderParams, finderArgs, this);
552         }
553 
554         if (result == null) {
555             Session session = null;
556 
557             try {
558                 session = openSession();
559 
560                 StringBuilder query = new StringBuilder();
561 
562                 query.append("FROM com.liferay.portal.model.Image ");
563 
564                 if (obc != null) {
565                     query.append("ORDER BY ");
566                     query.append(obc.getOrderBy());
567                 }
568 
569                 else {
570                     query.append("ORDER BY ");
571 
572                     query.append("imageId ASC");
573                 }
574 
575                 Query q = session.createQuery(query.toString());
576 
577                 List<Image> list = null;
578 
579                 if (obc == null) {
580                     list = (List<Image>)QueryUtil.list(q, getDialect(), start,
581                             end, false);
582 
583                     Collections.sort(list);
584                 }
585                 else {
586                     list = (List<Image>)QueryUtil.list(q, getDialect(), start,
587                             end);
588                 }
589 
590                 FinderCacheUtil.putResult(finderClassNameCacheEnabled,
591                     finderClassName, finderMethodName, finderParams,
592                     finderArgs, list);
593 
594                 return list;
595             }
596             catch (Exception e) {
597                 throw processException(e);
598             }
599             finally {
600                 closeSession(session);
601             }
602         }
603         else {
604             return (List<Image>)result;
605         }
606     }
607 
608     public void removeBySize(int size) throws SystemException {
609         for (Image image : findBySize(size)) {
610             remove(image);
611         }
612     }
613 
614     public void removeAll() throws SystemException {
615         for (Image image : findAll()) {
616             remove(image);
617         }
618     }
619 
620     public int countBySize(int size) throws SystemException {
621         boolean finderClassNameCacheEnabled = ImageModelImpl.CACHE_ENABLED;
622         String finderClassName = Image.class.getName();
623         String finderMethodName = "countBySize";
624         String[] finderParams = new String[] { Integer.class.getName() };
625         Object[] finderArgs = new Object[] { new Integer(size) };
626 
627         Object result = null;
628 
629         if (finderClassNameCacheEnabled) {
630             result = FinderCacheUtil.getResult(finderClassName,
631                     finderMethodName, finderParams, finderArgs, this);
632         }
633 
634         if (result == null) {
635             Session session = null;
636 
637             try {
638                 session = openSession();
639 
640                 StringBuilder query = new StringBuilder();
641 
642                 query.append("SELECT COUNT(*) ");
643                 query.append("FROM com.liferay.portal.model.Image WHERE ");
644 
645                 query.append("size_ < ?");
646 
647                 query.append(" ");
648 
649                 Query q = session.createQuery(query.toString());
650 
651                 QueryPos qPos = QueryPos.getInstance(q);
652 
653                 qPos.add(size);
654 
655                 Long count = null;
656 
657                 Iterator<Long> itr = q.list().iterator();
658 
659                 if (itr.hasNext()) {
660                     count = itr.next();
661                 }
662 
663                 if (count == null) {
664                     count = new Long(0);
665                 }
666 
667                 FinderCacheUtil.putResult(finderClassNameCacheEnabled,
668                     finderClassName, finderMethodName, finderParams,
669                     finderArgs, count);
670 
671                 return count.intValue();
672             }
673             catch (Exception e) {
674                 throw processException(e);
675             }
676             finally {
677                 closeSession(session);
678             }
679         }
680         else {
681             return ((Long)result).intValue();
682         }
683     }
684 
685     public int countAll() throws SystemException {
686         boolean finderClassNameCacheEnabled = ImageModelImpl.CACHE_ENABLED;
687         String finderClassName = Image.class.getName();
688         String finderMethodName = "countAll";
689         String[] finderParams = new String[] {  };
690         Object[] finderArgs = new Object[] {  };
691 
692         Object result = null;
693 
694         if (finderClassNameCacheEnabled) {
695             result = FinderCacheUtil.getResult(finderClassName,
696                     finderMethodName, finderParams, finderArgs, this);
697         }
698 
699         if (result == null) {
700             Session session = null;
701 
702             try {
703                 session = openSession();
704 
705                 Query q = session.createQuery(
706                         "SELECT COUNT(*) FROM com.liferay.portal.model.Image");
707 
708                 Long count = null;
709 
710                 Iterator<Long> itr = q.list().iterator();
711 
712                 if (itr.hasNext()) {
713                     count = itr.next();
714                 }
715 
716                 if (count == null) {
717                     count = new Long(0);
718                 }
719 
720                 FinderCacheUtil.putResult(finderClassNameCacheEnabled,
721                     finderClassName, finderMethodName, finderParams,
722                     finderArgs, count);
723 
724                 return count.intValue();
725             }
726             catch (Exception e) {
727                 throw processException(e);
728             }
729             finally {
730                 closeSession(session);
731             }
732         }
733         else {
734             return ((Long)result).intValue();
735         }
736     }
737 
738     public void afterPropertiesSet() {
739         String[] listenerClassNames = StringUtil.split(GetterUtil.getString(
740                     com.liferay.portal.util.PropsUtil.get(
741                         "value.object.listener.com.liferay.portal.model.Image")));
742 
743         if (listenerClassNames.length > 0) {
744             try {
745                 List<ModelListener> listenersList = new ArrayList<ModelListener>();
746 
747                 for (String listenerClassName : listenerClassNames) {
748                     listenersList.add((ModelListener)Class.forName(
749                             listenerClassName).newInstance());
750                 }
751 
752                 listeners = listenersList.toArray(new ModelListener[listenersList.size()]);
753             }
754             catch (Exception e) {
755                 _log.error(e);
756             }
757         }
758     }
759 
760     @BeanReference(name = "com.liferay.portal.service.persistence.AccountPersistence.impl")
761     protected com.liferay.portal.service.persistence.AccountPersistence accountPersistence;
762     @BeanReference(name = "com.liferay.portal.service.persistence.AddressPersistence.impl")
763     protected com.liferay.portal.service.persistence.AddressPersistence addressPersistence;
764     @BeanReference(name = "com.liferay.portal.service.persistence.ClassNamePersistence.impl")
765     protected com.liferay.portal.service.persistence.ClassNamePersistence classNamePersistence;
766     @BeanReference(name = "com.liferay.portal.service.persistence.CompanyPersistence.impl")
767     protected com.liferay.portal.service.persistence.CompanyPersistence companyPersistence;
768     @BeanReference(name = "com.liferay.portal.service.persistence.ContactPersistence.impl")
769     protected com.liferay.portal.service.persistence.ContactPersistence contactPersistence;
770     @BeanReference(name = "com.liferay.portal.service.persistence.CountryPersistence.impl")
771     protected com.liferay.portal.service.persistence.CountryPersistence countryPersistence;
772     @BeanReference(name = "com.liferay.portal.service.persistence.EmailAddressPersistence.impl")
773     protected com.liferay.portal.service.persistence.EmailAddressPersistence emailAddressPersistence;
774     @BeanReference(name = "com.liferay.portal.service.persistence.GroupPersistence.impl")
775     protected com.liferay.portal.service.persistence.GroupPersistence groupPersistence;
776     @BeanReference(name = "com.liferay.portal.service.persistence.ImagePersistence.impl")
777     protected com.liferay.portal.service.persistence.ImagePersistence imagePersistence;
778     @BeanReference(name = "com.liferay.portal.service.persistence.LayoutPersistence.impl")
779     protected com.liferay.portal.service.persistence.LayoutPersistence layoutPersistence;
780     @BeanReference(name = "com.liferay.portal.service.persistence.LayoutSetPersistence.impl")
781     protected com.liferay.portal.service.persistence.LayoutSetPersistence layoutSetPersistence;
782     @BeanReference(name = "com.liferay.portal.service.persistence.ListTypePersistence.impl")
783     protected com.liferay.portal.service.persistence.ListTypePersistence listTypePersistence;
784     @BeanReference(name = "com.liferay.portal.service.persistence.MembershipRequestPersistence.impl")
785     protected com.liferay.portal.service.persistence.MembershipRequestPersistence membershipRequestPersistence;
786     @BeanReference(name = "com.liferay.portal.service.persistence.OrganizationPersistence.impl")
787     protected com.liferay.portal.service.persistence.OrganizationPersistence organizationPersistence;
788     @BeanReference(name = "com.liferay.portal.service.persistence.OrgGroupPermissionPersistence.impl")
789     protected com.liferay.portal.service.persistence.OrgGroupPermissionPersistence orgGroupPermissionPersistence;
790     @BeanReference(name = "com.liferay.portal.service.persistence.OrgGroupRolePersistence.impl")
791     protected com.liferay.portal.service.persistence.OrgGroupRolePersistence orgGroupRolePersistence;
792     @BeanReference(name = "com.liferay.portal.service.persistence.OrgLaborPersistence.impl")
793     protected com.liferay.portal.service.persistence.OrgLaborPersistence orgLaborPersistence;
794     @BeanReference(name = "com.liferay.portal.service.persistence.PasswordPolicyPersistence.impl")
795     protected com.liferay.portal.service.persistence.PasswordPolicyPersistence passwordPolicyPersistence;
796     @BeanReference(name = "com.liferay.portal.service.persistence.PasswordPolicyRelPersistence.impl")
797     protected com.liferay.portal.service.persistence.PasswordPolicyRelPersistence passwordPolicyRelPersistence;
798     @BeanReference(name = "com.liferay.portal.service.persistence.PasswordTrackerPersistence.impl")
799     protected com.liferay.portal.service.persistence.PasswordTrackerPersistence passwordTrackerPersistence;
800     @BeanReference(name = "com.liferay.portal.service.persistence.PermissionPersistence.impl")
801     protected com.liferay.portal.service.persistence.PermissionPersistence permissionPersistence;
802     @BeanReference(name = "com.liferay.portal.service.persistence.PhonePersistence.impl")
803     protected com.liferay.portal.service.persistence.PhonePersistence phonePersistence;
804     @BeanReference(name = "com.liferay.portal.service.persistence.PluginSettingPersistence.impl")
805     protected com.liferay.portal.service.persistence.PluginSettingPersistence pluginSettingPersistence;
806     @BeanReference(name = "com.liferay.portal.service.persistence.PortletPersistence.impl")
807     protected com.liferay.portal.service.persistence.PortletPersistence portletPersistence;
808     @BeanReference(name = "com.liferay.portal.service.persistence.PortletPreferencesPersistence.impl")
809     protected com.liferay.portal.service.persistence.PortletPreferencesPersistence portletPreferencesPersistence;
810     @BeanReference(name = "com.liferay.portal.service.persistence.RegionPersistence.impl")
811     protected com.liferay.portal.service.persistence.RegionPersistence regionPersistence;
812     @BeanReference(name = "com.liferay.portal.service.persistence.ReleasePersistence.impl")
813     protected com.liferay.portal.service.persistence.ReleasePersistence releasePersistence;
814     @BeanReference(name = "com.liferay.portal.service.persistence.ResourcePersistence.impl")
815     protected com.liferay.portal.service.persistence.ResourcePersistence resourcePersistence;
816     @BeanReference(name = "com.liferay.portal.service.persistence.ResourceCodePersistence.impl")
817     protected com.liferay.portal.service.persistence.ResourceCodePersistence resourceCodePersistence;
818     @BeanReference(name = "com.liferay.portal.service.persistence.RolePersistence.impl")
819     protected com.liferay.portal.service.persistence.RolePersistence rolePersistence;
820     @BeanReference(name = "com.liferay.portal.service.persistence.ServiceComponentPersistence.impl")
821     protected com.liferay.portal.service.persistence.ServiceComponentPersistence serviceComponentPersistence;
822     @BeanReference(name = "com.liferay.portal.service.persistence.PortletItemPersistence.impl")
823     protected com.liferay.portal.service.persistence.PortletItemPersistence portletItemPersistence;
824     @BeanReference(name = "com.liferay.portal.service.persistence.SubscriptionPersistence.impl")
825     protected com.liferay.portal.service.persistence.SubscriptionPersistence subscriptionPersistence;
826     @BeanReference(name = "com.liferay.portal.service.persistence.UserPersistence.impl")
827     protected com.liferay.portal.service.persistence.UserPersistence userPersistence;
828     @BeanReference(name = "com.liferay.portal.service.persistence.UserGroupPersistence.impl")
829     protected com.liferay.portal.service.persistence.UserGroupPersistence userGroupPersistence;
830     @BeanReference(name = "com.liferay.portal.service.persistence.UserGroupRolePersistence.impl")
831     protected com.liferay.portal.service.persistence.UserGroupRolePersistence userGroupRolePersistence;
832     @BeanReference(name = "com.liferay.portal.service.persistence.UserIdMapperPersistence.impl")
833     protected com.liferay.portal.service.persistence.UserIdMapperPersistence userIdMapperPersistence;
834     @BeanReference(name = "com.liferay.portal.service.persistence.UserTrackerPersistence.impl")
835     protected com.liferay.portal.service.persistence.UserTrackerPersistence userTrackerPersistence;
836     @BeanReference(name = "com.liferay.portal.service.persistence.UserTrackerPathPersistence.impl")
837     protected com.liferay.portal.service.persistence.UserTrackerPathPersistence userTrackerPathPersistence;
838     @BeanReference(name = "com.liferay.portal.service.persistence.WebDAVPropsPersistence.impl")
839     protected com.liferay.portal.service.persistence.WebDAVPropsPersistence webDAVPropsPersistence;
840     @BeanReference(name = "com.liferay.portal.service.persistence.WebsitePersistence.impl")
841     protected com.liferay.portal.service.persistence.WebsitePersistence websitePersistence;
842     private static Log _log = LogFactoryUtil.getLog(ImagePersistenceImpl.class);
843 }