001    /**
002     * Copyright (c) 2000-2012 Liferay, Inc. All rights reserved.
003     *
004     * This library is free software; you can redistribute it and/or modify it under
005     * the terms of the GNU Lesser General Public License as published by the Free
006     * Software Foundation; either version 2.1 of the License, or (at your option)
007     * any later version.
008     *
009     * This library is distributed in the hope that it will be useful, but WITHOUT
010     * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
011     * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
012     * details.
013     */
014    
015    package com.liferay.portlet.dynamicdatamapping.service.persistence;
016    
017    import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
018    import com.liferay.portal.kernel.dao.orm.DynamicQuery;
019    import com.liferay.portal.kernel.exception.SystemException;
020    import com.liferay.portal.kernel.util.OrderByComparator;
021    import com.liferay.portal.kernel.util.ReferenceRegistry;
022    import com.liferay.portal.service.ServiceContext;
023    
024    import com.liferay.portlet.dynamicdatamapping.model.DDMTemplate;
025    
026    import java.util.List;
027    
028    /**
029     * The persistence utility for the d d m template service. This utility wraps {@link DDMTemplatePersistenceImpl} and provides direct access to the database for CRUD operations. This utility should only be used by the service layer, as it must operate within a transaction. Never access this utility in a JSP, controller, model, or other front-end class.
030     *
031     * <p>
032     * Caching information and settings can be found in <code>portal.properties</code>
033     * </p>
034     *
035     * @author Brian Wing Shun Chan
036     * @see DDMTemplatePersistence
037     * @see DDMTemplatePersistenceImpl
038     * @generated
039     */
040    public class DDMTemplateUtil {
041            /*
042             * NOTE FOR DEVELOPERS:
043             *
044             * Never modify this class directly. Modify <code>service.xml</code> and rerun ServiceBuilder to regenerate this class.
045             */
046    
047            /**
048             * @see com.liferay.portal.service.persistence.BasePersistence#clearCache()
049             */
050            public static void clearCache() {
051                    getPersistence().clearCache();
052            }
053    
054            /**
055             * @see com.liferay.portal.service.persistence.BasePersistence#clearCache(com.liferay.portal.model.BaseModel)
056             */
057            public static void clearCache(DDMTemplate ddmTemplate) {
058                    getPersistence().clearCache(ddmTemplate);
059            }
060    
061            /**
062             * @see com.liferay.portal.service.persistence.BasePersistence#countWithDynamicQuery(DynamicQuery)
063             */
064            public long countWithDynamicQuery(DynamicQuery dynamicQuery)
065                    throws SystemException {
066                    return getPersistence().countWithDynamicQuery(dynamicQuery);
067            }
068    
069            /**
070             * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery)
071             */
072            public static List<DDMTemplate> findWithDynamicQuery(
073                    DynamicQuery dynamicQuery) throws SystemException {
074                    return getPersistence().findWithDynamicQuery(dynamicQuery);
075            }
076    
077            /**
078             * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery, int, int)
079             */
080            public static List<DDMTemplate> findWithDynamicQuery(
081                    DynamicQuery dynamicQuery, int start, int end)
082                    throws SystemException {
083                    return getPersistence().findWithDynamicQuery(dynamicQuery, start, end);
084            }
085    
086            /**
087             * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery, int, int, OrderByComparator)
088             */
089            public static List<DDMTemplate> findWithDynamicQuery(
090                    DynamicQuery dynamicQuery, int start, int end,
091                    OrderByComparator orderByComparator) throws SystemException {
092                    return getPersistence()
093                                       .findWithDynamicQuery(dynamicQuery, start, end,
094                            orderByComparator);
095            }
096    
097            /**
098             * @see com.liferay.portal.service.persistence.BasePersistence#update(com.liferay.portal.model.BaseModel)
099             */
100            public static DDMTemplate update(DDMTemplate ddmTemplate)
101                    throws SystemException {
102                    return getPersistence().update(ddmTemplate);
103            }
104    
105            /**
106             * @see com.liferay.portal.service.persistence.BasePersistence#update(com.liferay.portal.model.BaseModel, ServiceContext)
107             */
108            public static DDMTemplate update(DDMTemplate ddmTemplate,
109                    ServiceContext serviceContext) throws SystemException {
110                    return getPersistence().update(ddmTemplate, serviceContext);
111            }
112    
113            /**
114            * Returns all the d d m templates where uuid = &#63;.
115            *
116            * @param uuid the uuid
117            * @return the matching d d m templates
118            * @throws SystemException if a system exception occurred
119            */
120            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByUuid(
121                    java.lang.String uuid)
122                    throws com.liferay.portal.kernel.exception.SystemException {
123                    return getPersistence().findByUuid(uuid);
124            }
125    
126            /**
127            * Returns a range of all the d d m templates where uuid = &#63;.
128            *
129            * <p>
130            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMTemplateModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
131            * </p>
132            *
133            * @param uuid the uuid
134            * @param start the lower bound of the range of d d m templates
135            * @param end the upper bound of the range of d d m templates (not inclusive)
136            * @return the range of matching d d m templates
137            * @throws SystemException if a system exception occurred
138            */
139            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByUuid(
140                    java.lang.String uuid, int start, int end)
141                    throws com.liferay.portal.kernel.exception.SystemException {
142                    return getPersistence().findByUuid(uuid, start, end);
143            }
144    
145            /**
146            * Returns an ordered range of all the d d m templates where uuid = &#63;.
147            *
148            * <p>
149            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMTemplateModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
150            * </p>
151            *
152            * @param uuid the uuid
153            * @param start the lower bound of the range of d d m templates
154            * @param end the upper bound of the range of d d m templates (not inclusive)
155            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
156            * @return the ordered range of matching d d m templates
157            * @throws SystemException if a system exception occurred
158            */
159            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByUuid(
160                    java.lang.String uuid, int start, int end,
161                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
162                    throws com.liferay.portal.kernel.exception.SystemException {
163                    return getPersistence().findByUuid(uuid, start, end, orderByComparator);
164            }
165    
166            /**
167            * Returns the first d d m template in the ordered set where uuid = &#63;.
168            *
169            * @param uuid the uuid
170            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
171            * @return the first matching d d m template
172            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
173            * @throws SystemException if a system exception occurred
174            */
175            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByUuid_First(
176                    java.lang.String uuid,
177                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
178                    throws com.liferay.portal.kernel.exception.SystemException,
179                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
180                    return getPersistence().findByUuid_First(uuid, orderByComparator);
181            }
182    
183            /**
184            * Returns the first d d m template in the ordered set where uuid = &#63;.
185            *
186            * @param uuid the uuid
187            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
188            * @return the first matching d d m template, or <code>null</code> if a matching d d m template could not be found
189            * @throws SystemException if a system exception occurred
190            */
191            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByUuid_First(
192                    java.lang.String uuid,
193                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
194                    throws com.liferay.portal.kernel.exception.SystemException {
195                    return getPersistence().fetchByUuid_First(uuid, orderByComparator);
196            }
197    
198            /**
199            * Returns the last d d m template in the ordered set where uuid = &#63;.
200            *
201            * @param uuid the uuid
202            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
203            * @return the last matching d d m template
204            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
205            * @throws SystemException if a system exception occurred
206            */
207            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByUuid_Last(
208                    java.lang.String uuid,
209                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
210                    throws com.liferay.portal.kernel.exception.SystemException,
211                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
212                    return getPersistence().findByUuid_Last(uuid, orderByComparator);
213            }
214    
215            /**
216            * Returns the last d d m template in the ordered set where uuid = &#63;.
217            *
218            * @param uuid the uuid
219            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
220            * @return the last matching d d m template, or <code>null</code> if a matching d d m template could not be found
221            * @throws SystemException if a system exception occurred
222            */
223            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByUuid_Last(
224                    java.lang.String uuid,
225                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
226                    throws com.liferay.portal.kernel.exception.SystemException {
227                    return getPersistence().fetchByUuid_Last(uuid, orderByComparator);
228            }
229    
230            /**
231            * Returns the d d m templates before and after the current d d m template in the ordered set where uuid = &#63;.
232            *
233            * @param templateId the primary key of the current d d m template
234            * @param uuid the uuid
235            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
236            * @return the previous, current, and next d d m template
237            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a d d m template with the primary key could not be found
238            * @throws SystemException if a system exception occurred
239            */
240            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate[] findByUuid_PrevAndNext(
241                    long templateId, java.lang.String uuid,
242                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
243                    throws com.liferay.portal.kernel.exception.SystemException,
244                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
245                    return getPersistence()
246                                       .findByUuid_PrevAndNext(templateId, uuid, orderByComparator);
247            }
248    
249            /**
250            * Removes all the d d m templates where uuid = &#63; from the database.
251            *
252            * @param uuid the uuid
253            * @throws SystemException if a system exception occurred
254            */
255            public static void removeByUuid(java.lang.String uuid)
256                    throws com.liferay.portal.kernel.exception.SystemException {
257                    getPersistence().removeByUuid(uuid);
258            }
259    
260            /**
261            * Returns the number of d d m templates where uuid = &#63;.
262            *
263            * @param uuid the uuid
264            * @return the number of matching d d m templates
265            * @throws SystemException if a system exception occurred
266            */
267            public static int countByUuid(java.lang.String uuid)
268                    throws com.liferay.portal.kernel.exception.SystemException {
269                    return getPersistence().countByUuid(uuid);
270            }
271    
272            /**
273            * Returns the d d m template where uuid = &#63; and groupId = &#63; or throws a {@link com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException} if it could not be found.
274            *
275            * @param uuid the uuid
276            * @param groupId the group ID
277            * @return the matching d d m template
278            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
279            * @throws SystemException if a system exception occurred
280            */
281            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByUUID_G(
282                    java.lang.String uuid, long groupId)
283                    throws com.liferay.portal.kernel.exception.SystemException,
284                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
285                    return getPersistence().findByUUID_G(uuid, groupId);
286            }
287    
288            /**
289            * Returns the d d m template where uuid = &#63; and groupId = &#63; or returns <code>null</code> if it could not be found. Uses the finder cache.
290            *
291            * @param uuid the uuid
292            * @param groupId the group ID
293            * @return the matching d d m template, or <code>null</code> if a matching d d m template could not be found
294            * @throws SystemException if a system exception occurred
295            */
296            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByUUID_G(
297                    java.lang.String uuid, long groupId)
298                    throws com.liferay.portal.kernel.exception.SystemException {
299                    return getPersistence().fetchByUUID_G(uuid, groupId);
300            }
301    
302            /**
303            * Returns the d d m template where uuid = &#63; and groupId = &#63; or returns <code>null</code> if it could not be found, optionally using the finder cache.
304            *
305            * @param uuid the uuid
306            * @param groupId the group ID
307            * @param retrieveFromCache whether to use the finder cache
308            * @return the matching d d m template, or <code>null</code> if a matching d d m template could not be found
309            * @throws SystemException if a system exception occurred
310            */
311            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByUUID_G(
312                    java.lang.String uuid, long groupId, boolean retrieveFromCache)
313                    throws com.liferay.portal.kernel.exception.SystemException {
314                    return getPersistence().fetchByUUID_G(uuid, groupId, retrieveFromCache);
315            }
316    
317            /**
318            * Removes the d d m template where uuid = &#63; and groupId = &#63; from the database.
319            *
320            * @param uuid the uuid
321            * @param groupId the group ID
322            * @return the d d m template that was removed
323            * @throws SystemException if a system exception occurred
324            */
325            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate removeByUUID_G(
326                    java.lang.String uuid, long groupId)
327                    throws com.liferay.portal.kernel.exception.SystemException,
328                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
329                    return getPersistence().removeByUUID_G(uuid, groupId);
330            }
331    
332            /**
333            * Returns the number of d d m templates where uuid = &#63; and groupId = &#63;.
334            *
335            * @param uuid the uuid
336            * @param groupId the group ID
337            * @return the number of matching d d m templates
338            * @throws SystemException if a system exception occurred
339            */
340            public static int countByUUID_G(java.lang.String uuid, long groupId)
341                    throws com.liferay.portal.kernel.exception.SystemException {
342                    return getPersistence().countByUUID_G(uuid, groupId);
343            }
344    
345            /**
346            * Returns all the d d m templates where uuid = &#63; and companyId = &#63;.
347            *
348            * @param uuid the uuid
349            * @param companyId the company ID
350            * @return the matching d d m templates
351            * @throws SystemException if a system exception occurred
352            */
353            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByUuid_C(
354                    java.lang.String uuid, long companyId)
355                    throws com.liferay.portal.kernel.exception.SystemException {
356                    return getPersistence().findByUuid_C(uuid, companyId);
357            }
358    
359            /**
360            * Returns a range of all the d d m templates where uuid = &#63; and companyId = &#63;.
361            *
362            * <p>
363            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMTemplateModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
364            * </p>
365            *
366            * @param uuid the uuid
367            * @param companyId the company ID
368            * @param start the lower bound of the range of d d m templates
369            * @param end the upper bound of the range of d d m templates (not inclusive)
370            * @return the range of matching d d m templates
371            * @throws SystemException if a system exception occurred
372            */
373            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByUuid_C(
374                    java.lang.String uuid, long companyId, int start, int end)
375                    throws com.liferay.portal.kernel.exception.SystemException {
376                    return getPersistence().findByUuid_C(uuid, companyId, start, end);
377            }
378    
379            /**
380            * Returns an ordered range of all the d d m templates where uuid = &#63; and companyId = &#63;.
381            *
382            * <p>
383            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMTemplateModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
384            * </p>
385            *
386            * @param uuid the uuid
387            * @param companyId the company ID
388            * @param start the lower bound of the range of d d m templates
389            * @param end the upper bound of the range of d d m templates (not inclusive)
390            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
391            * @return the ordered range of matching d d m templates
392            * @throws SystemException if a system exception occurred
393            */
394            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByUuid_C(
395                    java.lang.String uuid, long companyId, int start, int end,
396                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
397                    throws com.liferay.portal.kernel.exception.SystemException {
398                    return getPersistence()
399                                       .findByUuid_C(uuid, companyId, start, end, orderByComparator);
400            }
401    
402            /**
403            * Returns the first d d m template in the ordered set where uuid = &#63; and companyId = &#63;.
404            *
405            * @param uuid the uuid
406            * @param companyId the company ID
407            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
408            * @return the first matching d d m template
409            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
410            * @throws SystemException if a system exception occurred
411            */
412            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByUuid_C_First(
413                    java.lang.String uuid, long companyId,
414                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
415                    throws com.liferay.portal.kernel.exception.SystemException,
416                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
417                    return getPersistence()
418                                       .findByUuid_C_First(uuid, companyId, orderByComparator);
419            }
420    
421            /**
422            * Returns the first d d m template in the ordered set where uuid = &#63; and companyId = &#63;.
423            *
424            * @param uuid the uuid
425            * @param companyId the company ID
426            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
427            * @return the first matching d d m template, or <code>null</code> if a matching d d m template could not be found
428            * @throws SystemException if a system exception occurred
429            */
430            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByUuid_C_First(
431                    java.lang.String uuid, long companyId,
432                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
433                    throws com.liferay.portal.kernel.exception.SystemException {
434                    return getPersistence()
435                                       .fetchByUuid_C_First(uuid, companyId, orderByComparator);
436            }
437    
438            /**
439            * Returns the last d d m template in the ordered set where uuid = &#63; and companyId = &#63;.
440            *
441            * @param uuid the uuid
442            * @param companyId the company ID
443            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
444            * @return the last matching d d m template
445            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
446            * @throws SystemException if a system exception occurred
447            */
448            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByUuid_C_Last(
449                    java.lang.String uuid, long companyId,
450                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
451                    throws com.liferay.portal.kernel.exception.SystemException,
452                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
453                    return getPersistence()
454                                       .findByUuid_C_Last(uuid, companyId, orderByComparator);
455            }
456    
457            /**
458            * Returns the last d d m template in the ordered set where uuid = &#63; and companyId = &#63;.
459            *
460            * @param uuid the uuid
461            * @param companyId the company ID
462            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
463            * @return the last matching d d m template, or <code>null</code> if a matching d d m template could not be found
464            * @throws SystemException if a system exception occurred
465            */
466            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByUuid_C_Last(
467                    java.lang.String uuid, long companyId,
468                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
469                    throws com.liferay.portal.kernel.exception.SystemException {
470                    return getPersistence()
471                                       .fetchByUuid_C_Last(uuid, companyId, orderByComparator);
472            }
473    
474            /**
475            * Returns the d d m templates before and after the current d d m template in the ordered set where uuid = &#63; and companyId = &#63;.
476            *
477            * @param templateId the primary key of the current d d m template
478            * @param uuid the uuid
479            * @param companyId the company ID
480            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
481            * @return the previous, current, and next d d m template
482            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a d d m template with the primary key could not be found
483            * @throws SystemException if a system exception occurred
484            */
485            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate[] findByUuid_C_PrevAndNext(
486                    long templateId, java.lang.String uuid, long companyId,
487                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
488                    throws com.liferay.portal.kernel.exception.SystemException,
489                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
490                    return getPersistence()
491                                       .findByUuid_C_PrevAndNext(templateId, uuid, companyId,
492                            orderByComparator);
493            }
494    
495            /**
496            * Removes all the d d m templates where uuid = &#63; and companyId = &#63; from the database.
497            *
498            * @param uuid the uuid
499            * @param companyId the company ID
500            * @throws SystemException if a system exception occurred
501            */
502            public static void removeByUuid_C(java.lang.String uuid, long companyId)
503                    throws com.liferay.portal.kernel.exception.SystemException {
504                    getPersistence().removeByUuid_C(uuid, companyId);
505            }
506    
507            /**
508            * Returns the number of d d m templates where uuid = &#63; and companyId = &#63;.
509            *
510            * @param uuid the uuid
511            * @param companyId the company ID
512            * @return the number of matching d d m templates
513            * @throws SystemException if a system exception occurred
514            */
515            public static int countByUuid_C(java.lang.String uuid, long companyId)
516                    throws com.liferay.portal.kernel.exception.SystemException {
517                    return getPersistence().countByUuid_C(uuid, companyId);
518            }
519    
520            /**
521            * Returns all the d d m templates where groupId = &#63;.
522            *
523            * @param groupId the group ID
524            * @return the matching d d m templates
525            * @throws SystemException if a system exception occurred
526            */
527            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByGroupId(
528                    long groupId)
529                    throws com.liferay.portal.kernel.exception.SystemException {
530                    return getPersistence().findByGroupId(groupId);
531            }
532    
533            /**
534            * Returns a range of all the d d m templates where groupId = &#63;.
535            *
536            * <p>
537            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMTemplateModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
538            * </p>
539            *
540            * @param groupId the group ID
541            * @param start the lower bound of the range of d d m templates
542            * @param end the upper bound of the range of d d m templates (not inclusive)
543            * @return the range of matching d d m templates
544            * @throws SystemException if a system exception occurred
545            */
546            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByGroupId(
547                    long groupId, int start, int end)
548                    throws com.liferay.portal.kernel.exception.SystemException {
549                    return getPersistence().findByGroupId(groupId, start, end);
550            }
551    
552            /**
553            * Returns an ordered range of all the d d m templates where groupId = &#63;.
554            *
555            * <p>
556            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMTemplateModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
557            * </p>
558            *
559            * @param groupId the group ID
560            * @param start the lower bound of the range of d d m templates
561            * @param end the upper bound of the range of d d m templates (not inclusive)
562            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
563            * @return the ordered range of matching d d m templates
564            * @throws SystemException if a system exception occurred
565            */
566            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByGroupId(
567                    long groupId, int start, int end,
568                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
569                    throws com.liferay.portal.kernel.exception.SystemException {
570                    return getPersistence()
571                                       .findByGroupId(groupId, start, end, orderByComparator);
572            }
573    
574            /**
575            * Returns the first d d m template in the ordered set where groupId = &#63;.
576            *
577            * @param groupId the group ID
578            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
579            * @return the first matching d d m template
580            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
581            * @throws SystemException if a system exception occurred
582            */
583            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByGroupId_First(
584                    long groupId,
585                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
586                    throws com.liferay.portal.kernel.exception.SystemException,
587                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
588                    return getPersistence().findByGroupId_First(groupId, orderByComparator);
589            }
590    
591            /**
592            * Returns the first d d m template in the ordered set where groupId = &#63;.
593            *
594            * @param groupId the group ID
595            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
596            * @return the first matching d d m template, or <code>null</code> if a matching d d m template could not be found
597            * @throws SystemException if a system exception occurred
598            */
599            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByGroupId_First(
600                    long groupId,
601                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
602                    throws com.liferay.portal.kernel.exception.SystemException {
603                    return getPersistence().fetchByGroupId_First(groupId, orderByComparator);
604            }
605    
606            /**
607            * Returns the last d d m template in the ordered set where groupId = &#63;.
608            *
609            * @param groupId the group ID
610            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
611            * @return the last matching d d m template
612            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
613            * @throws SystemException if a system exception occurred
614            */
615            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByGroupId_Last(
616                    long groupId,
617                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
618                    throws com.liferay.portal.kernel.exception.SystemException,
619                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
620                    return getPersistence().findByGroupId_Last(groupId, orderByComparator);
621            }
622    
623            /**
624            * Returns the last d d m template in the ordered set where groupId = &#63;.
625            *
626            * @param groupId the group ID
627            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
628            * @return the last matching d d m template, or <code>null</code> if a matching d d m template could not be found
629            * @throws SystemException if a system exception occurred
630            */
631            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByGroupId_Last(
632                    long groupId,
633                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
634                    throws com.liferay.portal.kernel.exception.SystemException {
635                    return getPersistence().fetchByGroupId_Last(groupId, orderByComparator);
636            }
637    
638            /**
639            * Returns the d d m templates before and after the current d d m template in the ordered set where groupId = &#63;.
640            *
641            * @param templateId the primary key of the current d d m template
642            * @param groupId the group ID
643            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
644            * @return the previous, current, and next d d m template
645            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a d d m template with the primary key could not be found
646            * @throws SystemException if a system exception occurred
647            */
648            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate[] findByGroupId_PrevAndNext(
649                    long templateId, long groupId,
650                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
651                    throws com.liferay.portal.kernel.exception.SystemException,
652                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
653                    return getPersistence()
654                                       .findByGroupId_PrevAndNext(templateId, groupId,
655                            orderByComparator);
656            }
657    
658            /**
659            * Returns all the d d m templates that the user has permission to view where groupId = &#63;.
660            *
661            * @param groupId the group ID
662            * @return the matching d d m templates that the user has permission to view
663            * @throws SystemException if a system exception occurred
664            */
665            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> filterFindByGroupId(
666                    long groupId)
667                    throws com.liferay.portal.kernel.exception.SystemException {
668                    return getPersistence().filterFindByGroupId(groupId);
669            }
670    
671            /**
672            * Returns a range of all the d d m templates that the user has permission to view where groupId = &#63;.
673            *
674            * <p>
675            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMTemplateModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
676            * </p>
677            *
678            * @param groupId the group ID
679            * @param start the lower bound of the range of d d m templates
680            * @param end the upper bound of the range of d d m templates (not inclusive)
681            * @return the range of matching d d m templates that the user has permission to view
682            * @throws SystemException if a system exception occurred
683            */
684            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> filterFindByGroupId(
685                    long groupId, int start, int end)
686                    throws com.liferay.portal.kernel.exception.SystemException {
687                    return getPersistence().filterFindByGroupId(groupId, start, end);
688            }
689    
690            /**
691            * Returns an ordered range of all the d d m templates that the user has permissions to view where groupId = &#63;.
692            *
693            * <p>
694            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMTemplateModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
695            * </p>
696            *
697            * @param groupId the group ID
698            * @param start the lower bound of the range of d d m templates
699            * @param end the upper bound of the range of d d m templates (not inclusive)
700            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
701            * @return the ordered range of matching d d m templates that the user has permission to view
702            * @throws SystemException if a system exception occurred
703            */
704            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> filterFindByGroupId(
705                    long groupId, int start, int end,
706                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
707                    throws com.liferay.portal.kernel.exception.SystemException {
708                    return getPersistence()
709                                       .filterFindByGroupId(groupId, start, end, orderByComparator);
710            }
711    
712            /**
713            * Returns the d d m templates before and after the current d d m template in the ordered set of d d m templates that the user has permission to view where groupId = &#63;.
714            *
715            * @param templateId the primary key of the current d d m template
716            * @param groupId the group ID
717            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
718            * @return the previous, current, and next d d m template
719            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a d d m template with the primary key could not be found
720            * @throws SystemException if a system exception occurred
721            */
722            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate[] filterFindByGroupId_PrevAndNext(
723                    long templateId, long groupId,
724                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
725                    throws com.liferay.portal.kernel.exception.SystemException,
726                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
727                    return getPersistence()
728                                       .filterFindByGroupId_PrevAndNext(templateId, groupId,
729                            orderByComparator);
730            }
731    
732            /**
733            * Removes all the d d m templates where groupId = &#63; from the database.
734            *
735            * @param groupId the group ID
736            * @throws SystemException if a system exception occurred
737            */
738            public static void removeByGroupId(long groupId)
739                    throws com.liferay.portal.kernel.exception.SystemException {
740                    getPersistence().removeByGroupId(groupId);
741            }
742    
743            /**
744            * Returns the number of d d m templates where groupId = &#63;.
745            *
746            * @param groupId the group ID
747            * @return the number of matching d d m templates
748            * @throws SystemException if a system exception occurred
749            */
750            public static int countByGroupId(long groupId)
751                    throws com.liferay.portal.kernel.exception.SystemException {
752                    return getPersistence().countByGroupId(groupId);
753            }
754    
755            /**
756            * Returns the number of d d m templates that the user has permission to view where groupId = &#63;.
757            *
758            * @param groupId the group ID
759            * @return the number of matching d d m templates that the user has permission to view
760            * @throws SystemException if a system exception occurred
761            */
762            public static int filterCountByGroupId(long groupId)
763                    throws com.liferay.portal.kernel.exception.SystemException {
764                    return getPersistence().filterCountByGroupId(groupId);
765            }
766    
767            /**
768            * Returns all the d d m templates where classPK = &#63;.
769            *
770            * @param classPK the class p k
771            * @return the matching d d m templates
772            * @throws SystemException if a system exception occurred
773            */
774            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByClassPK(
775                    long classPK)
776                    throws com.liferay.portal.kernel.exception.SystemException {
777                    return getPersistence().findByClassPK(classPK);
778            }
779    
780            /**
781            * Returns a range of all the d d m templates where classPK = &#63;.
782            *
783            * <p>
784            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMTemplateModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
785            * </p>
786            *
787            * @param classPK the class p k
788            * @param start the lower bound of the range of d d m templates
789            * @param end the upper bound of the range of d d m templates (not inclusive)
790            * @return the range of matching d d m templates
791            * @throws SystemException if a system exception occurred
792            */
793            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByClassPK(
794                    long classPK, int start, int end)
795                    throws com.liferay.portal.kernel.exception.SystemException {
796                    return getPersistence().findByClassPK(classPK, start, end);
797            }
798    
799            /**
800            * Returns an ordered range of all the d d m templates where classPK = &#63;.
801            *
802            * <p>
803            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMTemplateModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
804            * </p>
805            *
806            * @param classPK the class p k
807            * @param start the lower bound of the range of d d m templates
808            * @param end the upper bound of the range of d d m templates (not inclusive)
809            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
810            * @return the ordered range of matching d d m templates
811            * @throws SystemException if a system exception occurred
812            */
813            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByClassPK(
814                    long classPK, int start, int end,
815                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
816                    throws com.liferay.portal.kernel.exception.SystemException {
817                    return getPersistence()
818                                       .findByClassPK(classPK, start, end, orderByComparator);
819            }
820    
821            /**
822            * Returns the first d d m template in the ordered set where classPK = &#63;.
823            *
824            * @param classPK the class p k
825            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
826            * @return the first matching d d m template
827            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
828            * @throws SystemException if a system exception occurred
829            */
830            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByClassPK_First(
831                    long classPK,
832                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
833                    throws com.liferay.portal.kernel.exception.SystemException,
834                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
835                    return getPersistence().findByClassPK_First(classPK, orderByComparator);
836            }
837    
838            /**
839            * Returns the first d d m template in the ordered set where classPK = &#63;.
840            *
841            * @param classPK the class p k
842            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
843            * @return the first matching d d m template, or <code>null</code> if a matching d d m template could not be found
844            * @throws SystemException if a system exception occurred
845            */
846            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByClassPK_First(
847                    long classPK,
848                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
849                    throws com.liferay.portal.kernel.exception.SystemException {
850                    return getPersistence().fetchByClassPK_First(classPK, orderByComparator);
851            }
852    
853            /**
854            * Returns the last d d m template in the ordered set where classPK = &#63;.
855            *
856            * @param classPK the class p k
857            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
858            * @return the last matching d d m template
859            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
860            * @throws SystemException if a system exception occurred
861            */
862            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByClassPK_Last(
863                    long classPK,
864                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
865                    throws com.liferay.portal.kernel.exception.SystemException,
866                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
867                    return getPersistence().findByClassPK_Last(classPK, orderByComparator);
868            }
869    
870            /**
871            * Returns the last d d m template in the ordered set where classPK = &#63;.
872            *
873            * @param classPK the class p k
874            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
875            * @return the last matching d d m template, or <code>null</code> if a matching d d m template could not be found
876            * @throws SystemException if a system exception occurred
877            */
878            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByClassPK_Last(
879                    long classPK,
880                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
881                    throws com.liferay.portal.kernel.exception.SystemException {
882                    return getPersistence().fetchByClassPK_Last(classPK, orderByComparator);
883            }
884    
885            /**
886            * Returns the d d m templates before and after the current d d m template in the ordered set where classPK = &#63;.
887            *
888            * @param templateId the primary key of the current d d m template
889            * @param classPK the class p k
890            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
891            * @return the previous, current, and next d d m template
892            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a d d m template with the primary key could not be found
893            * @throws SystemException if a system exception occurred
894            */
895            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate[] findByClassPK_PrevAndNext(
896                    long templateId, long classPK,
897                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
898                    throws com.liferay.portal.kernel.exception.SystemException,
899                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
900                    return getPersistence()
901                                       .findByClassPK_PrevAndNext(templateId, classPK,
902                            orderByComparator);
903            }
904    
905            /**
906            * Removes all the d d m templates where classPK = &#63; from the database.
907            *
908            * @param classPK the class p k
909            * @throws SystemException if a system exception occurred
910            */
911            public static void removeByClassPK(long classPK)
912                    throws com.liferay.portal.kernel.exception.SystemException {
913                    getPersistence().removeByClassPK(classPK);
914            }
915    
916            /**
917            * Returns the number of d d m templates where classPK = &#63;.
918            *
919            * @param classPK the class p k
920            * @return the number of matching d d m templates
921            * @throws SystemException if a system exception occurred
922            */
923            public static int countByClassPK(long classPK)
924                    throws com.liferay.portal.kernel.exception.SystemException {
925                    return getPersistence().countByClassPK(classPK);
926            }
927    
928            /**
929            * Returns all the d d m templates where templateKey = &#63;.
930            *
931            * @param templateKey the template key
932            * @return the matching d d m templates
933            * @throws SystemException if a system exception occurred
934            */
935            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByTemplateKey(
936                    java.lang.String templateKey)
937                    throws com.liferay.portal.kernel.exception.SystemException {
938                    return getPersistence().findByTemplateKey(templateKey);
939            }
940    
941            /**
942            * Returns a range of all the d d m templates where templateKey = &#63;.
943            *
944            * <p>
945            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMTemplateModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
946            * </p>
947            *
948            * @param templateKey the template key
949            * @param start the lower bound of the range of d d m templates
950            * @param end the upper bound of the range of d d m templates (not inclusive)
951            * @return the range of matching d d m templates
952            * @throws SystemException if a system exception occurred
953            */
954            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByTemplateKey(
955                    java.lang.String templateKey, int start, int end)
956                    throws com.liferay.portal.kernel.exception.SystemException {
957                    return getPersistence().findByTemplateKey(templateKey, start, end);
958            }
959    
960            /**
961            * Returns an ordered range of all the d d m templates where templateKey = &#63;.
962            *
963            * <p>
964            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMTemplateModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
965            * </p>
966            *
967            * @param templateKey the template key
968            * @param start the lower bound of the range of d d m templates
969            * @param end the upper bound of the range of d d m templates (not inclusive)
970            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
971            * @return the ordered range of matching d d m templates
972            * @throws SystemException if a system exception occurred
973            */
974            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByTemplateKey(
975                    java.lang.String templateKey, int start, int end,
976                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
977                    throws com.liferay.portal.kernel.exception.SystemException {
978                    return getPersistence()
979                                       .findByTemplateKey(templateKey, start, end, orderByComparator);
980            }
981    
982            /**
983            * Returns the first d d m template in the ordered set where templateKey = &#63;.
984            *
985            * @param templateKey the template key
986            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
987            * @return the first matching d d m template
988            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
989            * @throws SystemException if a system exception occurred
990            */
991            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByTemplateKey_First(
992                    java.lang.String templateKey,
993                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
994                    throws com.liferay.portal.kernel.exception.SystemException,
995                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
996                    return getPersistence()
997                                       .findByTemplateKey_First(templateKey, orderByComparator);
998            }
999    
1000            /**
1001            * Returns the first d d m template in the ordered set where templateKey = &#63;.
1002            *
1003            * @param templateKey the template key
1004            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1005            * @return the first matching d d m template, or <code>null</code> if a matching d d m template could not be found
1006            * @throws SystemException if a system exception occurred
1007            */
1008            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByTemplateKey_First(
1009                    java.lang.String templateKey,
1010                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1011                    throws com.liferay.portal.kernel.exception.SystemException {
1012                    return getPersistence()
1013                                       .fetchByTemplateKey_First(templateKey, orderByComparator);
1014            }
1015    
1016            /**
1017            * Returns the last d d m template in the ordered set where templateKey = &#63;.
1018            *
1019            * @param templateKey the template key
1020            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1021            * @return the last matching d d m template
1022            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
1023            * @throws SystemException if a system exception occurred
1024            */
1025            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByTemplateKey_Last(
1026                    java.lang.String templateKey,
1027                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1028                    throws com.liferay.portal.kernel.exception.SystemException,
1029                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
1030                    return getPersistence()
1031                                       .findByTemplateKey_Last(templateKey, orderByComparator);
1032            }
1033    
1034            /**
1035            * Returns the last d d m template in the ordered set where templateKey = &#63;.
1036            *
1037            * @param templateKey the template key
1038            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1039            * @return the last matching d d m template, or <code>null</code> if a matching d d m template could not be found
1040            * @throws SystemException if a system exception occurred
1041            */
1042            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByTemplateKey_Last(
1043                    java.lang.String templateKey,
1044                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1045                    throws com.liferay.portal.kernel.exception.SystemException {
1046                    return getPersistence()
1047                                       .fetchByTemplateKey_Last(templateKey, orderByComparator);
1048            }
1049    
1050            /**
1051            * Returns the d d m templates before and after the current d d m template in the ordered set where templateKey = &#63;.
1052            *
1053            * @param templateId the primary key of the current d d m template
1054            * @param templateKey the template key
1055            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1056            * @return the previous, current, and next d d m template
1057            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a d d m template with the primary key could not be found
1058            * @throws SystemException if a system exception occurred
1059            */
1060            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate[] findByTemplateKey_PrevAndNext(
1061                    long templateId, java.lang.String templateKey,
1062                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1063                    throws com.liferay.portal.kernel.exception.SystemException,
1064                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
1065                    return getPersistence()
1066                                       .findByTemplateKey_PrevAndNext(templateId, templateKey,
1067                            orderByComparator);
1068            }
1069    
1070            /**
1071            * Removes all the d d m templates where templateKey = &#63; from the database.
1072            *
1073            * @param templateKey the template key
1074            * @throws SystemException if a system exception occurred
1075            */
1076            public static void removeByTemplateKey(java.lang.String templateKey)
1077                    throws com.liferay.portal.kernel.exception.SystemException {
1078                    getPersistence().removeByTemplateKey(templateKey);
1079            }
1080    
1081            /**
1082            * Returns the number of d d m templates where templateKey = &#63;.
1083            *
1084            * @param templateKey the template key
1085            * @return the number of matching d d m templates
1086            * @throws SystemException if a system exception occurred
1087            */
1088            public static int countByTemplateKey(java.lang.String templateKey)
1089                    throws com.liferay.portal.kernel.exception.SystemException {
1090                    return getPersistence().countByTemplateKey(templateKey);
1091            }
1092    
1093            /**
1094            * Returns all the d d m templates where type = &#63;.
1095            *
1096            * @param type the type
1097            * @return the matching d d m templates
1098            * @throws SystemException if a system exception occurred
1099            */
1100            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByType(
1101                    java.lang.String type)
1102                    throws com.liferay.portal.kernel.exception.SystemException {
1103                    return getPersistence().findByType(type);
1104            }
1105    
1106            /**
1107            * Returns a range of all the d d m templates where type = &#63;.
1108            *
1109            * <p>
1110            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMTemplateModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
1111            * </p>
1112            *
1113            * @param type the type
1114            * @param start the lower bound of the range of d d m templates
1115            * @param end the upper bound of the range of d d m templates (not inclusive)
1116            * @return the range of matching d d m templates
1117            * @throws SystemException if a system exception occurred
1118            */
1119            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByType(
1120                    java.lang.String type, int start, int end)
1121                    throws com.liferay.portal.kernel.exception.SystemException {
1122                    return getPersistence().findByType(type, start, end);
1123            }
1124    
1125            /**
1126            * Returns an ordered range of all the d d m templates where type = &#63;.
1127            *
1128            * <p>
1129            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMTemplateModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
1130            * </p>
1131            *
1132            * @param type the type
1133            * @param start the lower bound of the range of d d m templates
1134            * @param end the upper bound of the range of d d m templates (not inclusive)
1135            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1136            * @return the ordered range of matching d d m templates
1137            * @throws SystemException if a system exception occurred
1138            */
1139            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByType(
1140                    java.lang.String type, int start, int end,
1141                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1142                    throws com.liferay.portal.kernel.exception.SystemException {
1143                    return getPersistence().findByType(type, start, end, orderByComparator);
1144            }
1145    
1146            /**
1147            * Returns the first d d m template in the ordered set where type = &#63;.
1148            *
1149            * @param type the type
1150            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1151            * @return the first matching d d m template
1152            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
1153            * @throws SystemException if a system exception occurred
1154            */
1155            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByType_First(
1156                    java.lang.String type,
1157                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1158                    throws com.liferay.portal.kernel.exception.SystemException,
1159                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
1160                    return getPersistence().findByType_First(type, orderByComparator);
1161            }
1162    
1163            /**
1164            * Returns the first d d m template in the ordered set where type = &#63;.
1165            *
1166            * @param type the type
1167            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1168            * @return the first matching d d m template, or <code>null</code> if a matching d d m template could not be found
1169            * @throws SystemException if a system exception occurred
1170            */
1171            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByType_First(
1172                    java.lang.String type,
1173                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1174                    throws com.liferay.portal.kernel.exception.SystemException {
1175                    return getPersistence().fetchByType_First(type, orderByComparator);
1176            }
1177    
1178            /**
1179            * Returns the last d d m template in the ordered set where type = &#63;.
1180            *
1181            * @param type the type
1182            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1183            * @return the last matching d d m template
1184            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
1185            * @throws SystemException if a system exception occurred
1186            */
1187            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByType_Last(
1188                    java.lang.String type,
1189                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1190                    throws com.liferay.portal.kernel.exception.SystemException,
1191                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
1192                    return getPersistence().findByType_Last(type, orderByComparator);
1193            }
1194    
1195            /**
1196            * Returns the last d d m template in the ordered set where type = &#63;.
1197            *
1198            * @param type the type
1199            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1200            * @return the last matching d d m template, or <code>null</code> if a matching d d m template could not be found
1201            * @throws SystemException if a system exception occurred
1202            */
1203            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByType_Last(
1204                    java.lang.String type,
1205                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1206                    throws com.liferay.portal.kernel.exception.SystemException {
1207                    return getPersistence().fetchByType_Last(type, orderByComparator);
1208            }
1209    
1210            /**
1211            * Returns the d d m templates before and after the current d d m template in the ordered set where type = &#63;.
1212            *
1213            * @param templateId the primary key of the current d d m template
1214            * @param type the type
1215            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1216            * @return the previous, current, and next d d m template
1217            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a d d m template with the primary key could not be found
1218            * @throws SystemException if a system exception occurred
1219            */
1220            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate[] findByType_PrevAndNext(
1221                    long templateId, java.lang.String type,
1222                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1223                    throws com.liferay.portal.kernel.exception.SystemException,
1224                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
1225                    return getPersistence()
1226                                       .findByType_PrevAndNext(templateId, type, orderByComparator);
1227            }
1228    
1229            /**
1230            * Removes all the d d m templates where type = &#63; from the database.
1231            *
1232            * @param type the type
1233            * @throws SystemException if a system exception occurred
1234            */
1235            public static void removeByType(java.lang.String type)
1236                    throws com.liferay.portal.kernel.exception.SystemException {
1237                    getPersistence().removeByType(type);
1238            }
1239    
1240            /**
1241            * Returns the number of d d m templates where type = &#63;.
1242            *
1243            * @param type the type
1244            * @return the number of matching d d m templates
1245            * @throws SystemException if a system exception occurred
1246            */
1247            public static int countByType(java.lang.String type)
1248                    throws com.liferay.portal.kernel.exception.SystemException {
1249                    return getPersistence().countByType(type);
1250            }
1251    
1252            /**
1253            * Returns all the d d m templates where language = &#63;.
1254            *
1255            * @param language the language
1256            * @return the matching d d m templates
1257            * @throws SystemException if a system exception occurred
1258            */
1259            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByLanguage(
1260                    java.lang.String language)
1261                    throws com.liferay.portal.kernel.exception.SystemException {
1262                    return getPersistence().findByLanguage(language);
1263            }
1264    
1265            /**
1266            * Returns a range of all the d d m templates where language = &#63;.
1267            *
1268            * <p>
1269            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMTemplateModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
1270            * </p>
1271            *
1272            * @param language the language
1273            * @param start the lower bound of the range of d d m templates
1274            * @param end the upper bound of the range of d d m templates (not inclusive)
1275            * @return the range of matching d d m templates
1276            * @throws SystemException if a system exception occurred
1277            */
1278            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByLanguage(
1279                    java.lang.String language, int start, int end)
1280                    throws com.liferay.portal.kernel.exception.SystemException {
1281                    return getPersistence().findByLanguage(language, start, end);
1282            }
1283    
1284            /**
1285            * Returns an ordered range of all the d d m templates where language = &#63;.
1286            *
1287            * <p>
1288            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMTemplateModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
1289            * </p>
1290            *
1291            * @param language the language
1292            * @param start the lower bound of the range of d d m templates
1293            * @param end the upper bound of the range of d d m templates (not inclusive)
1294            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1295            * @return the ordered range of matching d d m templates
1296            * @throws SystemException if a system exception occurred
1297            */
1298            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByLanguage(
1299                    java.lang.String language, int start, int end,
1300                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1301                    throws com.liferay.portal.kernel.exception.SystemException {
1302                    return getPersistence()
1303                                       .findByLanguage(language, start, end, orderByComparator);
1304            }
1305    
1306            /**
1307            * Returns the first d d m template in the ordered set where language = &#63;.
1308            *
1309            * @param language the language
1310            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1311            * @return the first matching d d m template
1312            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
1313            * @throws SystemException if a system exception occurred
1314            */
1315            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByLanguage_First(
1316                    java.lang.String language,
1317                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1318                    throws com.liferay.portal.kernel.exception.SystemException,
1319                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
1320                    return getPersistence().findByLanguage_First(language, orderByComparator);
1321            }
1322    
1323            /**
1324            * Returns the first d d m template in the ordered set where language = &#63;.
1325            *
1326            * @param language the language
1327            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1328            * @return the first matching d d m template, or <code>null</code> if a matching d d m template could not be found
1329            * @throws SystemException if a system exception occurred
1330            */
1331            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByLanguage_First(
1332                    java.lang.String language,
1333                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1334                    throws com.liferay.portal.kernel.exception.SystemException {
1335                    return getPersistence()
1336                                       .fetchByLanguage_First(language, orderByComparator);
1337            }
1338    
1339            /**
1340            * Returns the last d d m template in the ordered set where language = &#63;.
1341            *
1342            * @param language the language
1343            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1344            * @return the last matching d d m template
1345            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
1346            * @throws SystemException if a system exception occurred
1347            */
1348            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByLanguage_Last(
1349                    java.lang.String language,
1350                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1351                    throws com.liferay.portal.kernel.exception.SystemException,
1352                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
1353                    return getPersistence().findByLanguage_Last(language, orderByComparator);
1354            }
1355    
1356            /**
1357            * Returns the last d d m template in the ordered set where language = &#63;.
1358            *
1359            * @param language the language
1360            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1361            * @return the last matching d d m template, or <code>null</code> if a matching d d m template could not be found
1362            * @throws SystemException if a system exception occurred
1363            */
1364            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByLanguage_Last(
1365                    java.lang.String language,
1366                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1367                    throws com.liferay.portal.kernel.exception.SystemException {
1368                    return getPersistence().fetchByLanguage_Last(language, orderByComparator);
1369            }
1370    
1371            /**
1372            * Returns the d d m templates before and after the current d d m template in the ordered set where language = &#63;.
1373            *
1374            * @param templateId the primary key of the current d d m template
1375            * @param language the language
1376            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1377            * @return the previous, current, and next d d m template
1378            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a d d m template with the primary key could not be found
1379            * @throws SystemException if a system exception occurred
1380            */
1381            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate[] findByLanguage_PrevAndNext(
1382                    long templateId, java.lang.String language,
1383                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1384                    throws com.liferay.portal.kernel.exception.SystemException,
1385                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
1386                    return getPersistence()
1387                                       .findByLanguage_PrevAndNext(templateId, language,
1388                            orderByComparator);
1389            }
1390    
1391            /**
1392            * Removes all the d d m templates where language = &#63; from the database.
1393            *
1394            * @param language the language
1395            * @throws SystemException if a system exception occurred
1396            */
1397            public static void removeByLanguage(java.lang.String language)
1398                    throws com.liferay.portal.kernel.exception.SystemException {
1399                    getPersistence().removeByLanguage(language);
1400            }
1401    
1402            /**
1403            * Returns the number of d d m templates where language = &#63;.
1404            *
1405            * @param language the language
1406            * @return the number of matching d d m templates
1407            * @throws SystemException if a system exception occurred
1408            */
1409            public static int countByLanguage(java.lang.String language)
1410                    throws com.liferay.portal.kernel.exception.SystemException {
1411                    return getPersistence().countByLanguage(language);
1412            }
1413    
1414            /**
1415            * Returns all the d d m templates where groupId = &#63; and classNameId = &#63;.
1416            *
1417            * @param groupId the group ID
1418            * @param classNameId the class name ID
1419            * @return the matching d d m templates
1420            * @throws SystemException if a system exception occurred
1421            */
1422            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByG_C(
1423                    long groupId, long classNameId)
1424                    throws com.liferay.portal.kernel.exception.SystemException {
1425                    return getPersistence().findByG_C(groupId, classNameId);
1426            }
1427    
1428            /**
1429            * Returns a range of all the d d m templates where groupId = &#63; and classNameId = &#63;.
1430            *
1431            * <p>
1432            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMTemplateModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
1433            * </p>
1434            *
1435            * @param groupId the group ID
1436            * @param classNameId the class name ID
1437            * @param start the lower bound of the range of d d m templates
1438            * @param end the upper bound of the range of d d m templates (not inclusive)
1439            * @return the range of matching d d m templates
1440            * @throws SystemException if a system exception occurred
1441            */
1442            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByG_C(
1443                    long groupId, long classNameId, int start, int end)
1444                    throws com.liferay.portal.kernel.exception.SystemException {
1445                    return getPersistence().findByG_C(groupId, classNameId, start, end);
1446            }
1447    
1448            /**
1449            * Returns an ordered range of all the d d m templates where groupId = &#63; and classNameId = &#63;.
1450            *
1451            * <p>
1452            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMTemplateModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
1453            * </p>
1454            *
1455            * @param groupId the group ID
1456            * @param classNameId the class name ID
1457            * @param start the lower bound of the range of d d m templates
1458            * @param end the upper bound of the range of d d m templates (not inclusive)
1459            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1460            * @return the ordered range of matching d d m templates
1461            * @throws SystemException if a system exception occurred
1462            */
1463            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByG_C(
1464                    long groupId, long classNameId, int start, int end,
1465                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1466                    throws com.liferay.portal.kernel.exception.SystemException {
1467                    return getPersistence()
1468                                       .findByG_C(groupId, classNameId, start, end,
1469                            orderByComparator);
1470            }
1471    
1472            /**
1473            * Returns the first d d m template in the ordered set where groupId = &#63; and classNameId = &#63;.
1474            *
1475            * @param groupId the group ID
1476            * @param classNameId the class name ID
1477            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1478            * @return the first matching d d m template
1479            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
1480            * @throws SystemException if a system exception occurred
1481            */
1482            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByG_C_First(
1483                    long groupId, long classNameId,
1484                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1485                    throws com.liferay.portal.kernel.exception.SystemException,
1486                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
1487                    return getPersistence()
1488                                       .findByG_C_First(groupId, classNameId, orderByComparator);
1489            }
1490    
1491            /**
1492            * Returns the first d d m template in the ordered set where groupId = &#63; and classNameId = &#63;.
1493            *
1494            * @param groupId the group ID
1495            * @param classNameId the class name ID
1496            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1497            * @return the first matching d d m template, or <code>null</code> if a matching d d m template could not be found
1498            * @throws SystemException if a system exception occurred
1499            */
1500            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByG_C_First(
1501                    long groupId, long classNameId,
1502                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1503                    throws com.liferay.portal.kernel.exception.SystemException {
1504                    return getPersistence()
1505                                       .fetchByG_C_First(groupId, classNameId, orderByComparator);
1506            }
1507    
1508            /**
1509            * Returns the last d d m template in the ordered set where groupId = &#63; and classNameId = &#63;.
1510            *
1511            * @param groupId the group ID
1512            * @param classNameId the class name ID
1513            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1514            * @return the last matching d d m template
1515            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
1516            * @throws SystemException if a system exception occurred
1517            */
1518            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByG_C_Last(
1519                    long groupId, long classNameId,
1520                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1521                    throws com.liferay.portal.kernel.exception.SystemException,
1522                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
1523                    return getPersistence()
1524                                       .findByG_C_Last(groupId, classNameId, orderByComparator);
1525            }
1526    
1527            /**
1528            * Returns the last d d m template in the ordered set where groupId = &#63; and classNameId = &#63;.
1529            *
1530            * @param groupId the group ID
1531            * @param classNameId the class name ID
1532            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1533            * @return the last matching d d m template, or <code>null</code> if a matching d d m template could not be found
1534            * @throws SystemException if a system exception occurred
1535            */
1536            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByG_C_Last(
1537                    long groupId, long classNameId,
1538                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1539                    throws com.liferay.portal.kernel.exception.SystemException {
1540                    return getPersistence()
1541                                       .fetchByG_C_Last(groupId, classNameId, orderByComparator);
1542            }
1543    
1544            /**
1545            * Returns the d d m templates before and after the current d d m template in the ordered set where groupId = &#63; and classNameId = &#63;.
1546            *
1547            * @param templateId the primary key of the current d d m template
1548            * @param groupId the group ID
1549            * @param classNameId the class name ID
1550            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1551            * @return the previous, current, and next d d m template
1552            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a d d m template with the primary key could not be found
1553            * @throws SystemException if a system exception occurred
1554            */
1555            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate[] findByG_C_PrevAndNext(
1556                    long templateId, long groupId, long classNameId,
1557                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1558                    throws com.liferay.portal.kernel.exception.SystemException,
1559                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
1560                    return getPersistence()
1561                                       .findByG_C_PrevAndNext(templateId, groupId, classNameId,
1562                            orderByComparator);
1563            }
1564    
1565            /**
1566            * Returns all the d d m templates that the user has permission to view where groupId = &#63; and classNameId = &#63;.
1567            *
1568            * @param groupId the group ID
1569            * @param classNameId the class name ID
1570            * @return the matching d d m templates that the user has permission to view
1571            * @throws SystemException if a system exception occurred
1572            */
1573            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> filterFindByG_C(
1574                    long groupId, long classNameId)
1575                    throws com.liferay.portal.kernel.exception.SystemException {
1576                    return getPersistence().filterFindByG_C(groupId, classNameId);
1577            }
1578    
1579            /**
1580            * Returns a range of all the d d m templates that the user has permission to view where groupId = &#63; and classNameId = &#63;.
1581            *
1582            * <p>
1583            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMTemplateModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
1584            * </p>
1585            *
1586            * @param groupId the group ID
1587            * @param classNameId the class name ID
1588            * @param start the lower bound of the range of d d m templates
1589            * @param end the upper bound of the range of d d m templates (not inclusive)
1590            * @return the range of matching d d m templates that the user has permission to view
1591            * @throws SystemException if a system exception occurred
1592            */
1593            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> filterFindByG_C(
1594                    long groupId, long classNameId, int start, int end)
1595                    throws com.liferay.portal.kernel.exception.SystemException {
1596                    return getPersistence().filterFindByG_C(groupId, classNameId, start, end);
1597            }
1598    
1599            /**
1600            * Returns an ordered range of all the d d m templates that the user has permissions to view where groupId = &#63; and classNameId = &#63;.
1601            *
1602            * <p>
1603            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMTemplateModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
1604            * </p>
1605            *
1606            * @param groupId the group ID
1607            * @param classNameId the class name ID
1608            * @param start the lower bound of the range of d d m templates
1609            * @param end the upper bound of the range of d d m templates (not inclusive)
1610            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1611            * @return the ordered range of matching d d m templates that the user has permission to view
1612            * @throws SystemException if a system exception occurred
1613            */
1614            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> filterFindByG_C(
1615                    long groupId, long classNameId, int start, int end,
1616                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1617                    throws com.liferay.portal.kernel.exception.SystemException {
1618                    return getPersistence()
1619                                       .filterFindByG_C(groupId, classNameId, start, end,
1620                            orderByComparator);
1621            }
1622    
1623            /**
1624            * Returns the d d m templates before and after the current d d m template in the ordered set of d d m templates that the user has permission to view where groupId = &#63; and classNameId = &#63;.
1625            *
1626            * @param templateId the primary key of the current d d m template
1627            * @param groupId the group ID
1628            * @param classNameId the class name ID
1629            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1630            * @return the previous, current, and next d d m template
1631            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a d d m template with the primary key could not be found
1632            * @throws SystemException if a system exception occurred
1633            */
1634            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate[] filterFindByG_C_PrevAndNext(
1635                    long templateId, long groupId, long classNameId,
1636                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1637                    throws com.liferay.portal.kernel.exception.SystemException,
1638                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
1639                    return getPersistence()
1640                                       .filterFindByG_C_PrevAndNext(templateId, groupId,
1641                            classNameId, orderByComparator);
1642            }
1643    
1644            /**
1645            * Removes all the d d m templates where groupId = &#63; and classNameId = &#63; from the database.
1646            *
1647            * @param groupId the group ID
1648            * @param classNameId the class name ID
1649            * @throws SystemException if a system exception occurred
1650            */
1651            public static void removeByG_C(long groupId, long classNameId)
1652                    throws com.liferay.portal.kernel.exception.SystemException {
1653                    getPersistence().removeByG_C(groupId, classNameId);
1654            }
1655    
1656            /**
1657            * Returns the number of d d m templates where groupId = &#63; and classNameId = &#63;.
1658            *
1659            * @param groupId the group ID
1660            * @param classNameId the class name ID
1661            * @return the number of matching d d m templates
1662            * @throws SystemException if a system exception occurred
1663            */
1664            public static int countByG_C(long groupId, long classNameId)
1665                    throws com.liferay.portal.kernel.exception.SystemException {
1666                    return getPersistence().countByG_C(groupId, classNameId);
1667            }
1668    
1669            /**
1670            * Returns the number of d d m templates that the user has permission to view where groupId = &#63; and classNameId = &#63;.
1671            *
1672            * @param groupId the group ID
1673            * @param classNameId the class name ID
1674            * @return the number of matching d d m templates that the user has permission to view
1675            * @throws SystemException if a system exception occurred
1676            */
1677            public static int filterCountByG_C(long groupId, long classNameId)
1678                    throws com.liferay.portal.kernel.exception.SystemException {
1679                    return getPersistence().filterCountByG_C(groupId, classNameId);
1680            }
1681    
1682            /**
1683            * Returns all the d d m templates where groupId = &#63; and classNameId = &#63; and classPK = &#63;.
1684            *
1685            * @param groupId the group ID
1686            * @param classNameId the class name ID
1687            * @param classPK the class p k
1688            * @return the matching d d m templates
1689            * @throws SystemException if a system exception occurred
1690            */
1691            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByG_C_C(
1692                    long groupId, long classNameId, long classPK)
1693                    throws com.liferay.portal.kernel.exception.SystemException {
1694                    return getPersistence().findByG_C_C(groupId, classNameId, classPK);
1695            }
1696    
1697            /**
1698            * Returns a range of all the d d m templates where groupId = &#63; and classNameId = &#63; and classPK = &#63;.
1699            *
1700            * <p>
1701            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMTemplateModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
1702            * </p>
1703            *
1704            * @param groupId the group ID
1705            * @param classNameId the class name ID
1706            * @param classPK the class p k
1707            * @param start the lower bound of the range of d d m templates
1708            * @param end the upper bound of the range of d d m templates (not inclusive)
1709            * @return the range of matching d d m templates
1710            * @throws SystemException if a system exception occurred
1711            */
1712            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByG_C_C(
1713                    long groupId, long classNameId, long classPK, int start, int end)
1714                    throws com.liferay.portal.kernel.exception.SystemException {
1715                    return getPersistence()
1716                                       .findByG_C_C(groupId, classNameId, classPK, start, end);
1717            }
1718    
1719            /**
1720            * Returns an ordered range of all the d d m templates where groupId = &#63; and classNameId = &#63; and classPK = &#63;.
1721            *
1722            * <p>
1723            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMTemplateModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
1724            * </p>
1725            *
1726            * @param groupId the group ID
1727            * @param classNameId the class name ID
1728            * @param classPK the class p k
1729            * @param start the lower bound of the range of d d m templates
1730            * @param end the upper bound of the range of d d m templates (not inclusive)
1731            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1732            * @return the ordered range of matching d d m templates
1733            * @throws SystemException if a system exception occurred
1734            */
1735            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByG_C_C(
1736                    long groupId, long classNameId, long classPK, int start, int end,
1737                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1738                    throws com.liferay.portal.kernel.exception.SystemException {
1739                    return getPersistence()
1740                                       .findByG_C_C(groupId, classNameId, classPK, start, end,
1741                            orderByComparator);
1742            }
1743    
1744            /**
1745            * Returns the first d d m template in the ordered set where groupId = &#63; and classNameId = &#63; and classPK = &#63;.
1746            *
1747            * @param groupId the group ID
1748            * @param classNameId the class name ID
1749            * @param classPK the class p k
1750            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1751            * @return the first matching d d m template
1752            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
1753            * @throws SystemException if a system exception occurred
1754            */
1755            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByG_C_C_First(
1756                    long groupId, long classNameId, long classPK,
1757                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1758                    throws com.liferay.portal.kernel.exception.SystemException,
1759                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
1760                    return getPersistence()
1761                                       .findByG_C_C_First(groupId, classNameId, classPK,
1762                            orderByComparator);
1763            }
1764    
1765            /**
1766            * Returns the first d d m template in the ordered set where groupId = &#63; and classNameId = &#63; and classPK = &#63;.
1767            *
1768            * @param groupId the group ID
1769            * @param classNameId the class name ID
1770            * @param classPK the class p k
1771            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1772            * @return the first matching d d m template, or <code>null</code> if a matching d d m template could not be found
1773            * @throws SystemException if a system exception occurred
1774            */
1775            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByG_C_C_First(
1776                    long groupId, long classNameId, long classPK,
1777                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1778                    throws com.liferay.portal.kernel.exception.SystemException {
1779                    return getPersistence()
1780                                       .fetchByG_C_C_First(groupId, classNameId, classPK,
1781                            orderByComparator);
1782            }
1783    
1784            /**
1785            * Returns the last d d m template in the ordered set where groupId = &#63; and classNameId = &#63; and classPK = &#63;.
1786            *
1787            * @param groupId the group ID
1788            * @param classNameId the class name ID
1789            * @param classPK the class p k
1790            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1791            * @return the last matching d d m template
1792            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
1793            * @throws SystemException if a system exception occurred
1794            */
1795            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByG_C_C_Last(
1796                    long groupId, long classNameId, long classPK,
1797                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1798                    throws com.liferay.portal.kernel.exception.SystemException,
1799                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
1800                    return getPersistence()
1801                                       .findByG_C_C_Last(groupId, classNameId, classPK,
1802                            orderByComparator);
1803            }
1804    
1805            /**
1806            * Returns the last d d m template in the ordered set where groupId = &#63; and classNameId = &#63; and classPK = &#63;.
1807            *
1808            * @param groupId the group ID
1809            * @param classNameId the class name ID
1810            * @param classPK the class p k
1811            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1812            * @return the last matching d d m template, or <code>null</code> if a matching d d m template could not be found
1813            * @throws SystemException if a system exception occurred
1814            */
1815            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByG_C_C_Last(
1816                    long groupId, long classNameId, long classPK,
1817                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1818                    throws com.liferay.portal.kernel.exception.SystemException {
1819                    return getPersistence()
1820                                       .fetchByG_C_C_Last(groupId, classNameId, classPK,
1821                            orderByComparator);
1822            }
1823    
1824            /**
1825            * Returns the d d m templates before and after the current d d m template in the ordered set where groupId = &#63; and classNameId = &#63; and classPK = &#63;.
1826            *
1827            * @param templateId the primary key of the current d d m template
1828            * @param groupId the group ID
1829            * @param classNameId the class name ID
1830            * @param classPK the class p k
1831            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1832            * @return the previous, current, and next d d m template
1833            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a d d m template with the primary key could not be found
1834            * @throws SystemException if a system exception occurred
1835            */
1836            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate[] findByG_C_C_PrevAndNext(
1837                    long templateId, long groupId, long classNameId, long classPK,
1838                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1839                    throws com.liferay.portal.kernel.exception.SystemException,
1840                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
1841                    return getPersistence()
1842                                       .findByG_C_C_PrevAndNext(templateId, groupId, classNameId,
1843                            classPK, orderByComparator);
1844            }
1845    
1846            /**
1847            * Returns all the d d m templates that the user has permission to view where groupId = &#63; and classNameId = &#63; and classPK = &#63;.
1848            *
1849            * @param groupId the group ID
1850            * @param classNameId the class name ID
1851            * @param classPK the class p k
1852            * @return the matching d d m templates that the user has permission to view
1853            * @throws SystemException if a system exception occurred
1854            */
1855            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> filterFindByG_C_C(
1856                    long groupId, long classNameId, long classPK)
1857                    throws com.liferay.portal.kernel.exception.SystemException {
1858                    return getPersistence().filterFindByG_C_C(groupId, classNameId, classPK);
1859            }
1860    
1861            /**
1862            * Returns a range of all the d d m templates that the user has permission to view where groupId = &#63; and classNameId = &#63; and classPK = &#63;.
1863            *
1864            * <p>
1865            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMTemplateModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
1866            * </p>
1867            *
1868            * @param groupId the group ID
1869            * @param classNameId the class name ID
1870            * @param classPK the class p k
1871            * @param start the lower bound of the range of d d m templates
1872            * @param end the upper bound of the range of d d m templates (not inclusive)
1873            * @return the range of matching d d m templates that the user has permission to view
1874            * @throws SystemException if a system exception occurred
1875            */
1876            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> filterFindByG_C_C(
1877                    long groupId, long classNameId, long classPK, int start, int end)
1878                    throws com.liferay.portal.kernel.exception.SystemException {
1879                    return getPersistence()
1880                                       .filterFindByG_C_C(groupId, classNameId, classPK, start, end);
1881            }
1882    
1883            /**
1884            * Returns an ordered range of all the d d m templates that the user has permissions to view where groupId = &#63; and classNameId = &#63; and classPK = &#63;.
1885            *
1886            * <p>
1887            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMTemplateModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
1888            * </p>
1889            *
1890            * @param groupId the group ID
1891            * @param classNameId the class name ID
1892            * @param classPK the class p k
1893            * @param start the lower bound of the range of d d m templates
1894            * @param end the upper bound of the range of d d m templates (not inclusive)
1895            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1896            * @return the ordered range of matching d d m templates that the user has permission to view
1897            * @throws SystemException if a system exception occurred
1898            */
1899            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> filterFindByG_C_C(
1900                    long groupId, long classNameId, long classPK, int start, int end,
1901                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1902                    throws com.liferay.portal.kernel.exception.SystemException {
1903                    return getPersistence()
1904                                       .filterFindByG_C_C(groupId, classNameId, classPK, start,
1905                            end, orderByComparator);
1906            }
1907    
1908            /**
1909            * Returns the d d m templates before and after the current d d m template in the ordered set of d d m templates that the user has permission to view where groupId = &#63; and classNameId = &#63; and classPK = &#63;.
1910            *
1911            * @param templateId the primary key of the current d d m template
1912            * @param groupId the group ID
1913            * @param classNameId the class name ID
1914            * @param classPK the class p k
1915            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1916            * @return the previous, current, and next d d m template
1917            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a d d m template with the primary key could not be found
1918            * @throws SystemException if a system exception occurred
1919            */
1920            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate[] filterFindByG_C_C_PrevAndNext(
1921                    long templateId, long groupId, long classNameId, long classPK,
1922                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1923                    throws com.liferay.portal.kernel.exception.SystemException,
1924                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
1925                    return getPersistence()
1926                                       .filterFindByG_C_C_PrevAndNext(templateId, groupId,
1927                            classNameId, classPK, orderByComparator);
1928            }
1929    
1930            /**
1931            * Removes all the d d m templates where groupId = &#63; and classNameId = &#63; and classPK = &#63; from the database.
1932            *
1933            * @param groupId the group ID
1934            * @param classNameId the class name ID
1935            * @param classPK the class p k
1936            * @throws SystemException if a system exception occurred
1937            */
1938            public static void removeByG_C_C(long groupId, long classNameId,
1939                    long classPK)
1940                    throws com.liferay.portal.kernel.exception.SystemException {
1941                    getPersistence().removeByG_C_C(groupId, classNameId, classPK);
1942            }
1943    
1944            /**
1945            * Returns the number of d d m templates where groupId = &#63; and classNameId = &#63; and classPK = &#63;.
1946            *
1947            * @param groupId the group ID
1948            * @param classNameId the class name ID
1949            * @param classPK the class p k
1950            * @return the number of matching d d m templates
1951            * @throws SystemException if a system exception occurred
1952            */
1953            public static int countByG_C_C(long groupId, long classNameId, long classPK)
1954                    throws com.liferay.portal.kernel.exception.SystemException {
1955                    return getPersistence().countByG_C_C(groupId, classNameId, classPK);
1956            }
1957    
1958            /**
1959            * Returns the number of d d m templates that the user has permission to view where groupId = &#63; and classNameId = &#63; and classPK = &#63;.
1960            *
1961            * @param groupId the group ID
1962            * @param classNameId the class name ID
1963            * @param classPK the class p k
1964            * @return the number of matching d d m templates that the user has permission to view
1965            * @throws SystemException if a system exception occurred
1966            */
1967            public static int filterCountByG_C_C(long groupId, long classNameId,
1968                    long classPK)
1969                    throws com.liferay.portal.kernel.exception.SystemException {
1970                    return getPersistence().filterCountByG_C_C(groupId, classNameId, classPK);
1971            }
1972    
1973            /**
1974            * Returns the d d m template where groupId = &#63; and classNameId = &#63; and templateKey = &#63; or throws a {@link com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException} if it could not be found.
1975            *
1976            * @param groupId the group ID
1977            * @param classNameId the class name ID
1978            * @param templateKey the template key
1979            * @return the matching d d m template
1980            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
1981            * @throws SystemException if a system exception occurred
1982            */
1983            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByG_C_T(
1984                    long groupId, long classNameId, java.lang.String templateKey)
1985                    throws com.liferay.portal.kernel.exception.SystemException,
1986                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
1987                    return getPersistence().findByG_C_T(groupId, classNameId, templateKey);
1988            }
1989    
1990            /**
1991            * Returns the d d m template where groupId = &#63; and classNameId = &#63; and templateKey = &#63; or returns <code>null</code> if it could not be found. Uses the finder cache.
1992            *
1993            * @param groupId the group ID
1994            * @param classNameId the class name ID
1995            * @param templateKey the template key
1996            * @return the matching d d m template, or <code>null</code> if a matching d d m template could not be found
1997            * @throws SystemException if a system exception occurred
1998            */
1999            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByG_C_T(
2000                    long groupId, long classNameId, java.lang.String templateKey)
2001                    throws com.liferay.portal.kernel.exception.SystemException {
2002                    return getPersistence().fetchByG_C_T(groupId, classNameId, templateKey);
2003            }
2004    
2005            /**
2006            * Returns the d d m template where groupId = &#63; and classNameId = &#63; and templateKey = &#63; or returns <code>null</code> if it could not be found, optionally using the finder cache.
2007            *
2008            * @param groupId the group ID
2009            * @param classNameId the class name ID
2010            * @param templateKey the template key
2011            * @param retrieveFromCache whether to use the finder cache
2012            * @return the matching d d m template, or <code>null</code> if a matching d d m template could not be found
2013            * @throws SystemException if a system exception occurred
2014            */
2015            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByG_C_T(
2016                    long groupId, long classNameId, java.lang.String templateKey,
2017                    boolean retrieveFromCache)
2018                    throws com.liferay.portal.kernel.exception.SystemException {
2019                    return getPersistence()
2020                                       .fetchByG_C_T(groupId, classNameId, templateKey,
2021                            retrieveFromCache);
2022            }
2023    
2024            /**
2025            * Removes the d d m template where groupId = &#63; and classNameId = &#63; and templateKey = &#63; from the database.
2026            *
2027            * @param groupId the group ID
2028            * @param classNameId the class name ID
2029            * @param templateKey the template key
2030            * @return the d d m template that was removed
2031            * @throws SystemException if a system exception occurred
2032            */
2033            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate removeByG_C_T(
2034                    long groupId, long classNameId, java.lang.String templateKey)
2035                    throws com.liferay.portal.kernel.exception.SystemException,
2036                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
2037                    return getPersistence().removeByG_C_T(groupId, classNameId, templateKey);
2038            }
2039    
2040            /**
2041            * Returns the number of d d m templates where groupId = &#63; and classNameId = &#63; and templateKey = &#63;.
2042            *
2043            * @param groupId the group ID
2044            * @param classNameId the class name ID
2045            * @param templateKey the template key
2046            * @return the number of matching d d m templates
2047            * @throws SystemException if a system exception occurred
2048            */
2049            public static int countByG_C_T(long groupId, long classNameId,
2050                    java.lang.String templateKey)
2051                    throws com.liferay.portal.kernel.exception.SystemException {
2052                    return getPersistence().countByG_C_T(groupId, classNameId, templateKey);
2053            }
2054    
2055            /**
2056            * Returns all the d d m templates where classNameId = &#63; and classPK = &#63; and type = &#63;.
2057            *
2058            * @param classNameId the class name ID
2059            * @param classPK the class p k
2060            * @param type the type
2061            * @return the matching d d m templates
2062            * @throws SystemException if a system exception occurred
2063            */
2064            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByC_C_T(
2065                    long classNameId, long classPK, java.lang.String type)
2066                    throws com.liferay.portal.kernel.exception.SystemException {
2067                    return getPersistence().findByC_C_T(classNameId, classPK, type);
2068            }
2069    
2070            /**
2071            * Returns a range of all the d d m templates where classNameId = &#63; and classPK = &#63; and type = &#63;.
2072            *
2073            * <p>
2074            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMTemplateModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
2075            * </p>
2076            *
2077            * @param classNameId the class name ID
2078            * @param classPK the class p k
2079            * @param type the type
2080            * @param start the lower bound of the range of d d m templates
2081            * @param end the upper bound of the range of d d m templates (not inclusive)
2082            * @return the range of matching d d m templates
2083            * @throws SystemException if a system exception occurred
2084            */
2085            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByC_C_T(
2086                    long classNameId, long classPK, java.lang.String type, int start,
2087                    int end) throws com.liferay.portal.kernel.exception.SystemException {
2088                    return getPersistence()
2089                                       .findByC_C_T(classNameId, classPK, type, start, end);
2090            }
2091    
2092            /**
2093            * Returns an ordered range of all the d d m templates where classNameId = &#63; and classPK = &#63; and type = &#63;.
2094            *
2095            * <p>
2096            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMTemplateModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
2097            * </p>
2098            *
2099            * @param classNameId the class name ID
2100            * @param classPK the class p k
2101            * @param type the type
2102            * @param start the lower bound of the range of d d m templates
2103            * @param end the upper bound of the range of d d m templates (not inclusive)
2104            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
2105            * @return the ordered range of matching d d m templates
2106            * @throws SystemException if a system exception occurred
2107            */
2108            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByC_C_T(
2109                    long classNameId, long classPK, java.lang.String type, int start,
2110                    int end,
2111                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2112                    throws com.liferay.portal.kernel.exception.SystemException {
2113                    return getPersistence()
2114                                       .findByC_C_T(classNameId, classPK, type, start, end,
2115                            orderByComparator);
2116            }
2117    
2118            /**
2119            * Returns the first d d m template in the ordered set where classNameId = &#63; and classPK = &#63; and type = &#63;.
2120            *
2121            * @param classNameId the class name ID
2122            * @param classPK the class p k
2123            * @param type the type
2124            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
2125            * @return the first matching d d m template
2126            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
2127            * @throws SystemException if a system exception occurred
2128            */
2129            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByC_C_T_First(
2130                    long classNameId, long classPK, java.lang.String type,
2131                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2132                    throws com.liferay.portal.kernel.exception.SystemException,
2133                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
2134                    return getPersistence()
2135                                       .findByC_C_T_First(classNameId, classPK, type,
2136                            orderByComparator);
2137            }
2138    
2139            /**
2140            * Returns the first d d m template in the ordered set where classNameId = &#63; and classPK = &#63; and type = &#63;.
2141            *
2142            * @param classNameId the class name ID
2143            * @param classPK the class p k
2144            * @param type the type
2145            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
2146            * @return the first matching d d m template, or <code>null</code> if a matching d d m template could not be found
2147            * @throws SystemException if a system exception occurred
2148            */
2149            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByC_C_T_First(
2150                    long classNameId, long classPK, java.lang.String type,
2151                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2152                    throws com.liferay.portal.kernel.exception.SystemException {
2153                    return getPersistence()
2154                                       .fetchByC_C_T_First(classNameId, classPK, type,
2155                            orderByComparator);
2156            }
2157    
2158            /**
2159            * Returns the last d d m template in the ordered set where classNameId = &#63; and classPK = &#63; and type = &#63;.
2160            *
2161            * @param classNameId the class name ID
2162            * @param classPK the class p k
2163            * @param type the type
2164            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
2165            * @return the last matching d d m template
2166            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
2167            * @throws SystemException if a system exception occurred
2168            */
2169            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByC_C_T_Last(
2170                    long classNameId, long classPK, java.lang.String type,
2171                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2172                    throws com.liferay.portal.kernel.exception.SystemException,
2173                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
2174                    return getPersistence()
2175                                       .findByC_C_T_Last(classNameId, classPK, type,
2176                            orderByComparator);
2177            }
2178    
2179            /**
2180            * Returns the last d d m template in the ordered set where classNameId = &#63; and classPK = &#63; and type = &#63;.
2181            *
2182            * @param classNameId the class name ID
2183            * @param classPK the class p k
2184            * @param type the type
2185            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
2186            * @return the last matching d d m template, or <code>null</code> if a matching d d m template could not be found
2187            * @throws SystemException if a system exception occurred
2188            */
2189            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByC_C_T_Last(
2190                    long classNameId, long classPK, java.lang.String type,
2191                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2192                    throws com.liferay.portal.kernel.exception.SystemException {
2193                    return getPersistence()
2194                                       .fetchByC_C_T_Last(classNameId, classPK, type,
2195                            orderByComparator);
2196            }
2197    
2198            /**
2199            * Returns the d d m templates before and after the current d d m template in the ordered set where classNameId = &#63; and classPK = &#63; and type = &#63;.
2200            *
2201            * @param templateId the primary key of the current d d m template
2202            * @param classNameId the class name ID
2203            * @param classPK the class p k
2204            * @param type the type
2205            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
2206            * @return the previous, current, and next d d m template
2207            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a d d m template with the primary key could not be found
2208            * @throws SystemException if a system exception occurred
2209            */
2210            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate[] findByC_C_T_PrevAndNext(
2211                    long templateId, long classNameId, long classPK, java.lang.String type,
2212                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2213                    throws com.liferay.portal.kernel.exception.SystemException,
2214                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
2215                    return getPersistence()
2216                                       .findByC_C_T_PrevAndNext(templateId, classNameId, classPK,
2217                            type, orderByComparator);
2218            }
2219    
2220            /**
2221            * Removes all the d d m templates where classNameId = &#63; and classPK = &#63; and type = &#63; from the database.
2222            *
2223            * @param classNameId the class name ID
2224            * @param classPK the class p k
2225            * @param type the type
2226            * @throws SystemException if a system exception occurred
2227            */
2228            public static void removeByC_C_T(long classNameId, long classPK,
2229                    java.lang.String type)
2230                    throws com.liferay.portal.kernel.exception.SystemException {
2231                    getPersistence().removeByC_C_T(classNameId, classPK, type);
2232            }
2233    
2234            /**
2235            * Returns the number of d d m templates where classNameId = &#63; and classPK = &#63; and type = &#63;.
2236            *
2237            * @param classNameId the class name ID
2238            * @param classPK the class p k
2239            * @param type the type
2240            * @return the number of matching d d m templates
2241            * @throws SystemException if a system exception occurred
2242            */
2243            public static int countByC_C_T(long classNameId, long classPK,
2244                    java.lang.String type)
2245                    throws com.liferay.portal.kernel.exception.SystemException {
2246                    return getPersistence().countByC_C_T(classNameId, classPK, type);
2247            }
2248    
2249            /**
2250            * Returns all the d d m templates where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63;.
2251            *
2252            * @param groupId the group ID
2253            * @param classNameId the class name ID
2254            * @param classPK the class p k
2255            * @param type the type
2256            * @return the matching d d m templates
2257            * @throws SystemException if a system exception occurred
2258            */
2259            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByG_C_C_T(
2260                    long groupId, long classNameId, long classPK, java.lang.String type)
2261                    throws com.liferay.portal.kernel.exception.SystemException {
2262                    return getPersistence()
2263                                       .findByG_C_C_T(groupId, classNameId, classPK, type);
2264            }
2265    
2266            /**
2267            * Returns a range of all the d d m templates where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63;.
2268            *
2269            * <p>
2270            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMTemplateModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
2271            * </p>
2272            *
2273            * @param groupId the group ID
2274            * @param classNameId the class name ID
2275            * @param classPK the class p k
2276            * @param type the type
2277            * @param start the lower bound of the range of d d m templates
2278            * @param end the upper bound of the range of d d m templates (not inclusive)
2279            * @return the range of matching d d m templates
2280            * @throws SystemException if a system exception occurred
2281            */
2282            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByG_C_C_T(
2283                    long groupId, long classNameId, long classPK, java.lang.String type,
2284                    int start, int end)
2285                    throws com.liferay.portal.kernel.exception.SystemException {
2286                    return getPersistence()
2287                                       .findByG_C_C_T(groupId, classNameId, classPK, type, start,
2288                            end);
2289            }
2290    
2291            /**
2292            * Returns an ordered range of all the d d m templates where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63;.
2293            *
2294            * <p>
2295            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMTemplateModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
2296            * </p>
2297            *
2298            * @param groupId the group ID
2299            * @param classNameId the class name ID
2300            * @param classPK the class p k
2301            * @param type the type
2302            * @param start the lower bound of the range of d d m templates
2303            * @param end the upper bound of the range of d d m templates (not inclusive)
2304            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
2305            * @return the ordered range of matching d d m templates
2306            * @throws SystemException if a system exception occurred
2307            */
2308            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByG_C_C_T(
2309                    long groupId, long classNameId, long classPK, java.lang.String type,
2310                    int start, int end,
2311                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2312                    throws com.liferay.portal.kernel.exception.SystemException {
2313                    return getPersistence()
2314                                       .findByG_C_C_T(groupId, classNameId, classPK, type, start,
2315                            end, orderByComparator);
2316            }
2317    
2318            /**
2319            * Returns the first d d m template in the ordered set where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63;.
2320            *
2321            * @param groupId the group ID
2322            * @param classNameId the class name ID
2323            * @param classPK the class p k
2324            * @param type the type
2325            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
2326            * @return the first matching d d m template
2327            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
2328            * @throws SystemException if a system exception occurred
2329            */
2330            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByG_C_C_T_First(
2331                    long groupId, long classNameId, long classPK, java.lang.String type,
2332                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2333                    throws com.liferay.portal.kernel.exception.SystemException,
2334                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
2335                    return getPersistence()
2336                                       .findByG_C_C_T_First(groupId, classNameId, classPK, type,
2337                            orderByComparator);
2338            }
2339    
2340            /**
2341            * Returns the first d d m template in the ordered set where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63;.
2342            *
2343            * @param groupId the group ID
2344            * @param classNameId the class name ID
2345            * @param classPK the class p k
2346            * @param type the type
2347            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
2348            * @return the first matching d d m template, or <code>null</code> if a matching d d m template could not be found
2349            * @throws SystemException if a system exception occurred
2350            */
2351            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByG_C_C_T_First(
2352                    long groupId, long classNameId, long classPK, java.lang.String type,
2353                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2354                    throws com.liferay.portal.kernel.exception.SystemException {
2355                    return getPersistence()
2356                                       .fetchByG_C_C_T_First(groupId, classNameId, classPK, type,
2357                            orderByComparator);
2358            }
2359    
2360            /**
2361            * Returns the last d d m template in the ordered set where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63;.
2362            *
2363            * @param groupId the group ID
2364            * @param classNameId the class name ID
2365            * @param classPK the class p k
2366            * @param type the type
2367            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
2368            * @return the last matching d d m template
2369            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
2370            * @throws SystemException if a system exception occurred
2371            */
2372            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByG_C_C_T_Last(
2373                    long groupId, long classNameId, long classPK, java.lang.String type,
2374                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2375                    throws com.liferay.portal.kernel.exception.SystemException,
2376                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
2377                    return getPersistence()
2378                                       .findByG_C_C_T_Last(groupId, classNameId, classPK, type,
2379                            orderByComparator);
2380            }
2381    
2382            /**
2383            * Returns the last d d m template in the ordered set where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63;.
2384            *
2385            * @param groupId the group ID
2386            * @param classNameId the class name ID
2387            * @param classPK the class p k
2388            * @param type the type
2389            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
2390            * @return the last matching d d m template, or <code>null</code> if a matching d d m template could not be found
2391            * @throws SystemException if a system exception occurred
2392            */
2393            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByG_C_C_T_Last(
2394                    long groupId, long classNameId, long classPK, java.lang.String type,
2395                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2396                    throws com.liferay.portal.kernel.exception.SystemException {
2397                    return getPersistence()
2398                                       .fetchByG_C_C_T_Last(groupId, classNameId, classPK, type,
2399                            orderByComparator);
2400            }
2401    
2402            /**
2403            * Returns the d d m templates before and after the current d d m template in the ordered set where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63;.
2404            *
2405            * @param templateId the primary key of the current d d m template
2406            * @param groupId the group ID
2407            * @param classNameId the class name ID
2408            * @param classPK the class p k
2409            * @param type the type
2410            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
2411            * @return the previous, current, and next d d m template
2412            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a d d m template with the primary key could not be found
2413            * @throws SystemException if a system exception occurred
2414            */
2415            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate[] findByG_C_C_T_PrevAndNext(
2416                    long templateId, long groupId, long classNameId, long classPK,
2417                    java.lang.String type,
2418                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2419                    throws com.liferay.portal.kernel.exception.SystemException,
2420                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
2421                    return getPersistence()
2422                                       .findByG_C_C_T_PrevAndNext(templateId, groupId, classNameId,
2423                            classPK, type, orderByComparator);
2424            }
2425    
2426            /**
2427            * Returns all the d d m templates that the user has permission to view where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63;.
2428            *
2429            * @param groupId the group ID
2430            * @param classNameId the class name ID
2431            * @param classPK the class p k
2432            * @param type the type
2433            * @return the matching d d m templates that the user has permission to view
2434            * @throws SystemException if a system exception occurred
2435            */
2436            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> filterFindByG_C_C_T(
2437                    long groupId, long classNameId, long classPK, java.lang.String type)
2438                    throws com.liferay.portal.kernel.exception.SystemException {
2439                    return getPersistence()
2440                                       .filterFindByG_C_C_T(groupId, classNameId, classPK, type);
2441            }
2442    
2443            /**
2444            * Returns a range of all the d d m templates that the user has permission to view where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63;.
2445            *
2446            * <p>
2447            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMTemplateModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
2448            * </p>
2449            *
2450            * @param groupId the group ID
2451            * @param classNameId the class name ID
2452            * @param classPK the class p k
2453            * @param type the type
2454            * @param start the lower bound of the range of d d m templates
2455            * @param end the upper bound of the range of d d m templates (not inclusive)
2456            * @return the range of matching d d m templates that the user has permission to view
2457            * @throws SystemException if a system exception occurred
2458            */
2459            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> filterFindByG_C_C_T(
2460                    long groupId, long classNameId, long classPK, java.lang.String type,
2461                    int start, int end)
2462                    throws com.liferay.portal.kernel.exception.SystemException {
2463                    return getPersistence()
2464                                       .filterFindByG_C_C_T(groupId, classNameId, classPK, type,
2465                            start, end);
2466            }
2467    
2468            /**
2469            * Returns an ordered range of all the d d m templates that the user has permissions to view where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63;.
2470            *
2471            * <p>
2472            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMTemplateModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
2473            * </p>
2474            *
2475            * @param groupId the group ID
2476            * @param classNameId the class name ID
2477            * @param classPK the class p k
2478            * @param type the type
2479            * @param start the lower bound of the range of d d m templates
2480            * @param end the upper bound of the range of d d m templates (not inclusive)
2481            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
2482            * @return the ordered range of matching d d m templates that the user has permission to view
2483            * @throws SystemException if a system exception occurred
2484            */
2485            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> filterFindByG_C_C_T(
2486                    long groupId, long classNameId, long classPK, java.lang.String type,
2487                    int start, int end,
2488                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2489                    throws com.liferay.portal.kernel.exception.SystemException {
2490                    return getPersistence()
2491                                       .filterFindByG_C_C_T(groupId, classNameId, classPK, type,
2492                            start, end, orderByComparator);
2493            }
2494    
2495            /**
2496            * Returns the d d m templates before and after the current d d m template in the ordered set of d d m templates that the user has permission to view where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63;.
2497            *
2498            * @param templateId the primary key of the current d d m template
2499            * @param groupId the group ID
2500            * @param classNameId the class name ID
2501            * @param classPK the class p k
2502            * @param type the type
2503            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
2504            * @return the previous, current, and next d d m template
2505            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a d d m template with the primary key could not be found
2506            * @throws SystemException if a system exception occurred
2507            */
2508            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate[] filterFindByG_C_C_T_PrevAndNext(
2509                    long templateId, long groupId, long classNameId, long classPK,
2510                    java.lang.String type,
2511                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2512                    throws com.liferay.portal.kernel.exception.SystemException,
2513                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
2514                    return getPersistence()
2515                                       .filterFindByG_C_C_T_PrevAndNext(templateId, groupId,
2516                            classNameId, classPK, type, orderByComparator);
2517            }
2518    
2519            /**
2520            * Removes all the d d m templates where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63; from the database.
2521            *
2522            * @param groupId the group ID
2523            * @param classNameId the class name ID
2524            * @param classPK the class p k
2525            * @param type the type
2526            * @throws SystemException if a system exception occurred
2527            */
2528            public static void removeByG_C_C_T(long groupId, long classNameId,
2529                    long classPK, java.lang.String type)
2530                    throws com.liferay.portal.kernel.exception.SystemException {
2531                    getPersistence().removeByG_C_C_T(groupId, classNameId, classPK, type);
2532            }
2533    
2534            /**
2535            * Returns the number of d d m templates where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63;.
2536            *
2537            * @param groupId the group ID
2538            * @param classNameId the class name ID
2539            * @param classPK the class p k
2540            * @param type the type
2541            * @return the number of matching d d m templates
2542            * @throws SystemException if a system exception occurred
2543            */
2544            public static int countByG_C_C_T(long groupId, long classNameId,
2545                    long classPK, java.lang.String type)
2546                    throws com.liferay.portal.kernel.exception.SystemException {
2547                    return getPersistence()
2548                                       .countByG_C_C_T(groupId, classNameId, classPK, type);
2549            }
2550    
2551            /**
2552            * Returns the number of d d m templates that the user has permission to view where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63;.
2553            *
2554            * @param groupId the group ID
2555            * @param classNameId the class name ID
2556            * @param classPK the class p k
2557            * @param type the type
2558            * @return the number of matching d d m templates that the user has permission to view
2559            * @throws SystemException if a system exception occurred
2560            */
2561            public static int filterCountByG_C_C_T(long groupId, long classNameId,
2562                    long classPK, java.lang.String type)
2563                    throws com.liferay.portal.kernel.exception.SystemException {
2564                    return getPersistence()
2565                                       .filterCountByG_C_C_T(groupId, classNameId, classPK, type);
2566            }
2567    
2568            /**
2569            * Returns all the d d m templates where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63; and mode = &#63;.
2570            *
2571            * @param groupId the group ID
2572            * @param classNameId the class name ID
2573            * @param classPK the class p k
2574            * @param type the type
2575            * @param mode the mode
2576            * @return the matching d d m templates
2577            * @throws SystemException if a system exception occurred
2578            */
2579            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByG_C_C_T_M(
2580                    long groupId, long classNameId, long classPK, java.lang.String type,
2581                    java.lang.String mode)
2582                    throws com.liferay.portal.kernel.exception.SystemException {
2583                    return getPersistence()
2584                                       .findByG_C_C_T_M(groupId, classNameId, classPK, type, mode);
2585            }
2586    
2587            /**
2588            * Returns a range of all the d d m templates where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63; and mode = &#63;.
2589            *
2590            * <p>
2591            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMTemplateModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
2592            * </p>
2593            *
2594            * @param groupId the group ID
2595            * @param classNameId the class name ID
2596            * @param classPK the class p k
2597            * @param type the type
2598            * @param mode the mode
2599            * @param start the lower bound of the range of d d m templates
2600            * @param end the upper bound of the range of d d m templates (not inclusive)
2601            * @return the range of matching d d m templates
2602            * @throws SystemException if a system exception occurred
2603            */
2604            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByG_C_C_T_M(
2605                    long groupId, long classNameId, long classPK, java.lang.String type,
2606                    java.lang.String mode, int start, int end)
2607                    throws com.liferay.portal.kernel.exception.SystemException {
2608                    return getPersistence()
2609                                       .findByG_C_C_T_M(groupId, classNameId, classPK, type, mode,
2610                            start, end);
2611            }
2612    
2613            /**
2614            * Returns an ordered range of all the d d m templates where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63; and mode = &#63;.
2615            *
2616            * <p>
2617            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMTemplateModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
2618            * </p>
2619            *
2620            * @param groupId the group ID
2621            * @param classNameId the class name ID
2622            * @param classPK the class p k
2623            * @param type the type
2624            * @param mode the mode
2625            * @param start the lower bound of the range of d d m templates
2626            * @param end the upper bound of the range of d d m templates (not inclusive)
2627            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
2628            * @return the ordered range of matching d d m templates
2629            * @throws SystemException if a system exception occurred
2630            */
2631            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByG_C_C_T_M(
2632                    long groupId, long classNameId, long classPK, java.lang.String type,
2633                    java.lang.String mode, int start, int end,
2634                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2635                    throws com.liferay.portal.kernel.exception.SystemException {
2636                    return getPersistence()
2637                                       .findByG_C_C_T_M(groupId, classNameId, classPK, type, mode,
2638                            start, end, orderByComparator);
2639            }
2640    
2641            /**
2642            * Returns the first d d m template in the ordered set where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63; and mode = &#63;.
2643            *
2644            * @param groupId the group ID
2645            * @param classNameId the class name ID
2646            * @param classPK the class p k
2647            * @param type the type
2648            * @param mode the mode
2649            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
2650            * @return the first matching d d m template
2651            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
2652            * @throws SystemException if a system exception occurred
2653            */
2654            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByG_C_C_T_M_First(
2655                    long groupId, long classNameId, long classPK, java.lang.String type,
2656                    java.lang.String mode,
2657                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2658                    throws com.liferay.portal.kernel.exception.SystemException,
2659                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
2660                    return getPersistence()
2661                                       .findByG_C_C_T_M_First(groupId, classNameId, classPK, type,
2662                            mode, orderByComparator);
2663            }
2664    
2665            /**
2666            * Returns the first d d m template in the ordered set where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63; and mode = &#63;.
2667            *
2668            * @param groupId the group ID
2669            * @param classNameId the class name ID
2670            * @param classPK the class p k
2671            * @param type the type
2672            * @param mode the mode
2673            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
2674            * @return the first matching d d m template, or <code>null</code> if a matching d d m template could not be found
2675            * @throws SystemException if a system exception occurred
2676            */
2677            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByG_C_C_T_M_First(
2678                    long groupId, long classNameId, long classPK, java.lang.String type,
2679                    java.lang.String mode,
2680                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2681                    throws com.liferay.portal.kernel.exception.SystemException {
2682                    return getPersistence()
2683                                       .fetchByG_C_C_T_M_First(groupId, classNameId, classPK, type,
2684                            mode, orderByComparator);
2685            }
2686    
2687            /**
2688            * Returns the last d d m template in the ordered set where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63; and mode = &#63;.
2689            *
2690            * @param groupId the group ID
2691            * @param classNameId the class name ID
2692            * @param classPK the class p k
2693            * @param type the type
2694            * @param mode the mode
2695            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
2696            * @return the last matching d d m template
2697            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
2698            * @throws SystemException if a system exception occurred
2699            */
2700            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByG_C_C_T_M_Last(
2701                    long groupId, long classNameId, long classPK, java.lang.String type,
2702                    java.lang.String mode,
2703                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2704                    throws com.liferay.portal.kernel.exception.SystemException,
2705                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
2706                    return getPersistence()
2707                                       .findByG_C_C_T_M_Last(groupId, classNameId, classPK, type,
2708                            mode, orderByComparator);
2709            }
2710    
2711            /**
2712            * Returns the last d d m template in the ordered set where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63; and mode = &#63;.
2713            *
2714            * @param groupId the group ID
2715            * @param classNameId the class name ID
2716            * @param classPK the class p k
2717            * @param type the type
2718            * @param mode the mode
2719            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
2720            * @return the last matching d d m template, or <code>null</code> if a matching d d m template could not be found
2721            * @throws SystemException if a system exception occurred
2722            */
2723            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByG_C_C_T_M_Last(
2724                    long groupId, long classNameId, long classPK, java.lang.String type,
2725                    java.lang.String mode,
2726                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2727                    throws com.liferay.portal.kernel.exception.SystemException {
2728                    return getPersistence()
2729                                       .fetchByG_C_C_T_M_Last(groupId, classNameId, classPK, type,
2730                            mode, orderByComparator);
2731            }
2732    
2733            /**
2734            * Returns the d d m templates before and after the current d d m template in the ordered set where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63; and mode = &#63;.
2735            *
2736            * @param templateId the primary key of the current d d m template
2737            * @param groupId the group ID
2738            * @param classNameId the class name ID
2739            * @param classPK the class p k
2740            * @param type the type
2741            * @param mode the mode
2742            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
2743            * @return the previous, current, and next d d m template
2744            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a d d m template with the primary key could not be found
2745            * @throws SystemException if a system exception occurred
2746            */
2747            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate[] findByG_C_C_T_M_PrevAndNext(
2748                    long templateId, long groupId, long classNameId, long classPK,
2749                    java.lang.String type, java.lang.String mode,
2750                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2751                    throws com.liferay.portal.kernel.exception.SystemException,
2752                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
2753                    return getPersistence()
2754                                       .findByG_C_C_T_M_PrevAndNext(templateId, groupId,
2755                            classNameId, classPK, type, mode, orderByComparator);
2756            }
2757    
2758            /**
2759            * Returns all the d d m templates that the user has permission to view where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63; and mode = &#63;.
2760            *
2761            * @param groupId the group ID
2762            * @param classNameId the class name ID
2763            * @param classPK the class p k
2764            * @param type the type
2765            * @param mode the mode
2766            * @return the matching d d m templates that the user has permission to view
2767            * @throws SystemException if a system exception occurred
2768            */
2769            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> filterFindByG_C_C_T_M(
2770                    long groupId, long classNameId, long classPK, java.lang.String type,
2771                    java.lang.String mode)
2772                    throws com.liferay.portal.kernel.exception.SystemException {
2773                    return getPersistence()
2774                                       .filterFindByG_C_C_T_M(groupId, classNameId, classPK, type,
2775                            mode);
2776            }
2777    
2778            /**
2779            * Returns a range of all the d d m templates that the user has permission to view where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63; and mode = &#63;.
2780            *
2781            * <p>
2782            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMTemplateModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
2783            * </p>
2784            *
2785            * @param groupId the group ID
2786            * @param classNameId the class name ID
2787            * @param classPK the class p k
2788            * @param type the type
2789            * @param mode the mode
2790            * @param start the lower bound of the range of d d m templates
2791            * @param end the upper bound of the range of d d m templates (not inclusive)
2792            * @return the range of matching d d m templates that the user has permission to view
2793            * @throws SystemException if a system exception occurred
2794            */
2795            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> filterFindByG_C_C_T_M(
2796                    long groupId, long classNameId, long classPK, java.lang.String type,
2797                    java.lang.String mode, int start, int end)
2798                    throws com.liferay.portal.kernel.exception.SystemException {
2799                    return getPersistence()
2800                                       .filterFindByG_C_C_T_M(groupId, classNameId, classPK, type,
2801                            mode, start, end);
2802            }
2803    
2804            /**
2805            * Returns an ordered range of all the d d m templates that the user has permissions to view where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63; and mode = &#63;.
2806            *
2807            * <p>
2808            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMTemplateModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
2809            * </p>
2810            *
2811            * @param groupId the group ID
2812            * @param classNameId the class name ID
2813            * @param classPK the class p k
2814            * @param type the type
2815            * @param mode the mode
2816            * @param start the lower bound of the range of d d m templates
2817            * @param end the upper bound of the range of d d m templates (not inclusive)
2818            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
2819            * @return the ordered range of matching d d m templates that the user has permission to view
2820            * @throws SystemException if a system exception occurred
2821            */
2822            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> filterFindByG_C_C_T_M(
2823                    long groupId, long classNameId, long classPK, java.lang.String type,
2824                    java.lang.String mode, int start, int end,
2825                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2826                    throws com.liferay.portal.kernel.exception.SystemException {
2827                    return getPersistence()
2828                                       .filterFindByG_C_C_T_M(groupId, classNameId, classPK, type,
2829                            mode, start, end, orderByComparator);
2830            }
2831    
2832            /**
2833            * Returns the d d m templates before and after the current d d m template in the ordered set of d d m templates that the user has permission to view where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63; and mode = &#63;.
2834            *
2835            * @param templateId the primary key of the current d d m template
2836            * @param groupId the group ID
2837            * @param classNameId the class name ID
2838            * @param classPK the class p k
2839            * @param type the type
2840            * @param mode the mode
2841            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
2842            * @return the previous, current, and next d d m template
2843            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a d d m template with the primary key could not be found
2844            * @throws SystemException if a system exception occurred
2845            */
2846            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate[] filterFindByG_C_C_T_M_PrevAndNext(
2847                    long templateId, long groupId, long classNameId, long classPK,
2848                    java.lang.String type, java.lang.String mode,
2849                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2850                    throws com.liferay.portal.kernel.exception.SystemException,
2851                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
2852                    return getPersistence()
2853                                       .filterFindByG_C_C_T_M_PrevAndNext(templateId, groupId,
2854                            classNameId, classPK, type, mode, orderByComparator);
2855            }
2856    
2857            /**
2858            * Removes all the d d m templates where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63; and mode = &#63; from the database.
2859            *
2860            * @param groupId the group ID
2861            * @param classNameId the class name ID
2862            * @param classPK the class p k
2863            * @param type the type
2864            * @param mode the mode
2865            * @throws SystemException if a system exception occurred
2866            */
2867            public static void removeByG_C_C_T_M(long groupId, long classNameId,
2868                    long classPK, java.lang.String type, java.lang.String mode)
2869                    throws com.liferay.portal.kernel.exception.SystemException {
2870                    getPersistence()
2871                            .removeByG_C_C_T_M(groupId, classNameId, classPK, type, mode);
2872            }
2873    
2874            /**
2875            * Returns the number of d d m templates where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63; and mode = &#63;.
2876            *
2877            * @param groupId the group ID
2878            * @param classNameId the class name ID
2879            * @param classPK the class p k
2880            * @param type the type
2881            * @param mode the mode
2882            * @return the number of matching d d m templates
2883            * @throws SystemException if a system exception occurred
2884            */
2885            public static int countByG_C_C_T_M(long groupId, long classNameId,
2886                    long classPK, java.lang.String type, java.lang.String mode)
2887                    throws com.liferay.portal.kernel.exception.SystemException {
2888                    return getPersistence()
2889                                       .countByG_C_C_T_M(groupId, classNameId, classPK, type, mode);
2890            }
2891    
2892            /**
2893            * Returns the number of d d m templates that the user has permission to view where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63; and mode = &#63;.
2894            *
2895            * @param groupId the group ID
2896            * @param classNameId the class name ID
2897            * @param classPK the class p k
2898            * @param type the type
2899            * @param mode the mode
2900            * @return the number of matching d d m templates that the user has permission to view
2901            * @throws SystemException if a system exception occurred
2902            */
2903            public static int filterCountByG_C_C_T_M(long groupId, long classNameId,
2904                    long classPK, java.lang.String type, java.lang.String mode)
2905                    throws com.liferay.portal.kernel.exception.SystemException {
2906                    return getPersistence()
2907                                       .filterCountByG_C_C_T_M(groupId, classNameId, classPK, type,
2908                            mode);
2909            }
2910    
2911            /**
2912            * Caches the d d m template in the entity cache if it is enabled.
2913            *
2914            * @param ddmTemplate the d d m template
2915            */
2916            public static void cacheResult(
2917                    com.liferay.portlet.dynamicdatamapping.model.DDMTemplate ddmTemplate) {
2918                    getPersistence().cacheResult(ddmTemplate);
2919            }
2920    
2921            /**
2922            * Caches the d d m templates in the entity cache if it is enabled.
2923            *
2924            * @param ddmTemplates the d d m templates
2925            */
2926            public static void cacheResult(
2927                    java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> ddmTemplates) {
2928                    getPersistence().cacheResult(ddmTemplates);
2929            }
2930    
2931            /**
2932            * Creates a new d d m template with the primary key. Does not add the d d m template to the database.
2933            *
2934            * @param templateId the primary key for the new d d m template
2935            * @return the new d d m template
2936            */
2937            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate create(
2938                    long templateId) {
2939                    return getPersistence().create(templateId);
2940            }
2941    
2942            /**
2943            * Removes the d d m template with the primary key from the database. Also notifies the appropriate model listeners.
2944            *
2945            * @param templateId the primary key of the d d m template
2946            * @return the d d m template that was removed
2947            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a d d m template with the primary key could not be found
2948            * @throws SystemException if a system exception occurred
2949            */
2950            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate remove(
2951                    long templateId)
2952                    throws com.liferay.portal.kernel.exception.SystemException,
2953                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
2954                    return getPersistence().remove(templateId);
2955            }
2956    
2957            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate updateImpl(
2958                    com.liferay.portlet.dynamicdatamapping.model.DDMTemplate ddmTemplate)
2959                    throws com.liferay.portal.kernel.exception.SystemException {
2960                    return getPersistence().updateImpl(ddmTemplate);
2961            }
2962    
2963            /**
2964            * Returns the d d m template with the primary key or throws a {@link com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException} if it could not be found.
2965            *
2966            * @param templateId the primary key of the d d m template
2967            * @return the d d m template
2968            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a d d m template with the primary key could not be found
2969            * @throws SystemException if a system exception occurred
2970            */
2971            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByPrimaryKey(
2972                    long templateId)
2973                    throws com.liferay.portal.kernel.exception.SystemException,
2974                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
2975                    return getPersistence().findByPrimaryKey(templateId);
2976            }
2977    
2978            /**
2979            * Returns the d d m template with the primary key or returns <code>null</code> if it could not be found.
2980            *
2981            * @param templateId the primary key of the d d m template
2982            * @return the d d m template, or <code>null</code> if a d d m template with the primary key could not be found
2983            * @throws SystemException if a system exception occurred
2984            */
2985            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByPrimaryKey(
2986                    long templateId)
2987                    throws com.liferay.portal.kernel.exception.SystemException {
2988                    return getPersistence().fetchByPrimaryKey(templateId);
2989            }
2990    
2991            /**
2992            * Returns all the d d m templates.
2993            *
2994            * @return the d d m templates
2995            * @throws SystemException if a system exception occurred
2996            */
2997            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findAll()
2998                    throws com.liferay.portal.kernel.exception.SystemException {
2999                    return getPersistence().findAll();
3000            }
3001    
3002            /**
3003            * Returns a range of all the d d m templates.
3004            *
3005            * <p>
3006            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMTemplateModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
3007            * </p>
3008            *
3009            * @param start the lower bound of the range of d d m templates
3010            * @param end the upper bound of the range of d d m templates (not inclusive)
3011            * @return the range of d d m templates
3012            * @throws SystemException if a system exception occurred
3013            */
3014            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findAll(
3015                    int start, int end)
3016                    throws com.liferay.portal.kernel.exception.SystemException {
3017                    return getPersistence().findAll(start, end);
3018            }
3019    
3020            /**
3021            * Returns an ordered range of all the d d m templates.
3022            *
3023            * <p>
3024            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMTemplateModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
3025            * </p>
3026            *
3027            * @param start the lower bound of the range of d d m templates
3028            * @param end the upper bound of the range of d d m templates (not inclusive)
3029            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
3030            * @return the ordered range of d d m templates
3031            * @throws SystemException if a system exception occurred
3032            */
3033            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findAll(
3034                    int start, int end,
3035                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
3036                    throws com.liferay.portal.kernel.exception.SystemException {
3037                    return getPersistence().findAll(start, end, orderByComparator);
3038            }
3039    
3040            /**
3041            * Removes all the d d m templates from the database.
3042            *
3043            * @throws SystemException if a system exception occurred
3044            */
3045            public static void removeAll()
3046                    throws com.liferay.portal.kernel.exception.SystemException {
3047                    getPersistence().removeAll();
3048            }
3049    
3050            /**
3051            * Returns the number of d d m templates.
3052            *
3053            * @return the number of d d m templates
3054            * @throws SystemException if a system exception occurred
3055            */
3056            public static int countAll()
3057                    throws com.liferay.portal.kernel.exception.SystemException {
3058                    return getPersistence().countAll();
3059            }
3060    
3061            public static DDMTemplatePersistence getPersistence() {
3062                    if (_persistence == null) {
3063                            _persistence = (DDMTemplatePersistence)PortalBeanLocatorUtil.locate(DDMTemplatePersistence.class.getName());
3064    
3065                            ReferenceRegistry.registerReference(DDMTemplateUtil.class,
3066                                    "_persistence");
3067                    }
3068    
3069                    return _persistence;
3070            }
3071    
3072            /**
3073             * @deprecated
3074             */
3075            public void setPersistence(DDMTemplatePersistence persistence) {
3076            }
3077    
3078            private static DDMTemplatePersistence _persistence;
3079    }