1
14
15 package com.liferay.portal.service.persistence;
16
17 import com.liferay.portal.NoSuchClassNameException;
18 import com.liferay.portal.NoSuchModelException;
19 import com.liferay.portal.kernel.annotation.BeanReference;
20 import com.liferay.portal.kernel.cache.CacheRegistry;
21 import com.liferay.portal.kernel.dao.orm.EntityCacheUtil;
22 import com.liferay.portal.kernel.dao.orm.FinderCacheUtil;
23 import com.liferay.portal.kernel.dao.orm.FinderPath;
24 import com.liferay.portal.kernel.dao.orm.Query;
25 import com.liferay.portal.kernel.dao.orm.QueryPos;
26 import com.liferay.portal.kernel.dao.orm.QueryUtil;
27 import com.liferay.portal.kernel.dao.orm.Session;
28 import com.liferay.portal.kernel.exception.SystemException;
29 import com.liferay.portal.kernel.log.Log;
30 import com.liferay.portal.kernel.log.LogFactoryUtil;
31 import com.liferay.portal.kernel.util.GetterUtil;
32 import com.liferay.portal.kernel.util.OrderByComparator;
33 import com.liferay.portal.kernel.util.StringBundler;
34 import com.liferay.portal.kernel.util.StringPool;
35 import com.liferay.portal.kernel.util.StringUtil;
36 import com.liferay.portal.kernel.util.Validator;
37 import com.liferay.portal.model.ClassName;
38 import com.liferay.portal.model.ModelListener;
39 import com.liferay.portal.model.impl.ClassNameImpl;
40 import com.liferay.portal.model.impl.ClassNameModelImpl;
41 import com.liferay.portal.service.persistence.impl.BasePersistenceImpl;
42
43 import java.io.Serializable;
44
45 import java.util.ArrayList;
46 import java.util.Collections;
47 import java.util.List;
48
49
62 public class ClassNamePersistenceImpl extends BasePersistenceImpl<ClassName>
63 implements ClassNamePersistence {
64 public static final String FINDER_CLASS_NAME_ENTITY = ClassNameImpl.class.getName();
65 public static final String FINDER_CLASS_NAME_LIST = FINDER_CLASS_NAME_ENTITY +
66 ".List";
67 public static final FinderPath FINDER_PATH_FETCH_BY_VALUE = new FinderPath(ClassNameModelImpl.ENTITY_CACHE_ENABLED,
68 ClassNameModelImpl.FINDER_CACHE_ENABLED, FINDER_CLASS_NAME_ENTITY,
69 "fetchByValue", new String[] { String.class.getName() });
70 public static final FinderPath FINDER_PATH_COUNT_BY_VALUE = new FinderPath(ClassNameModelImpl.ENTITY_CACHE_ENABLED,
71 ClassNameModelImpl.FINDER_CACHE_ENABLED, FINDER_CLASS_NAME_LIST,
72 "countByValue", new String[] { String.class.getName() });
73 public static final FinderPath FINDER_PATH_FIND_ALL = new FinderPath(ClassNameModelImpl.ENTITY_CACHE_ENABLED,
74 ClassNameModelImpl.FINDER_CACHE_ENABLED, FINDER_CLASS_NAME_LIST,
75 "findAll", new String[0]);
76 public static final FinderPath FINDER_PATH_COUNT_ALL = new FinderPath(ClassNameModelImpl.ENTITY_CACHE_ENABLED,
77 ClassNameModelImpl.FINDER_CACHE_ENABLED, FINDER_CLASS_NAME_LIST,
78 "countAll", new String[0]);
79
80 public void cacheResult(ClassName className) {
81 EntityCacheUtil.putResult(ClassNameModelImpl.ENTITY_CACHE_ENABLED,
82 ClassNameImpl.class, className.getPrimaryKey(), className);
83
84 FinderCacheUtil.putResult(FINDER_PATH_FETCH_BY_VALUE,
85 new Object[] { className.getValue() }, className);
86 }
87
88 public void cacheResult(List<ClassName> classNames) {
89 for (ClassName className : classNames) {
90 if (EntityCacheUtil.getResult(
91 ClassNameModelImpl.ENTITY_CACHE_ENABLED,
92 ClassNameImpl.class, className.getPrimaryKey(), this) == null) {
93 cacheResult(className);
94 }
95 }
96 }
97
98 public void clearCache() {
99 CacheRegistry.clear(ClassNameImpl.class.getName());
100 EntityCacheUtil.clearCache(ClassNameImpl.class.getName());
101 FinderCacheUtil.clearCache(FINDER_CLASS_NAME_ENTITY);
102 FinderCacheUtil.clearCache(FINDER_CLASS_NAME_LIST);
103 }
104
105 public ClassName create(long classNameId) {
106 ClassName className = new ClassNameImpl();
107
108 className.setNew(true);
109 className.setPrimaryKey(classNameId);
110
111 return className;
112 }
113
114 public ClassName remove(Serializable primaryKey)
115 throws NoSuchModelException, SystemException {
116 return remove(((Long)primaryKey).longValue());
117 }
118
119 public ClassName remove(long classNameId)
120 throws NoSuchClassNameException, SystemException {
121 Session session = null;
122
123 try {
124 session = openSession();
125
126 ClassName className = (ClassName)session.get(ClassNameImpl.class,
127 new Long(classNameId));
128
129 if (className == null) {
130 if (_log.isWarnEnabled()) {
131 _log.warn(_NO_SUCH_ENTITY_WITH_PRIMARY_KEY + classNameId);
132 }
133
134 throw new NoSuchClassNameException(_NO_SUCH_ENTITY_WITH_PRIMARY_KEY +
135 classNameId);
136 }
137
138 return remove(className);
139 }
140 catch (NoSuchClassNameException nsee) {
141 throw nsee;
142 }
143 catch (Exception e) {
144 throw processException(e);
145 }
146 finally {
147 closeSession(session);
148 }
149 }
150
151 public ClassName remove(ClassName className) throws SystemException {
152 for (ModelListener<ClassName> listener : listeners) {
153 listener.onBeforeRemove(className);
154 }
155
156 className = removeImpl(className);
157
158 for (ModelListener<ClassName> listener : listeners) {
159 listener.onAfterRemove(className);
160 }
161
162 return className;
163 }
164
165 protected ClassName removeImpl(ClassName className)
166 throws SystemException {
167 className = toUnwrappedModel(className);
168
169 Session session = null;
170
171 try {
172 session = openSession();
173
174 if (className.isCachedModel() || BatchSessionUtil.isEnabled()) {
175 Object staleObject = session.get(ClassNameImpl.class,
176 className.getPrimaryKeyObj());
177
178 if (staleObject != null) {
179 session.evict(staleObject);
180 }
181 }
182
183 session.delete(className);
184
185 session.flush();
186 }
187 catch (Exception e) {
188 throw processException(e);
189 }
190 finally {
191 closeSession(session);
192 }
193
194 FinderCacheUtil.clearCache(FINDER_CLASS_NAME_LIST);
195
196 ClassNameModelImpl classNameModelImpl = (ClassNameModelImpl)className;
197
198 FinderCacheUtil.removeResult(FINDER_PATH_FETCH_BY_VALUE,
199 new Object[] { classNameModelImpl.getOriginalValue() });
200
201 EntityCacheUtil.removeResult(ClassNameModelImpl.ENTITY_CACHE_ENABLED,
202 ClassNameImpl.class, className.getPrimaryKey());
203
204 return className;
205 }
206
207 public ClassName updateImpl(com.liferay.portal.model.ClassName className,
208 boolean merge) throws SystemException {
209 className = toUnwrappedModel(className);
210
211 boolean isNew = className.isNew();
212
213 ClassNameModelImpl classNameModelImpl = (ClassNameModelImpl)className;
214
215 Session session = null;
216
217 try {
218 session = openSession();
219
220 BatchSessionUtil.update(session, className, merge);
221
222 className.setNew(false);
223 }
224 catch (Exception e) {
225 throw processException(e);
226 }
227 finally {
228 closeSession(session);
229 }
230
231 FinderCacheUtil.clearCache(FINDER_CLASS_NAME_LIST);
232
233 EntityCacheUtil.putResult(ClassNameModelImpl.ENTITY_CACHE_ENABLED,
234 ClassNameImpl.class, className.getPrimaryKey(), className);
235
236 if (!isNew &&
237 (!Validator.equals(className.getValue(),
238 classNameModelImpl.getOriginalValue()))) {
239 FinderCacheUtil.removeResult(FINDER_PATH_FETCH_BY_VALUE,
240 new Object[] { classNameModelImpl.getOriginalValue() });
241 }
242
243 if (isNew ||
244 (!Validator.equals(className.getValue(),
245 classNameModelImpl.getOriginalValue()))) {
246 FinderCacheUtil.putResult(FINDER_PATH_FETCH_BY_VALUE,
247 new Object[] { className.getValue() }, className);
248 }
249
250 return className;
251 }
252
253 protected ClassName toUnwrappedModel(ClassName className) {
254 if (className instanceof ClassNameImpl) {
255 return className;
256 }
257
258 ClassNameImpl classNameImpl = new ClassNameImpl();
259
260 classNameImpl.setNew(className.isNew());
261 classNameImpl.setPrimaryKey(className.getPrimaryKey());
262
263 classNameImpl.setClassNameId(className.getClassNameId());
264 classNameImpl.setValue(className.getValue());
265
266 return classNameImpl;
267 }
268
269 public ClassName findByPrimaryKey(Serializable primaryKey)
270 throws NoSuchModelException, SystemException {
271 return findByPrimaryKey(((Long)primaryKey).longValue());
272 }
273
274 public ClassName findByPrimaryKey(long classNameId)
275 throws NoSuchClassNameException, SystemException {
276 ClassName className = fetchByPrimaryKey(classNameId);
277
278 if (className == null) {
279 if (_log.isWarnEnabled()) {
280 _log.warn(_NO_SUCH_ENTITY_WITH_PRIMARY_KEY + classNameId);
281 }
282
283 throw new NoSuchClassNameException(_NO_SUCH_ENTITY_WITH_PRIMARY_KEY +
284 classNameId);
285 }
286
287 return className;
288 }
289
290 public ClassName fetchByPrimaryKey(Serializable primaryKey)
291 throws SystemException {
292 return fetchByPrimaryKey(((Long)primaryKey).longValue());
293 }
294
295 public ClassName fetchByPrimaryKey(long classNameId)
296 throws SystemException {
297 ClassName className = (ClassName)EntityCacheUtil.getResult(ClassNameModelImpl.ENTITY_CACHE_ENABLED,
298 ClassNameImpl.class, classNameId, this);
299
300 if (className == null) {
301 Session session = null;
302
303 try {
304 session = openSession();
305
306 className = (ClassName)session.get(ClassNameImpl.class,
307 new Long(classNameId));
308 }
309 catch (Exception e) {
310 throw processException(e);
311 }
312 finally {
313 if (className != null) {
314 cacheResult(className);
315 }
316
317 closeSession(session);
318 }
319 }
320
321 return className;
322 }
323
324 public ClassName findByValue(String value)
325 throws NoSuchClassNameException, SystemException {
326 ClassName className = fetchByValue(value);
327
328 if (className == null) {
329 StringBundler msg = new StringBundler(4);
330
331 msg.append(_NO_SUCH_ENTITY_WITH_KEY);
332
333 msg.append("value=");
334 msg.append(value);
335
336 msg.append(StringPool.CLOSE_CURLY_BRACE);
337
338 if (_log.isWarnEnabled()) {
339 _log.warn(msg.toString());
340 }
341
342 throw new NoSuchClassNameException(msg.toString());
343 }
344
345 return className;
346 }
347
348 public ClassName fetchByValue(String value) throws SystemException {
349 return fetchByValue(value, true);
350 }
351
352 public ClassName fetchByValue(String value, boolean retrieveFromCache)
353 throws SystemException {
354 Object[] finderArgs = new Object[] { value };
355
356 Object result = null;
357
358 if (retrieveFromCache) {
359 result = FinderCacheUtil.getResult(FINDER_PATH_FETCH_BY_VALUE,
360 finderArgs, this);
361 }
362
363 if (result == null) {
364 Session session = null;
365
366 try {
367 session = openSession();
368
369 StringBundler query = new StringBundler(2);
370
371 query.append(_SQL_SELECT_CLASSNAME_WHERE);
372
373 if (value == null) {
374 query.append(_FINDER_COLUMN_VALUE_VALUE_1);
375 }
376 else {
377 if (value.equals(StringPool.BLANK)) {
378 query.append(_FINDER_COLUMN_VALUE_VALUE_3);
379 }
380 else {
381 query.append(_FINDER_COLUMN_VALUE_VALUE_2);
382 }
383 }
384
385 String sql = query.toString();
386
387 Query q = session.createQuery(sql);
388
389 QueryPos qPos = QueryPos.getInstance(q);
390
391 if (value != null) {
392 qPos.add(value);
393 }
394
395 List<ClassName> list = q.list();
396
397 result = list;
398
399 ClassName className = null;
400
401 if (list.isEmpty()) {
402 FinderCacheUtil.putResult(FINDER_PATH_FETCH_BY_VALUE,
403 finderArgs, list);
404 }
405 else {
406 className = list.get(0);
407
408 cacheResult(className);
409
410 if ((className.getValue() == null) ||
411 !className.getValue().equals(value)) {
412 FinderCacheUtil.putResult(FINDER_PATH_FETCH_BY_VALUE,
413 finderArgs, className);
414 }
415 }
416
417 return className;
418 }
419 catch (Exception e) {
420 throw processException(e);
421 }
422 finally {
423 if (result == null) {
424 FinderCacheUtil.putResult(FINDER_PATH_FETCH_BY_VALUE,
425 finderArgs, new ArrayList<ClassName>());
426 }
427
428 closeSession(session);
429 }
430 }
431 else {
432 if (result instanceof List<?>) {
433 return null;
434 }
435 else {
436 return (ClassName)result;
437 }
438 }
439 }
440
441 public List<ClassName> findAll() throws SystemException {
442 return findAll(QueryUtil.ALL_POS, QueryUtil.ALL_POS, null);
443 }
444
445 public List<ClassName> findAll(int start, int end)
446 throws SystemException {
447 return findAll(start, end, null);
448 }
449
450 public List<ClassName> findAll(int start, int end,
451 OrderByComparator orderByComparator) throws SystemException {
452 Object[] finderArgs = new Object[] {
453 String.valueOf(start), String.valueOf(end),
454 String.valueOf(orderByComparator)
455 };
456
457 List<ClassName> list = (List<ClassName>)FinderCacheUtil.getResult(FINDER_PATH_FIND_ALL,
458 finderArgs, this);
459
460 if (list == null) {
461 Session session = null;
462
463 try {
464 session = openSession();
465
466 StringBundler query = null;
467 String sql = null;
468
469 if (orderByComparator != null) {
470 query = new StringBundler(2 +
471 (orderByComparator.getOrderByFields().length * 3));
472
473 query.append(_SQL_SELECT_CLASSNAME);
474
475 appendOrderByComparator(query, _ORDER_BY_ENTITY_ALIAS,
476 orderByComparator);
477
478 sql = query.toString();
479 }
480
481 sql = _SQL_SELECT_CLASSNAME;
482
483 Query q = session.createQuery(sql);
484
485 if (orderByComparator == null) {
486 list = (List<ClassName>)QueryUtil.list(q, getDialect(),
487 start, end, false);
488
489 Collections.sort(list);
490 }
491 else {
492 list = (List<ClassName>)QueryUtil.list(q, getDialect(),
493 start, end);
494 }
495 }
496 catch (Exception e) {
497 throw processException(e);
498 }
499 finally {
500 if (list == null) {
501 list = new ArrayList<ClassName>();
502 }
503
504 cacheResult(list);
505
506 FinderCacheUtil.putResult(FINDER_PATH_FIND_ALL, finderArgs, list);
507
508 closeSession(session);
509 }
510 }
511
512 return list;
513 }
514
515 public void removeByValue(String value)
516 throws NoSuchClassNameException, SystemException {
517 ClassName className = findByValue(value);
518
519 remove(className);
520 }
521
522 public void removeAll() throws SystemException {
523 for (ClassName className : findAll()) {
524 remove(className);
525 }
526 }
527
528 public int countByValue(String value) throws SystemException {
529 Object[] finderArgs = new Object[] { value };
530
531 Long count = (Long)FinderCacheUtil.getResult(FINDER_PATH_COUNT_BY_VALUE,
532 finderArgs, this);
533
534 if (count == null) {
535 Session session = null;
536
537 try {
538 session = openSession();
539
540 StringBundler query = new StringBundler(2);
541
542 query.append(_SQL_COUNT_CLASSNAME_WHERE);
543
544 if (value == null) {
545 query.append(_FINDER_COLUMN_VALUE_VALUE_1);
546 }
547 else {
548 if (value.equals(StringPool.BLANK)) {
549 query.append(_FINDER_COLUMN_VALUE_VALUE_3);
550 }
551 else {
552 query.append(_FINDER_COLUMN_VALUE_VALUE_2);
553 }
554 }
555
556 String sql = query.toString();
557
558 Query q = session.createQuery(sql);
559
560 QueryPos qPos = QueryPos.getInstance(q);
561
562 if (value != null) {
563 qPos.add(value);
564 }
565
566 count = (Long)q.uniqueResult();
567 }
568 catch (Exception e) {
569 throw processException(e);
570 }
571 finally {
572 if (count == null) {
573 count = Long.valueOf(0);
574 }
575
576 FinderCacheUtil.putResult(FINDER_PATH_COUNT_BY_VALUE,
577 finderArgs, count);
578
579 closeSession(session);
580 }
581 }
582
583 return count.intValue();
584 }
585
586 public int countAll() throws SystemException {
587 Object[] finderArgs = new Object[0];
588
589 Long count = (Long)FinderCacheUtil.getResult(FINDER_PATH_COUNT_ALL,
590 finderArgs, this);
591
592 if (count == null) {
593 Session session = null;
594
595 try {
596 session = openSession();
597
598 Query q = session.createQuery(_SQL_COUNT_CLASSNAME);
599
600 count = (Long)q.uniqueResult();
601 }
602 catch (Exception e) {
603 throw processException(e);
604 }
605 finally {
606 if (count == null) {
607 count = Long.valueOf(0);
608 }
609
610 FinderCacheUtil.putResult(FINDER_PATH_COUNT_ALL, finderArgs,
611 count);
612
613 closeSession(session);
614 }
615 }
616
617 return count.intValue();
618 }
619
620 public void afterPropertiesSet() {
621 String[] listenerClassNames = StringUtil.split(GetterUtil.getString(
622 com.liferay.portal.util.PropsUtil.get(
623 "value.object.listener.com.liferay.portal.model.ClassName")));
624
625 if (listenerClassNames.length > 0) {
626 try {
627 List<ModelListener<ClassName>> listenersList = new ArrayList<ModelListener<ClassName>>();
628
629 for (String listenerClassName : listenerClassNames) {
630 listenersList.add((ModelListener<ClassName>)Class.forName(
631 listenerClassName).newInstance());
632 }
633
634 listeners = listenersList.toArray(new ModelListener[listenersList.size()]);
635 }
636 catch (Exception e) {
637 _log.error(e);
638 }
639 }
640 }
641
642 @BeanReference(type = AccountPersistence.class)
643 protected AccountPersistence accountPersistence;
644 @BeanReference(type = AddressPersistence.class)
645 protected AddressPersistence addressPersistence;
646 @BeanReference(type = BrowserTrackerPersistence.class)
647 protected BrowserTrackerPersistence browserTrackerPersistence;
648 @BeanReference(type = ClassNamePersistence.class)
649 protected ClassNamePersistence classNamePersistence;
650 @BeanReference(type = CompanyPersistence.class)
651 protected CompanyPersistence companyPersistence;
652 @BeanReference(type = ContactPersistence.class)
653 protected ContactPersistence contactPersistence;
654 @BeanReference(type = CountryPersistence.class)
655 protected CountryPersistence countryPersistence;
656 @BeanReference(type = EmailAddressPersistence.class)
657 protected EmailAddressPersistence emailAddressPersistence;
658 @BeanReference(type = GroupPersistence.class)
659 protected GroupPersistence groupPersistence;
660 @BeanReference(type = ImagePersistence.class)
661 protected ImagePersistence imagePersistence;
662 @BeanReference(type = LayoutPersistence.class)
663 protected LayoutPersistence layoutPersistence;
664 @BeanReference(type = LayoutPrototypePersistence.class)
665 protected LayoutPrototypePersistence layoutPrototypePersistence;
666 @BeanReference(type = LayoutSetPersistence.class)
667 protected LayoutSetPersistence layoutSetPersistence;
668 @BeanReference(type = LayoutSetPrototypePersistence.class)
669 protected LayoutSetPrototypePersistence layoutSetPrototypePersistence;
670 @BeanReference(type = ListTypePersistence.class)
671 protected ListTypePersistence listTypePersistence;
672 @BeanReference(type = LockPersistence.class)
673 protected LockPersistence lockPersistence;
674 @BeanReference(type = MembershipRequestPersistence.class)
675 protected MembershipRequestPersistence membershipRequestPersistence;
676 @BeanReference(type = OrganizationPersistence.class)
677 protected OrganizationPersistence organizationPersistence;
678 @BeanReference(type = OrgGroupPermissionPersistence.class)
679 protected OrgGroupPermissionPersistence orgGroupPermissionPersistence;
680 @BeanReference(type = OrgGroupRolePersistence.class)
681 protected OrgGroupRolePersistence orgGroupRolePersistence;
682 @BeanReference(type = OrgLaborPersistence.class)
683 protected OrgLaborPersistence orgLaborPersistence;
684 @BeanReference(type = PasswordPolicyPersistence.class)
685 protected PasswordPolicyPersistence passwordPolicyPersistence;
686 @BeanReference(type = PasswordPolicyRelPersistence.class)
687 protected PasswordPolicyRelPersistence passwordPolicyRelPersistence;
688 @BeanReference(type = PasswordTrackerPersistence.class)
689 protected PasswordTrackerPersistence passwordTrackerPersistence;
690 @BeanReference(type = PermissionPersistence.class)
691 protected PermissionPersistence permissionPersistence;
692 @BeanReference(type = PhonePersistence.class)
693 protected PhonePersistence phonePersistence;
694 @BeanReference(type = PluginSettingPersistence.class)
695 protected PluginSettingPersistence pluginSettingPersistence;
696 @BeanReference(type = PortletPersistence.class)
697 protected PortletPersistence portletPersistence;
698 @BeanReference(type = PortletItemPersistence.class)
699 protected PortletItemPersistence portletItemPersistence;
700 @BeanReference(type = PortletPreferencesPersistence.class)
701 protected PortletPreferencesPersistence portletPreferencesPersistence;
702 @BeanReference(type = RegionPersistence.class)
703 protected RegionPersistence regionPersistence;
704 @BeanReference(type = ReleasePersistence.class)
705 protected ReleasePersistence releasePersistence;
706 @BeanReference(type = ResourcePersistence.class)
707 protected ResourcePersistence resourcePersistence;
708 @BeanReference(type = ResourceActionPersistence.class)
709 protected ResourceActionPersistence resourceActionPersistence;
710 @BeanReference(type = ResourceCodePersistence.class)
711 protected ResourceCodePersistence resourceCodePersistence;
712 @BeanReference(type = ResourcePermissionPersistence.class)
713 protected ResourcePermissionPersistence resourcePermissionPersistence;
714 @BeanReference(type = RolePersistence.class)
715 protected RolePersistence rolePersistence;
716 @BeanReference(type = ServiceComponentPersistence.class)
717 protected ServiceComponentPersistence serviceComponentPersistence;
718 @BeanReference(type = ShardPersistence.class)
719 protected ShardPersistence shardPersistence;
720 @BeanReference(type = SubscriptionPersistence.class)
721 protected SubscriptionPersistence subscriptionPersistence;
722 @BeanReference(type = TeamPersistence.class)
723 protected TeamPersistence teamPersistence;
724 @BeanReference(type = UserPersistence.class)
725 protected UserPersistence userPersistence;
726 @BeanReference(type = UserGroupPersistence.class)
727 protected UserGroupPersistence userGroupPersistence;
728 @BeanReference(type = UserGroupGroupRolePersistence.class)
729 protected UserGroupGroupRolePersistence userGroupGroupRolePersistence;
730 @BeanReference(type = UserGroupRolePersistence.class)
731 protected UserGroupRolePersistence userGroupRolePersistence;
732 @BeanReference(type = UserIdMapperPersistence.class)
733 protected UserIdMapperPersistence userIdMapperPersistence;
734 @BeanReference(type = UserTrackerPersistence.class)
735 protected UserTrackerPersistence userTrackerPersistence;
736 @BeanReference(type = UserTrackerPathPersistence.class)
737 protected UserTrackerPathPersistence userTrackerPathPersistence;
738 @BeanReference(type = WebDAVPropsPersistence.class)
739 protected WebDAVPropsPersistence webDAVPropsPersistence;
740 @BeanReference(type = WebsitePersistence.class)
741 protected WebsitePersistence websitePersistence;
742 @BeanReference(type = WorkflowDefinitionLinkPersistence.class)
743 protected WorkflowDefinitionLinkPersistence workflowDefinitionLinkPersistence;
744 @BeanReference(type = WorkflowInstanceLinkPersistence.class)
745 protected WorkflowInstanceLinkPersistence workflowInstanceLinkPersistence;
746 private static final String _SQL_SELECT_CLASSNAME = "SELECT className FROM ClassName className";
747 private static final String _SQL_SELECT_CLASSNAME_WHERE = "SELECT className FROM ClassName className WHERE ";
748 private static final String _SQL_COUNT_CLASSNAME = "SELECT COUNT(className) FROM ClassName className";
749 private static final String _SQL_COUNT_CLASSNAME_WHERE = "SELECT COUNT(className) FROM ClassName className WHERE ";
750 private static final String _FINDER_COLUMN_VALUE_VALUE_1 = "className.value IS NULL";
751 private static final String _FINDER_COLUMN_VALUE_VALUE_2 = "className.value = ?";
752 private static final String _FINDER_COLUMN_VALUE_VALUE_3 = "(className.value IS NULL OR className.value = ?)";
753 private static final String _ORDER_BY_ENTITY_ALIAS = "className.";
754 private static final String _NO_SUCH_ENTITY_WITH_PRIMARY_KEY = "No ClassName exists with the primary key ";
755 private static final String _NO_SUCH_ENTITY_WITH_KEY = "No ClassName exists with the key {";
756 private static Log _log = LogFactoryUtil.getLog(ClassNamePersistenceImpl.class);
757 }