1
14
15 package com.liferay.portal.service.persistence;
16
17 import com.liferay.portal.SystemException;
18 import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
19 import com.liferay.portal.kernel.dao.orm.DynamicQuery;
20 import com.liferay.portal.model.ClassName;
21
22 import java.util.List;
23
24
37 public class ClassNameUtil {
38
41 public static void clearCache() {
42 getPersistence().clearCache();
43 }
44
45
48 public static List<Object> findWithDynamicQuery(DynamicQuery dynamicQuery)
49 throws SystemException {
50 return getPersistence().findWithDynamicQuery(dynamicQuery);
51 }
52
53
56 public static List<Object> findWithDynamicQuery(DynamicQuery dynamicQuery,
57 int start, int end) throws SystemException {
58 return getPersistence().findWithDynamicQuery(dynamicQuery, start, end);
59 }
60
61
64 public static ClassName remove(ClassName className)
65 throws SystemException {
66 return getPersistence().remove(className);
67 }
68
69
72 public static ClassName update(ClassName className, boolean merge)
73 throws SystemException {
74 return getPersistence().update(className, merge);
75 }
76
77 public static void cacheResult(com.liferay.portal.model.ClassName className) {
78 getPersistence().cacheResult(className);
79 }
80
81 public static void cacheResult(
82 java.util.List<com.liferay.portal.model.ClassName> classNames) {
83 getPersistence().cacheResult(classNames);
84 }
85
86 public static com.liferay.portal.model.ClassName create(long classNameId) {
87 return getPersistence().create(classNameId);
88 }
89
90 public static com.liferay.portal.model.ClassName remove(long classNameId)
91 throws com.liferay.portal.NoSuchClassNameException,
92 com.liferay.portal.SystemException {
93 return getPersistence().remove(classNameId);
94 }
95
96
99 public static com.liferay.portal.model.ClassName update(
100 com.liferay.portal.model.ClassName className)
101 throws com.liferay.portal.SystemException {
102 return getPersistence().update(className);
103 }
104
105 public static com.liferay.portal.model.ClassName updateImpl(
106 com.liferay.portal.model.ClassName className, boolean merge)
107 throws com.liferay.portal.SystemException {
108 return getPersistence().updateImpl(className, merge);
109 }
110
111 public static com.liferay.portal.model.ClassName findByPrimaryKey(
112 long classNameId)
113 throws com.liferay.portal.NoSuchClassNameException,
114 com.liferay.portal.SystemException {
115 return getPersistence().findByPrimaryKey(classNameId);
116 }
117
118 public static com.liferay.portal.model.ClassName fetchByPrimaryKey(
119 long classNameId) throws com.liferay.portal.SystemException {
120 return getPersistence().fetchByPrimaryKey(classNameId);
121 }
122
123 public static com.liferay.portal.model.ClassName findByValue(
124 java.lang.String value)
125 throws com.liferay.portal.NoSuchClassNameException,
126 com.liferay.portal.SystemException {
127 return getPersistence().findByValue(value);
128 }
129
130 public static com.liferay.portal.model.ClassName fetchByValue(
131 java.lang.String value) throws com.liferay.portal.SystemException {
132 return getPersistence().fetchByValue(value);
133 }
134
135 public static com.liferay.portal.model.ClassName fetchByValue(
136 java.lang.String value, boolean retrieveFromCache)
137 throws com.liferay.portal.SystemException {
138 return getPersistence().fetchByValue(value, retrieveFromCache);
139 }
140
141 public static java.util.List<com.liferay.portal.model.ClassName> findAll()
142 throws com.liferay.portal.SystemException {
143 return getPersistence().findAll();
144 }
145
146 public static java.util.List<com.liferay.portal.model.ClassName> findAll(
147 int start, int end) throws com.liferay.portal.SystemException {
148 return getPersistence().findAll(start, end);
149 }
150
151 public static java.util.List<com.liferay.portal.model.ClassName> findAll(
152 int start, int end,
153 com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
154 throws com.liferay.portal.SystemException {
155 return getPersistence().findAll(start, end, orderByComparator);
156 }
157
158 public static void removeByValue(java.lang.String value)
159 throws com.liferay.portal.NoSuchClassNameException,
160 com.liferay.portal.SystemException {
161 getPersistence().removeByValue(value);
162 }
163
164 public static void removeAll() throws com.liferay.portal.SystemException {
165 getPersistence().removeAll();
166 }
167
168 public static int countByValue(java.lang.String value)
169 throws com.liferay.portal.SystemException {
170 return getPersistence().countByValue(value);
171 }
172
173 public static int countAll() throws com.liferay.portal.SystemException {
174 return getPersistence().countAll();
175 }
176
177 public static ClassNamePersistence getPersistence() {
178 if (_persistence == null) {
179 _persistence = (ClassNamePersistence)PortalBeanLocatorUtil.locate(ClassNamePersistence.class.getName());
180 }
181
182 return _persistence;
183 }
184
185 public void setPersistence(ClassNamePersistence persistence) {
186 _persistence = persistence;
187 }
188
189 private static ClassNamePersistence _persistence;
190 }