1
14
15 package com.liferay.portlet.documentlibrary.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.kernel.util.ReferenceRegistry;
21
22 import com.liferay.portlet.documentlibrary.model.DLFileVersion;
23
24 import java.util.List;
25
26
39 public class DLFileVersionUtil {
40
43 public static void clearCache() {
44 getPersistence().clearCache();
45 }
46
47
50 public static void clearCache(DLFileVersion dlFileVersion) {
51 getPersistence().clearCache(dlFileVersion);
52 }
53
54
57 public int countWithDynamicQuery(DynamicQuery dynamicQuery)
58 throws SystemException {
59 return getPersistence().countWithDynamicQuery(dynamicQuery);
60 }
61
62
65 public static List<Object> findWithDynamicQuery(DynamicQuery dynamicQuery)
66 throws SystemException {
67 return getPersistence().findWithDynamicQuery(dynamicQuery);
68 }
69
70
73 public static List<Object> findWithDynamicQuery(DynamicQuery dynamicQuery,
74 int start, int end) throws SystemException {
75 return getPersistence().findWithDynamicQuery(dynamicQuery, start, end);
76 }
77
78
81 public static DLFileVersion remove(DLFileVersion dlFileVersion)
82 throws SystemException {
83 return getPersistence().remove(dlFileVersion);
84 }
85
86
89 public static DLFileVersion update(DLFileVersion dlFileVersion,
90 boolean merge) throws SystemException {
91 return getPersistence().update(dlFileVersion, merge);
92 }
93
94 public static void cacheResult(
95 com.liferay.portlet.documentlibrary.model.DLFileVersion dlFileVersion) {
96 getPersistence().cacheResult(dlFileVersion);
97 }
98
99 public static void cacheResult(
100 java.util.List<com.liferay.portlet.documentlibrary.model.DLFileVersion> dlFileVersions) {
101 getPersistence().cacheResult(dlFileVersions);
102 }
103
104 public static com.liferay.portlet.documentlibrary.model.DLFileVersion create(
105 long fileVersionId) {
106 return getPersistence().create(fileVersionId);
107 }
108
109 public static com.liferay.portlet.documentlibrary.model.DLFileVersion remove(
110 long fileVersionId)
111 throws com.liferay.portal.SystemException,
112 com.liferay.portlet.documentlibrary.NoSuchFileVersionException {
113 return getPersistence().remove(fileVersionId);
114 }
115
116
119 public static com.liferay.portlet.documentlibrary.model.DLFileVersion update(
120 com.liferay.portlet.documentlibrary.model.DLFileVersion dlFileVersion)
121 throws com.liferay.portal.SystemException {
122 return getPersistence().update(dlFileVersion);
123 }
124
125 public static com.liferay.portlet.documentlibrary.model.DLFileVersion updateImpl(
126 com.liferay.portlet.documentlibrary.model.DLFileVersion dlFileVersion,
127 boolean merge) throws com.liferay.portal.SystemException {
128 return getPersistence().updateImpl(dlFileVersion, merge);
129 }
130
131 public static com.liferay.portlet.documentlibrary.model.DLFileVersion findByPrimaryKey(
132 long fileVersionId)
133 throws com.liferay.portal.SystemException,
134 com.liferay.portlet.documentlibrary.NoSuchFileVersionException {
135 return getPersistence().findByPrimaryKey(fileVersionId);
136 }
137
138 public static com.liferay.portlet.documentlibrary.model.DLFileVersion fetchByPrimaryKey(
139 long fileVersionId) throws com.liferay.portal.SystemException {
140 return getPersistence().fetchByPrimaryKey(fileVersionId);
141 }
142
143 public static java.util.List<com.liferay.portlet.documentlibrary.model.DLFileVersion> findByF_N(
144 long folderId, java.lang.String name)
145 throws com.liferay.portal.SystemException {
146 return getPersistence().findByF_N(folderId, name);
147 }
148
149 public static java.util.List<com.liferay.portlet.documentlibrary.model.DLFileVersion> findByF_N(
150 long folderId, java.lang.String name, int start, int end)
151 throws com.liferay.portal.SystemException {
152 return getPersistence().findByF_N(folderId, name, start, end);
153 }
154
155 public static java.util.List<com.liferay.portlet.documentlibrary.model.DLFileVersion> findByF_N(
156 long folderId, java.lang.String name, int start, int end,
157 com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
158 throws com.liferay.portal.SystemException {
159 return getPersistence()
160 .findByF_N(folderId, name, start, end, orderByComparator);
161 }
162
163 public static com.liferay.portlet.documentlibrary.model.DLFileVersion findByF_N_First(
164 long folderId, java.lang.String name,
165 com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
166 throws com.liferay.portal.SystemException,
167 com.liferay.portlet.documentlibrary.NoSuchFileVersionException {
168 return getPersistence()
169 .findByF_N_First(folderId, name, orderByComparator);
170 }
171
172 public static com.liferay.portlet.documentlibrary.model.DLFileVersion findByF_N_Last(
173 long folderId, java.lang.String name,
174 com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
175 throws com.liferay.portal.SystemException,
176 com.liferay.portlet.documentlibrary.NoSuchFileVersionException {
177 return getPersistence().findByF_N_Last(folderId, name, orderByComparator);
178 }
179
180 public static com.liferay.portlet.documentlibrary.model.DLFileVersion[] findByF_N_PrevAndNext(
181 long fileVersionId, long folderId, java.lang.String name,
182 com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
183 throws com.liferay.portal.SystemException,
184 com.liferay.portlet.documentlibrary.NoSuchFileVersionException {
185 return getPersistence()
186 .findByF_N_PrevAndNext(fileVersionId, folderId, name,
187 orderByComparator);
188 }
189
190 public static com.liferay.portlet.documentlibrary.model.DLFileVersion findByF_N_V(
191 long folderId, java.lang.String name, double version)
192 throws com.liferay.portal.SystemException,
193 com.liferay.portlet.documentlibrary.NoSuchFileVersionException {
194 return getPersistence().findByF_N_V(folderId, name, version);
195 }
196
197 public static com.liferay.portlet.documentlibrary.model.DLFileVersion fetchByF_N_V(
198 long folderId, java.lang.String name, double version)
199 throws com.liferay.portal.SystemException {
200 return getPersistence().fetchByF_N_V(folderId, name, version);
201 }
202
203 public static com.liferay.portlet.documentlibrary.model.DLFileVersion fetchByF_N_V(
204 long folderId, java.lang.String name, double version,
205 boolean retrieveFromCache) throws com.liferay.portal.SystemException {
206 return getPersistence()
207 .fetchByF_N_V(folderId, name, version, retrieveFromCache);
208 }
209
210 public static java.util.List<com.liferay.portlet.documentlibrary.model.DLFileVersion> findAll()
211 throws com.liferay.portal.SystemException {
212 return getPersistence().findAll();
213 }
214
215 public static java.util.List<com.liferay.portlet.documentlibrary.model.DLFileVersion> findAll(
216 int start, int end) throws com.liferay.portal.SystemException {
217 return getPersistence().findAll(start, end);
218 }
219
220 public static java.util.List<com.liferay.portlet.documentlibrary.model.DLFileVersion> findAll(
221 int start, int end,
222 com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
223 throws com.liferay.portal.SystemException {
224 return getPersistence().findAll(start, end, orderByComparator);
225 }
226
227 public static void removeByF_N(long folderId, java.lang.String name)
228 throws com.liferay.portal.SystemException {
229 getPersistence().removeByF_N(folderId, name);
230 }
231
232 public static void removeByF_N_V(long folderId, java.lang.String name,
233 double version)
234 throws com.liferay.portal.SystemException,
235 com.liferay.portlet.documentlibrary.NoSuchFileVersionException {
236 getPersistence().removeByF_N_V(folderId, name, version);
237 }
238
239 public static void removeAll() throws com.liferay.portal.SystemException {
240 getPersistence().removeAll();
241 }
242
243 public static int countByF_N(long folderId, java.lang.String name)
244 throws com.liferay.portal.SystemException {
245 return getPersistence().countByF_N(folderId, name);
246 }
247
248 public static int countByF_N_V(long folderId, java.lang.String name,
249 double version) throws com.liferay.portal.SystemException {
250 return getPersistence().countByF_N_V(folderId, name, version);
251 }
252
253 public static int countAll() throws com.liferay.portal.SystemException {
254 return getPersistence().countAll();
255 }
256
257 public static DLFileVersionPersistence getPersistence() {
258 if (_persistence == null) {
259 _persistence = (DLFileVersionPersistence)PortalBeanLocatorUtil.locate(DLFileVersionPersistence.class.getName());
260
261 ReferenceRegistry.registerReference(DLFileVersionUtil.class,
262 "_persistence");
263 }
264
265 return _persistence;
266 }
267
268 public void setPersistence(DLFileVersionPersistence persistence) {
269 _persistence = persistence;
270
271 ReferenceRegistry.registerReference(DLFileVersionUtil.class,
272 "_persistence");
273 }
274
275 private static DLFileVersionPersistence _persistence;
276 }