001    /**
002     * Copyright (c) 2000-2013 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 the d d m template where smallImageId = &#63; or throws a {@link com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException} if it could not be found.
1416            *
1417            * @param smallImageId the small image ID
1418            * @return the matching d d m template
1419            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
1420            * @throws SystemException if a system exception occurred
1421            */
1422            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findBySmallImageId(
1423                    long smallImageId)
1424                    throws com.liferay.portal.kernel.exception.SystemException,
1425                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
1426                    return getPersistence().findBySmallImageId(smallImageId);
1427            }
1428    
1429            /**
1430            * Returns the d d m template where smallImageId = &#63; or returns <code>null</code> if it could not be found. Uses the finder cache.
1431            *
1432            * @param smallImageId the small image ID
1433            * @return the matching d d m template, or <code>null</code> if a matching d d m template could not be found
1434            * @throws SystemException if a system exception occurred
1435            */
1436            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchBySmallImageId(
1437                    long smallImageId)
1438                    throws com.liferay.portal.kernel.exception.SystemException {
1439                    return getPersistence().fetchBySmallImageId(smallImageId);
1440            }
1441    
1442            /**
1443            * Returns the d d m template where smallImageId = &#63; or returns <code>null</code> if it could not be found, optionally using the finder cache.
1444            *
1445            * @param smallImageId the small image ID
1446            * @param retrieveFromCache whether to use the finder cache
1447            * @return the matching d d m template, or <code>null</code> if a matching d d m template could not be found
1448            * @throws SystemException if a system exception occurred
1449            */
1450            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchBySmallImageId(
1451                    long smallImageId, boolean retrieveFromCache)
1452                    throws com.liferay.portal.kernel.exception.SystemException {
1453                    return getPersistence()
1454                                       .fetchBySmallImageId(smallImageId, retrieveFromCache);
1455            }
1456    
1457            /**
1458            * Removes the d d m template where smallImageId = &#63; from the database.
1459            *
1460            * @param smallImageId the small image ID
1461            * @return the d d m template that was removed
1462            * @throws SystemException if a system exception occurred
1463            */
1464            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate removeBySmallImageId(
1465                    long smallImageId)
1466                    throws com.liferay.portal.kernel.exception.SystemException,
1467                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
1468                    return getPersistence().removeBySmallImageId(smallImageId);
1469            }
1470    
1471            /**
1472            * Returns the number of d d m templates where smallImageId = &#63;.
1473            *
1474            * @param smallImageId the small image ID
1475            * @return the number of matching d d m templates
1476            * @throws SystemException if a system exception occurred
1477            */
1478            public static int countBySmallImageId(long smallImageId)
1479                    throws com.liferay.portal.kernel.exception.SystemException {
1480                    return getPersistence().countBySmallImageId(smallImageId);
1481            }
1482    
1483            /**
1484            * Returns all the d d m templates where groupId = &#63; and classNameId = &#63;.
1485            *
1486            * @param groupId the group ID
1487            * @param classNameId the class name ID
1488            * @return the matching d d m templates
1489            * @throws SystemException if a system exception occurred
1490            */
1491            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByG_C(
1492                    long groupId, long classNameId)
1493                    throws com.liferay.portal.kernel.exception.SystemException {
1494                    return getPersistence().findByG_C(groupId, classNameId);
1495            }
1496    
1497            /**
1498            * Returns a range of all the d d m templates where groupId = &#63; and classNameId = &#63;.
1499            *
1500            * <p>
1501            * 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.
1502            * </p>
1503            *
1504            * @param groupId the group ID
1505            * @param classNameId the class name ID
1506            * @param start the lower bound of the range of d d m templates
1507            * @param end the upper bound of the range of d d m templates (not inclusive)
1508            * @return the range of matching d d m templates
1509            * @throws SystemException if a system exception occurred
1510            */
1511            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByG_C(
1512                    long groupId, long classNameId, int start, int end)
1513                    throws com.liferay.portal.kernel.exception.SystemException {
1514                    return getPersistence().findByG_C(groupId, classNameId, start, end);
1515            }
1516    
1517            /**
1518            * Returns an ordered range of all the d d m templates where groupId = &#63; and classNameId = &#63;.
1519            *
1520            * <p>
1521            * 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.
1522            * </p>
1523            *
1524            * @param groupId the group ID
1525            * @param classNameId the class name ID
1526            * @param start the lower bound of the range of d d m templates
1527            * @param end the upper bound of the range of d d m templates (not inclusive)
1528            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1529            * @return the ordered range of matching d d m templates
1530            * @throws SystemException if a system exception occurred
1531            */
1532            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByG_C(
1533                    long groupId, long classNameId, int start, int end,
1534                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1535                    throws com.liferay.portal.kernel.exception.SystemException {
1536                    return getPersistence()
1537                                       .findByG_C(groupId, classNameId, start, end,
1538                            orderByComparator);
1539            }
1540    
1541            /**
1542            * Returns the first d d m template in the ordered set where groupId = &#63; and classNameId = &#63;.
1543            *
1544            * @param groupId the group ID
1545            * @param classNameId the class name ID
1546            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1547            * @return the first matching d d m template
1548            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
1549            * @throws SystemException if a system exception occurred
1550            */
1551            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByG_C_First(
1552                    long groupId, long classNameId,
1553                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1554                    throws com.liferay.portal.kernel.exception.SystemException,
1555                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
1556                    return getPersistence()
1557                                       .findByG_C_First(groupId, classNameId, orderByComparator);
1558            }
1559    
1560            /**
1561            * Returns the first d d m template in the ordered set where groupId = &#63; and classNameId = &#63;.
1562            *
1563            * @param groupId the group ID
1564            * @param classNameId the class name ID
1565            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1566            * @return the first matching d d m template, or <code>null</code> if a matching d d m template could not be found
1567            * @throws SystemException if a system exception occurred
1568            */
1569            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByG_C_First(
1570                    long groupId, long classNameId,
1571                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1572                    throws com.liferay.portal.kernel.exception.SystemException {
1573                    return getPersistence()
1574                                       .fetchByG_C_First(groupId, classNameId, orderByComparator);
1575            }
1576    
1577            /**
1578            * Returns the last d d m template in the ordered set where groupId = &#63; and classNameId = &#63;.
1579            *
1580            * @param groupId the group ID
1581            * @param classNameId the class name ID
1582            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1583            * @return the last matching d d m template
1584            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
1585            * @throws SystemException if a system exception occurred
1586            */
1587            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByG_C_Last(
1588                    long groupId, long classNameId,
1589                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1590                    throws com.liferay.portal.kernel.exception.SystemException,
1591                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
1592                    return getPersistence()
1593                                       .findByG_C_Last(groupId, classNameId, orderByComparator);
1594            }
1595    
1596            /**
1597            * Returns the last d d m template in the ordered set where groupId = &#63; and classNameId = &#63;.
1598            *
1599            * @param groupId the group ID
1600            * @param classNameId the class name ID
1601            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1602            * @return the last matching d d m template, or <code>null</code> if a matching d d m template could not be found
1603            * @throws SystemException if a system exception occurred
1604            */
1605            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByG_C_Last(
1606                    long groupId, long classNameId,
1607                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1608                    throws com.liferay.portal.kernel.exception.SystemException {
1609                    return getPersistence()
1610                                       .fetchByG_C_Last(groupId, classNameId, orderByComparator);
1611            }
1612    
1613            /**
1614            * 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;.
1615            *
1616            * @param templateId the primary key of the current d d m template
1617            * @param groupId the group ID
1618            * @param classNameId the class name ID
1619            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1620            * @return the previous, current, and next d d m template
1621            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a d d m template with the primary key could not be found
1622            * @throws SystemException if a system exception occurred
1623            */
1624            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate[] findByG_C_PrevAndNext(
1625                    long templateId, long groupId, long classNameId,
1626                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1627                    throws com.liferay.portal.kernel.exception.SystemException,
1628                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
1629                    return getPersistence()
1630                                       .findByG_C_PrevAndNext(templateId, groupId, classNameId,
1631                            orderByComparator);
1632            }
1633    
1634            /**
1635            * Returns all the d d m templates that the user has permission to view where groupId = &#63; and classNameId = &#63;.
1636            *
1637            * @param groupId the group ID
1638            * @param classNameId the class name ID
1639            * @return the matching d d m templates that the user has permission to view
1640            * @throws SystemException if a system exception occurred
1641            */
1642            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> filterFindByG_C(
1643                    long groupId, long classNameId)
1644                    throws com.liferay.portal.kernel.exception.SystemException {
1645                    return getPersistence().filterFindByG_C(groupId, classNameId);
1646            }
1647    
1648            /**
1649            * Returns a range of all the d d m templates that the user has permission to view where groupId = &#63; and classNameId = &#63;.
1650            *
1651            * <p>
1652            * 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.
1653            * </p>
1654            *
1655            * @param groupId the group ID
1656            * @param classNameId the class name ID
1657            * @param start the lower bound of the range of d d m templates
1658            * @param end the upper bound of the range of d d m templates (not inclusive)
1659            * @return the range of matching d d m templates that the user has permission to view
1660            * @throws SystemException if a system exception occurred
1661            */
1662            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> filterFindByG_C(
1663                    long groupId, long classNameId, int start, int end)
1664                    throws com.liferay.portal.kernel.exception.SystemException {
1665                    return getPersistence().filterFindByG_C(groupId, classNameId, start, end);
1666            }
1667    
1668            /**
1669            * Returns an ordered range of all the d d m templates that the user has permissions to view where groupId = &#63; and classNameId = &#63;.
1670            *
1671            * <p>
1672            * 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.
1673            * </p>
1674            *
1675            * @param groupId the group ID
1676            * @param classNameId the class name ID
1677            * @param start the lower bound of the range of d d m templates
1678            * @param end the upper bound of the range of d d m templates (not inclusive)
1679            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1680            * @return the ordered range of matching d d m templates that the user has permission to view
1681            * @throws SystemException if a system exception occurred
1682            */
1683            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> filterFindByG_C(
1684                    long groupId, long classNameId, int start, int end,
1685                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1686                    throws com.liferay.portal.kernel.exception.SystemException {
1687                    return getPersistence()
1688                                       .filterFindByG_C(groupId, classNameId, start, end,
1689                            orderByComparator);
1690            }
1691    
1692            /**
1693            * 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;.
1694            *
1695            * @param templateId the primary key of the current d d m template
1696            * @param groupId the group ID
1697            * @param classNameId the class name ID
1698            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1699            * @return the previous, current, and next d d m template
1700            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a d d m template with the primary key could not be found
1701            * @throws SystemException if a system exception occurred
1702            */
1703            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate[] filterFindByG_C_PrevAndNext(
1704                    long templateId, long groupId, long classNameId,
1705                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1706                    throws com.liferay.portal.kernel.exception.SystemException,
1707                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
1708                    return getPersistence()
1709                                       .filterFindByG_C_PrevAndNext(templateId, groupId,
1710                            classNameId, orderByComparator);
1711            }
1712    
1713            /**
1714            * Removes all the d d m templates where groupId = &#63; and classNameId = &#63; from the database.
1715            *
1716            * @param groupId the group ID
1717            * @param classNameId the class name ID
1718            * @throws SystemException if a system exception occurred
1719            */
1720            public static void removeByG_C(long groupId, long classNameId)
1721                    throws com.liferay.portal.kernel.exception.SystemException {
1722                    getPersistence().removeByG_C(groupId, classNameId);
1723            }
1724    
1725            /**
1726            * Returns the number of d d m templates where groupId = &#63; and classNameId = &#63;.
1727            *
1728            * @param groupId the group ID
1729            * @param classNameId the class name ID
1730            * @return the number of matching d d m templates
1731            * @throws SystemException if a system exception occurred
1732            */
1733            public static int countByG_C(long groupId, long classNameId)
1734                    throws com.liferay.portal.kernel.exception.SystemException {
1735                    return getPersistence().countByG_C(groupId, classNameId);
1736            }
1737    
1738            /**
1739            * Returns the number of d d m templates that the user has permission to view where groupId = &#63; and classNameId = &#63;.
1740            *
1741            * @param groupId the group ID
1742            * @param classNameId the class name ID
1743            * @return the number of matching d d m templates that the user has permission to view
1744            * @throws SystemException if a system exception occurred
1745            */
1746            public static int filterCountByG_C(long groupId, long classNameId)
1747                    throws com.liferay.portal.kernel.exception.SystemException {
1748                    return getPersistence().filterCountByG_C(groupId, classNameId);
1749            }
1750    
1751            /**
1752            * Returns all the d d m templates where groupId = &#63; and classPK = &#63;.
1753            *
1754            * @param groupId the group ID
1755            * @param classPK the class p k
1756            * @return the matching d d m templates
1757            * @throws SystemException if a system exception occurred
1758            */
1759            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByG_CPK(
1760                    long groupId, long classPK)
1761                    throws com.liferay.portal.kernel.exception.SystemException {
1762                    return getPersistence().findByG_CPK(groupId, classPK);
1763            }
1764    
1765            /**
1766            * Returns a range of all the d d m templates where groupId = &#63; and classPK = &#63;.
1767            *
1768            * <p>
1769            * 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.
1770            * </p>
1771            *
1772            * @param groupId the group ID
1773            * @param classPK the class p k
1774            * @param start the lower bound of the range of d d m templates
1775            * @param end the upper bound of the range of d d m templates (not inclusive)
1776            * @return the range of matching d d m templates
1777            * @throws SystemException if a system exception occurred
1778            */
1779            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByG_CPK(
1780                    long groupId, long classPK, int start, int end)
1781                    throws com.liferay.portal.kernel.exception.SystemException {
1782                    return getPersistence().findByG_CPK(groupId, classPK, start, end);
1783            }
1784    
1785            /**
1786            * Returns an ordered range of all the d d m templates where groupId = &#63; and classPK = &#63;.
1787            *
1788            * <p>
1789            * 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.
1790            * </p>
1791            *
1792            * @param groupId the group ID
1793            * @param classPK the class p k
1794            * @param start the lower bound of the range of d d m templates
1795            * @param end the upper bound of the range of d d m templates (not inclusive)
1796            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1797            * @return the ordered range of matching d d m templates
1798            * @throws SystemException if a system exception occurred
1799            */
1800            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByG_CPK(
1801                    long groupId, long classPK, int start, int end,
1802                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1803                    throws com.liferay.portal.kernel.exception.SystemException {
1804                    return getPersistence()
1805                                       .findByG_CPK(groupId, classPK, start, end, orderByComparator);
1806            }
1807    
1808            /**
1809            * Returns the first d d m template in the ordered set where groupId = &#63; and classPK = &#63;.
1810            *
1811            * @param groupId the group ID
1812            * @param classPK the class p k
1813            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1814            * @return the first matching d d m template
1815            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
1816            * @throws SystemException if a system exception occurred
1817            */
1818            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByG_CPK_First(
1819                    long groupId, long classPK,
1820                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1821                    throws com.liferay.portal.kernel.exception.SystemException,
1822                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
1823                    return getPersistence()
1824                                       .findByG_CPK_First(groupId, classPK, orderByComparator);
1825            }
1826    
1827            /**
1828            * Returns the first d d m template in the ordered set where groupId = &#63; and classPK = &#63;.
1829            *
1830            * @param groupId the group ID
1831            * @param classPK the class p k
1832            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1833            * @return the first matching d d m template, or <code>null</code> if a matching d d m template could not be found
1834            * @throws SystemException if a system exception occurred
1835            */
1836            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByG_CPK_First(
1837                    long groupId, long classPK,
1838                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1839                    throws com.liferay.portal.kernel.exception.SystemException {
1840                    return getPersistence()
1841                                       .fetchByG_CPK_First(groupId, classPK, orderByComparator);
1842            }
1843    
1844            /**
1845            * Returns the last d d m template in the ordered set where groupId = &#63; and classPK = &#63;.
1846            *
1847            * @param groupId the group ID
1848            * @param classPK the class p k
1849            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1850            * @return the last matching d d m template
1851            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
1852            * @throws SystemException if a system exception occurred
1853            */
1854            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByG_CPK_Last(
1855                    long groupId, long classPK,
1856                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1857                    throws com.liferay.portal.kernel.exception.SystemException,
1858                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
1859                    return getPersistence()
1860                                       .findByG_CPK_Last(groupId, classPK, orderByComparator);
1861            }
1862    
1863            /**
1864            * Returns the last d d m template in the ordered set where groupId = &#63; and classPK = &#63;.
1865            *
1866            * @param groupId the group ID
1867            * @param classPK the class p k
1868            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1869            * @return the last matching d d m template, or <code>null</code> if a matching d d m template could not be found
1870            * @throws SystemException if a system exception occurred
1871            */
1872            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByG_CPK_Last(
1873                    long groupId, long classPK,
1874                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1875                    throws com.liferay.portal.kernel.exception.SystemException {
1876                    return getPersistence()
1877                                       .fetchByG_CPK_Last(groupId, classPK, orderByComparator);
1878            }
1879    
1880            /**
1881            * Returns the d d m templates before and after the current d d m template in the ordered set where groupId = &#63; and classPK = &#63;.
1882            *
1883            * @param templateId the primary key of the current d d m template
1884            * @param groupId the group ID
1885            * @param classPK the class p k
1886            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1887            * @return the previous, current, and next d d m template
1888            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a d d m template with the primary key could not be found
1889            * @throws SystemException if a system exception occurred
1890            */
1891            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate[] findByG_CPK_PrevAndNext(
1892                    long templateId, long groupId, long classPK,
1893                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1894                    throws com.liferay.portal.kernel.exception.SystemException,
1895                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
1896                    return getPersistence()
1897                                       .findByG_CPK_PrevAndNext(templateId, groupId, classPK,
1898                            orderByComparator);
1899            }
1900    
1901            /**
1902            * Returns all the d d m templates that the user has permission to view where groupId = &#63; and classPK = &#63;.
1903            *
1904            * @param groupId the group ID
1905            * @param classPK the class p k
1906            * @return the matching d d m templates that the user has permission to view
1907            * @throws SystemException if a system exception occurred
1908            */
1909            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> filterFindByG_CPK(
1910                    long groupId, long classPK)
1911                    throws com.liferay.portal.kernel.exception.SystemException {
1912                    return getPersistence().filterFindByG_CPK(groupId, classPK);
1913            }
1914    
1915            /**
1916            * Returns a range of all the d d m templates that the user has permission to view where groupId = &#63; and classPK = &#63;.
1917            *
1918            * <p>
1919            * 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.
1920            * </p>
1921            *
1922            * @param groupId the group ID
1923            * @param classPK the class p k
1924            * @param start the lower bound of the range of d d m templates
1925            * @param end the upper bound of the range of d d m templates (not inclusive)
1926            * @return the range of matching d d m templates that the user has permission to view
1927            * @throws SystemException if a system exception occurred
1928            */
1929            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> filterFindByG_CPK(
1930                    long groupId, long classPK, int start, int end)
1931                    throws com.liferay.portal.kernel.exception.SystemException {
1932                    return getPersistence().filterFindByG_CPK(groupId, classPK, start, end);
1933            }
1934    
1935            /**
1936            * Returns an ordered range of all the d d m templates that the user has permissions to view where groupId = &#63; and classPK = &#63;.
1937            *
1938            * <p>
1939            * 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.
1940            * </p>
1941            *
1942            * @param groupId the group ID
1943            * @param classPK the class p k
1944            * @param start the lower bound of the range of d d m templates
1945            * @param end the upper bound of the range of d d m templates (not inclusive)
1946            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1947            * @return the ordered range of matching d d m templates that the user has permission to view
1948            * @throws SystemException if a system exception occurred
1949            */
1950            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> filterFindByG_CPK(
1951                    long groupId, long classPK, int start, int end,
1952                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1953                    throws com.liferay.portal.kernel.exception.SystemException {
1954                    return getPersistence()
1955                                       .filterFindByG_CPK(groupId, classPK, start, end,
1956                            orderByComparator);
1957            }
1958    
1959            /**
1960            * 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 classPK = &#63;.
1961            *
1962            * @param templateId the primary key of the current d d m template
1963            * @param groupId the group ID
1964            * @param classPK the class p k
1965            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1966            * @return the previous, current, and next d d m template
1967            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a d d m template with the primary key could not be found
1968            * @throws SystemException if a system exception occurred
1969            */
1970            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate[] filterFindByG_CPK_PrevAndNext(
1971                    long templateId, long groupId, long classPK,
1972                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1973                    throws com.liferay.portal.kernel.exception.SystemException,
1974                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
1975                    return getPersistence()
1976                                       .filterFindByG_CPK_PrevAndNext(templateId, groupId, classPK,
1977                            orderByComparator);
1978            }
1979    
1980            /**
1981            * Returns all the d d m templates that the user has permission to view where groupId = any &#63; and classPK = &#63;.
1982            *
1983            * @param groupIds the group IDs
1984            * @param classPK the class p k
1985            * @return the matching d d m templates that the user has permission to view
1986            * @throws SystemException if a system exception occurred
1987            */
1988            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> filterFindByG_CPK(
1989                    long[] groupIds, long classPK)
1990                    throws com.liferay.portal.kernel.exception.SystemException {
1991                    return getPersistence().filterFindByG_CPK(groupIds, classPK);
1992            }
1993    
1994            /**
1995            * Returns a range of all the d d m templates that the user has permission to view where groupId = any &#63; and classPK = &#63;.
1996            *
1997            * <p>
1998            * 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.
1999            * </p>
2000            *
2001            * @param groupIds the group IDs
2002            * @param classPK the class p k
2003            * @param start the lower bound of the range of d d m templates
2004            * @param end the upper bound of the range of d d m templates (not inclusive)
2005            * @return the range of matching d d m templates that the user has permission to view
2006            * @throws SystemException if a system exception occurred
2007            */
2008            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> filterFindByG_CPK(
2009                    long[] groupIds, long classPK, int start, int end)
2010                    throws com.liferay.portal.kernel.exception.SystemException {
2011                    return getPersistence().filterFindByG_CPK(groupIds, classPK, start, end);
2012            }
2013    
2014            /**
2015            * Returns an ordered range of all the d d m templates that the user has permission to view where groupId = any &#63; and classPK = &#63;.
2016            *
2017            * <p>
2018            * 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.
2019            * </p>
2020            *
2021            * @param groupIds the group IDs
2022            * @param classPK the class p k
2023            * @param start the lower bound of the range of d d m templates
2024            * @param end the upper bound of the range of d d m templates (not inclusive)
2025            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
2026            * @return the ordered range of matching d d m templates that the user has permission to view
2027            * @throws SystemException if a system exception occurred
2028            */
2029            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> filterFindByG_CPK(
2030                    long[] groupIds, long classPK, int start, int end,
2031                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2032                    throws com.liferay.portal.kernel.exception.SystemException {
2033                    return getPersistence()
2034                                       .filterFindByG_CPK(groupIds, classPK, start, end,
2035                            orderByComparator);
2036            }
2037    
2038            /**
2039            * Returns all the d d m templates where groupId = any &#63; and classPK = &#63;.
2040            *
2041            * <p>
2042            * 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.
2043            * </p>
2044            *
2045            * @param groupIds the group IDs
2046            * @param classPK the class p k
2047            * @return the matching d d m templates
2048            * @throws SystemException if a system exception occurred
2049            */
2050            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByG_CPK(
2051                    long[] groupIds, long classPK)
2052                    throws com.liferay.portal.kernel.exception.SystemException {
2053                    return getPersistence().findByG_CPK(groupIds, classPK);
2054            }
2055    
2056            /**
2057            * Returns a range of all the d d m templates where groupId = any &#63; and classPK = &#63;.
2058            *
2059            * <p>
2060            * 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.
2061            * </p>
2062            *
2063            * @param groupIds the group IDs
2064            * @param classPK the class p k
2065            * @param start the lower bound of the range of d d m templates
2066            * @param end the upper bound of the range of d d m templates (not inclusive)
2067            * @return the range of matching d d m templates
2068            * @throws SystemException if a system exception occurred
2069            */
2070            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByG_CPK(
2071                    long[] groupIds, long classPK, int start, int end)
2072                    throws com.liferay.portal.kernel.exception.SystemException {
2073                    return getPersistence().findByG_CPK(groupIds, classPK, start, end);
2074            }
2075    
2076            /**
2077            * Returns an ordered range of all the d d m templates where groupId = any &#63; and classPK = &#63;.
2078            *
2079            * <p>
2080            * 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.
2081            * </p>
2082            *
2083            * @param groupIds the group IDs
2084            * @param classPK the class p k
2085            * @param start the lower bound of the range of d d m templates
2086            * @param end the upper bound of the range of d d m templates (not inclusive)
2087            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
2088            * @return the ordered range of matching d d m templates
2089            * @throws SystemException if a system exception occurred
2090            */
2091            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByG_CPK(
2092                    long[] groupIds, long classPK, int start, int end,
2093                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2094                    throws com.liferay.portal.kernel.exception.SystemException {
2095                    return getPersistence()
2096                                       .findByG_CPK(groupIds, classPK, start, end, orderByComparator);
2097            }
2098    
2099            /**
2100            * Removes all the d d m templates where groupId = &#63; and classPK = &#63; from the database.
2101            *
2102            * @param groupId the group ID
2103            * @param classPK the class p k
2104            * @throws SystemException if a system exception occurred
2105            */
2106            public static void removeByG_CPK(long groupId, long classPK)
2107                    throws com.liferay.portal.kernel.exception.SystemException {
2108                    getPersistence().removeByG_CPK(groupId, classPK);
2109            }
2110    
2111            /**
2112            * Returns the number of d d m templates where groupId = &#63; and classPK = &#63;.
2113            *
2114            * @param groupId the group ID
2115            * @param classPK the class p k
2116            * @return the number of matching d d m templates
2117            * @throws SystemException if a system exception occurred
2118            */
2119            public static int countByG_CPK(long groupId, long classPK)
2120                    throws com.liferay.portal.kernel.exception.SystemException {
2121                    return getPersistence().countByG_CPK(groupId, classPK);
2122            }
2123    
2124            /**
2125            * Returns the number of d d m templates where groupId = any &#63; and classPK = &#63;.
2126            *
2127            * @param groupIds the group IDs
2128            * @param classPK the class p k
2129            * @return the number of matching d d m templates
2130            * @throws SystemException if a system exception occurred
2131            */
2132            public static int countByG_CPK(long[] groupIds, long classPK)
2133                    throws com.liferay.portal.kernel.exception.SystemException {
2134                    return getPersistence().countByG_CPK(groupIds, classPK);
2135            }
2136    
2137            /**
2138            * Returns the number of d d m templates that the user has permission to view where groupId = &#63; and classPK = &#63;.
2139            *
2140            * @param groupId the group ID
2141            * @param classPK the class p k
2142            * @return the number of matching d d m templates that the user has permission to view
2143            * @throws SystemException if a system exception occurred
2144            */
2145            public static int filterCountByG_CPK(long groupId, long classPK)
2146                    throws com.liferay.portal.kernel.exception.SystemException {
2147                    return getPersistence().filterCountByG_CPK(groupId, classPK);
2148            }
2149    
2150            /**
2151            * Returns the number of d d m templates that the user has permission to view where groupId = any &#63; and classPK = &#63;.
2152            *
2153            * @param groupIds the group IDs
2154            * @param classPK the class p k
2155            * @return the number of matching d d m templates that the user has permission to view
2156            * @throws SystemException if a system exception occurred
2157            */
2158            public static int filterCountByG_CPK(long[] groupIds, long classPK)
2159                    throws com.liferay.portal.kernel.exception.SystemException {
2160                    return getPersistence().filterCountByG_CPK(groupIds, classPK);
2161            }
2162    
2163            /**
2164            * Returns all the d d m templates where groupId = &#63; and classNameId = &#63; and classPK = &#63;.
2165            *
2166            * @param groupId the group ID
2167            * @param classNameId the class name ID
2168            * @param classPK the class p k
2169            * @return the matching d d m templates
2170            * @throws SystemException if a system exception occurred
2171            */
2172            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByG_C_C(
2173                    long groupId, long classNameId, long classPK)
2174                    throws com.liferay.portal.kernel.exception.SystemException {
2175                    return getPersistence().findByG_C_C(groupId, classNameId, classPK);
2176            }
2177    
2178            /**
2179            * Returns a range of all the d d m templates where groupId = &#63; and classNameId = &#63; and classPK = &#63;.
2180            *
2181            * <p>
2182            * 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.
2183            * </p>
2184            *
2185            * @param groupId the group ID
2186            * @param classNameId the class name ID
2187            * @param classPK the class p k
2188            * @param start the lower bound of the range of d d m templates
2189            * @param end the upper bound of the range of d d m templates (not inclusive)
2190            * @return the range of matching d d m templates
2191            * @throws SystemException if a system exception occurred
2192            */
2193            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByG_C_C(
2194                    long groupId, long classNameId, long classPK, int start, int end)
2195                    throws com.liferay.portal.kernel.exception.SystemException {
2196                    return getPersistence()
2197                                       .findByG_C_C(groupId, classNameId, classPK, start, end);
2198            }
2199    
2200            /**
2201            * Returns an ordered range of all the d d m templates where groupId = &#63; and classNameId = &#63; and classPK = &#63;.
2202            *
2203            * <p>
2204            * 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.
2205            * </p>
2206            *
2207            * @param groupId the group ID
2208            * @param classNameId the class name ID
2209            * @param classPK the class p k
2210            * @param start the lower bound of the range of d d m templates
2211            * @param end the upper bound of the range of d d m templates (not inclusive)
2212            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
2213            * @return the ordered range of matching d d m templates
2214            * @throws SystemException if a system exception occurred
2215            */
2216            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByG_C_C(
2217                    long groupId, long classNameId, long classPK, int start, int end,
2218                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2219                    throws com.liferay.portal.kernel.exception.SystemException {
2220                    return getPersistence()
2221                                       .findByG_C_C(groupId, classNameId, classPK, start, end,
2222                            orderByComparator);
2223            }
2224    
2225            /**
2226            * Returns the first d d m template in the ordered set where groupId = &#63; and classNameId = &#63; and classPK = &#63;.
2227            *
2228            * @param groupId the group ID
2229            * @param classNameId the class name ID
2230            * @param classPK the class p k
2231            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
2232            * @return the first matching d d m template
2233            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
2234            * @throws SystemException if a system exception occurred
2235            */
2236            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByG_C_C_First(
2237                    long groupId, long classNameId, long classPK,
2238                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2239                    throws com.liferay.portal.kernel.exception.SystemException,
2240                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
2241                    return getPersistence()
2242                                       .findByG_C_C_First(groupId, classNameId, classPK,
2243                            orderByComparator);
2244            }
2245    
2246            /**
2247            * Returns the first d d m template in the ordered set where groupId = &#63; and classNameId = &#63; and classPK = &#63;.
2248            *
2249            * @param groupId the group ID
2250            * @param classNameId the class name ID
2251            * @param classPK the class p k
2252            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
2253            * @return the first matching d d m template, or <code>null</code> if a matching d d m template could not be found
2254            * @throws SystemException if a system exception occurred
2255            */
2256            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByG_C_C_First(
2257                    long groupId, long classNameId, long classPK,
2258                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2259                    throws com.liferay.portal.kernel.exception.SystemException {
2260                    return getPersistence()
2261                                       .fetchByG_C_C_First(groupId, classNameId, classPK,
2262                            orderByComparator);
2263            }
2264    
2265            /**
2266            * Returns the last d d m template in the ordered set where groupId = &#63; and classNameId = &#63; and classPK = &#63;.
2267            *
2268            * @param groupId the group ID
2269            * @param classNameId the class name ID
2270            * @param classPK the class p k
2271            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
2272            * @return the last matching d d m template
2273            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
2274            * @throws SystemException if a system exception occurred
2275            */
2276            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByG_C_C_Last(
2277                    long groupId, long classNameId, long classPK,
2278                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2279                    throws com.liferay.portal.kernel.exception.SystemException,
2280                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
2281                    return getPersistence()
2282                                       .findByG_C_C_Last(groupId, classNameId, classPK,
2283                            orderByComparator);
2284            }
2285    
2286            /**
2287            * Returns the last d d m template in the ordered set where groupId = &#63; and classNameId = &#63; and classPK = &#63;.
2288            *
2289            * @param groupId the group ID
2290            * @param classNameId the class name ID
2291            * @param classPK the class p k
2292            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
2293            * @return the last matching d d m template, or <code>null</code> if a matching d d m template could not be found
2294            * @throws SystemException if a system exception occurred
2295            */
2296            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByG_C_C_Last(
2297                    long groupId, long classNameId, long classPK,
2298                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2299                    throws com.liferay.portal.kernel.exception.SystemException {
2300                    return getPersistence()
2301                                       .fetchByG_C_C_Last(groupId, classNameId, classPK,
2302                            orderByComparator);
2303            }
2304    
2305            /**
2306            * 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;.
2307            *
2308            * @param templateId the primary key of the current d d m template
2309            * @param groupId the group ID
2310            * @param classNameId the class name ID
2311            * @param classPK the class p k
2312            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
2313            * @return the previous, current, and next d d m template
2314            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a d d m template with the primary key could not be found
2315            * @throws SystemException if a system exception occurred
2316            */
2317            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate[] findByG_C_C_PrevAndNext(
2318                    long templateId, long groupId, long classNameId, long classPK,
2319                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2320                    throws com.liferay.portal.kernel.exception.SystemException,
2321                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
2322                    return getPersistence()
2323                                       .findByG_C_C_PrevAndNext(templateId, groupId, classNameId,
2324                            classPK, orderByComparator);
2325            }
2326    
2327            /**
2328            * Returns all the d d m templates that the user has permission to view where groupId = &#63; and classNameId = &#63; and classPK = &#63;.
2329            *
2330            * @param groupId the group ID
2331            * @param classNameId the class name ID
2332            * @param classPK the class p k
2333            * @return the matching d d m templates that the user has permission to view
2334            * @throws SystemException if a system exception occurred
2335            */
2336            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> filterFindByG_C_C(
2337                    long groupId, long classNameId, long classPK)
2338                    throws com.liferay.portal.kernel.exception.SystemException {
2339                    return getPersistence().filterFindByG_C_C(groupId, classNameId, classPK);
2340            }
2341    
2342            /**
2343            * 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;.
2344            *
2345            * <p>
2346            * 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.
2347            * </p>
2348            *
2349            * @param groupId the group ID
2350            * @param classNameId the class name ID
2351            * @param classPK the class p k
2352            * @param start the lower bound of the range of d d m templates
2353            * @param end the upper bound of the range of d d m templates (not inclusive)
2354            * @return the range of matching d d m templates that the user has permission to view
2355            * @throws SystemException if a system exception occurred
2356            */
2357            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> filterFindByG_C_C(
2358                    long groupId, long classNameId, long classPK, int start, int end)
2359                    throws com.liferay.portal.kernel.exception.SystemException {
2360                    return getPersistence()
2361                                       .filterFindByG_C_C(groupId, classNameId, classPK, start, end);
2362            }
2363    
2364            /**
2365            * 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;.
2366            *
2367            * <p>
2368            * 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.
2369            * </p>
2370            *
2371            * @param groupId the group ID
2372            * @param classNameId the class name ID
2373            * @param classPK the class p k
2374            * @param start the lower bound of the range of d d m templates
2375            * @param end the upper bound of the range of d d m templates (not inclusive)
2376            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
2377            * @return the ordered range of matching d d m templates that the user has permission to view
2378            * @throws SystemException if a system exception occurred
2379            */
2380            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> filterFindByG_C_C(
2381                    long groupId, long classNameId, long classPK, int start, int end,
2382                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2383                    throws com.liferay.portal.kernel.exception.SystemException {
2384                    return getPersistence()
2385                                       .filterFindByG_C_C(groupId, classNameId, classPK, start,
2386                            end, orderByComparator);
2387            }
2388    
2389            /**
2390            * 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;.
2391            *
2392            * @param templateId the primary key of the current d d m template
2393            * @param groupId the group ID
2394            * @param classNameId the class name ID
2395            * @param classPK the class p k
2396            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
2397            * @return the previous, current, and next d d m template
2398            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a d d m template with the primary key could not be found
2399            * @throws SystemException if a system exception occurred
2400            */
2401            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate[] filterFindByG_C_C_PrevAndNext(
2402                    long templateId, long groupId, long classNameId, long classPK,
2403                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2404                    throws com.liferay.portal.kernel.exception.SystemException,
2405                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
2406                    return getPersistence()
2407                                       .filterFindByG_C_C_PrevAndNext(templateId, groupId,
2408                            classNameId, classPK, orderByComparator);
2409            }
2410    
2411            /**
2412            * Removes all the d d m templates where groupId = &#63; and classNameId = &#63; and classPK = &#63; from the database.
2413            *
2414            * @param groupId the group ID
2415            * @param classNameId the class name ID
2416            * @param classPK the class p k
2417            * @throws SystemException if a system exception occurred
2418            */
2419            public static void removeByG_C_C(long groupId, long classNameId,
2420                    long classPK)
2421                    throws com.liferay.portal.kernel.exception.SystemException {
2422                    getPersistence().removeByG_C_C(groupId, classNameId, classPK);
2423            }
2424    
2425            /**
2426            * Returns the number of d d m templates where groupId = &#63; and classNameId = &#63; and classPK = &#63;.
2427            *
2428            * @param groupId the group ID
2429            * @param classNameId the class name ID
2430            * @param classPK the class p k
2431            * @return the number of matching d d m templates
2432            * @throws SystemException if a system exception occurred
2433            */
2434            public static int countByG_C_C(long groupId, long classNameId, long classPK)
2435                    throws com.liferay.portal.kernel.exception.SystemException {
2436                    return getPersistence().countByG_C_C(groupId, classNameId, classPK);
2437            }
2438    
2439            /**
2440            * Returns the number of d d m templates that the user has permission to view where groupId = &#63; and classNameId = &#63; and classPK = &#63;.
2441            *
2442            * @param groupId the group ID
2443            * @param classNameId the class name ID
2444            * @param classPK the class p k
2445            * @return the number of matching d d m templates that the user has permission to view
2446            * @throws SystemException if a system exception occurred
2447            */
2448            public static int filterCountByG_C_C(long groupId, long classNameId,
2449                    long classPK)
2450                    throws com.liferay.portal.kernel.exception.SystemException {
2451                    return getPersistence().filterCountByG_C_C(groupId, classNameId, classPK);
2452            }
2453    
2454            /**
2455            * 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.
2456            *
2457            * @param groupId the group ID
2458            * @param classNameId the class name ID
2459            * @param templateKey the template key
2460            * @return the matching d d m template
2461            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
2462            * @throws SystemException if a system exception occurred
2463            */
2464            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByG_C_T(
2465                    long groupId, long classNameId, java.lang.String templateKey)
2466                    throws com.liferay.portal.kernel.exception.SystemException,
2467                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
2468                    return getPersistence().findByG_C_T(groupId, classNameId, templateKey);
2469            }
2470    
2471            /**
2472            * 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.
2473            *
2474            * @param groupId the group ID
2475            * @param classNameId the class name ID
2476            * @param templateKey the template key
2477            * @return the matching d d m template, or <code>null</code> if a matching d d m template could not be found
2478            * @throws SystemException if a system exception occurred
2479            */
2480            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByG_C_T(
2481                    long groupId, long classNameId, java.lang.String templateKey)
2482                    throws com.liferay.portal.kernel.exception.SystemException {
2483                    return getPersistence().fetchByG_C_T(groupId, classNameId, templateKey);
2484            }
2485    
2486            /**
2487            * 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.
2488            *
2489            * @param groupId the group ID
2490            * @param classNameId the class name ID
2491            * @param templateKey the template key
2492            * @param retrieveFromCache whether to use the finder cache
2493            * @return the matching d d m template, or <code>null</code> if a matching d d m template could not be found
2494            * @throws SystemException if a system exception occurred
2495            */
2496            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByG_C_T(
2497                    long groupId, long classNameId, java.lang.String templateKey,
2498                    boolean retrieveFromCache)
2499                    throws com.liferay.portal.kernel.exception.SystemException {
2500                    return getPersistence()
2501                                       .fetchByG_C_T(groupId, classNameId, templateKey,
2502                            retrieveFromCache);
2503            }
2504    
2505            /**
2506            * Removes the d d m template where groupId = &#63; and classNameId = &#63; and templateKey = &#63; from the database.
2507            *
2508            * @param groupId the group ID
2509            * @param classNameId the class name ID
2510            * @param templateKey the template key
2511            * @return the d d m template that was removed
2512            * @throws SystemException if a system exception occurred
2513            */
2514            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate removeByG_C_T(
2515                    long groupId, long classNameId, java.lang.String templateKey)
2516                    throws com.liferay.portal.kernel.exception.SystemException,
2517                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
2518                    return getPersistence().removeByG_C_T(groupId, classNameId, templateKey);
2519            }
2520    
2521            /**
2522            * Returns the number of d d m templates where groupId = &#63; and classNameId = &#63; and templateKey = &#63;.
2523            *
2524            * @param groupId the group ID
2525            * @param classNameId the class name ID
2526            * @param templateKey the template key
2527            * @return the number of matching d d m templates
2528            * @throws SystemException if a system exception occurred
2529            */
2530            public static int countByG_C_T(long groupId, long classNameId,
2531                    java.lang.String templateKey)
2532                    throws com.liferay.portal.kernel.exception.SystemException {
2533                    return getPersistence().countByG_C_T(groupId, classNameId, templateKey);
2534            }
2535    
2536            /**
2537            * Returns all the d d m templates where classNameId = &#63; and classPK = &#63; and type = &#63;.
2538            *
2539            * @param classNameId the class name ID
2540            * @param classPK the class p k
2541            * @param type the type
2542            * @return the matching d d m templates
2543            * @throws SystemException if a system exception occurred
2544            */
2545            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByC_C_T(
2546                    long classNameId, long classPK, java.lang.String type)
2547                    throws com.liferay.portal.kernel.exception.SystemException {
2548                    return getPersistence().findByC_C_T(classNameId, classPK, type);
2549            }
2550    
2551            /**
2552            * Returns a range of all the d d m templates where classNameId = &#63; and classPK = &#63; and type = &#63;.
2553            *
2554            * <p>
2555            * 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.
2556            * </p>
2557            *
2558            * @param classNameId the class name ID
2559            * @param classPK the class p k
2560            * @param type the type
2561            * @param start the lower bound of the range of d d m templates
2562            * @param end the upper bound of the range of d d m templates (not inclusive)
2563            * @return the range of matching d d m templates
2564            * @throws SystemException if a system exception occurred
2565            */
2566            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByC_C_T(
2567                    long classNameId, long classPK, java.lang.String type, int start,
2568                    int end) throws com.liferay.portal.kernel.exception.SystemException {
2569                    return getPersistence()
2570                                       .findByC_C_T(classNameId, classPK, type, start, end);
2571            }
2572    
2573            /**
2574            * Returns an ordered range of all the d d m templates where classNameId = &#63; and classPK = &#63; and type = &#63;.
2575            *
2576            * <p>
2577            * 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.
2578            * </p>
2579            *
2580            * @param classNameId the class name ID
2581            * @param classPK the class p k
2582            * @param type the type
2583            * @param start the lower bound of the range of d d m templates
2584            * @param end the upper bound of the range of d d m templates (not inclusive)
2585            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
2586            * @return the ordered range of matching d d m templates
2587            * @throws SystemException if a system exception occurred
2588            */
2589            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByC_C_T(
2590                    long classNameId, long classPK, java.lang.String type, int start,
2591                    int end,
2592                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2593                    throws com.liferay.portal.kernel.exception.SystemException {
2594                    return getPersistence()
2595                                       .findByC_C_T(classNameId, classPK, type, start, end,
2596                            orderByComparator);
2597            }
2598    
2599            /**
2600            * Returns the first d d m template in the ordered set where classNameId = &#63; and classPK = &#63; and type = &#63;.
2601            *
2602            * @param classNameId the class name ID
2603            * @param classPK the class p k
2604            * @param type the type
2605            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
2606            * @return the first matching d d m template
2607            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
2608            * @throws SystemException if a system exception occurred
2609            */
2610            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByC_C_T_First(
2611                    long classNameId, long classPK, java.lang.String type,
2612                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2613                    throws com.liferay.portal.kernel.exception.SystemException,
2614                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
2615                    return getPersistence()
2616                                       .findByC_C_T_First(classNameId, classPK, type,
2617                            orderByComparator);
2618            }
2619    
2620            /**
2621            * Returns the first d d m template in the ordered set where classNameId = &#63; and classPK = &#63; and type = &#63;.
2622            *
2623            * @param classNameId the class name ID
2624            * @param classPK the class p k
2625            * @param type the type
2626            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
2627            * @return the first matching d d m template, or <code>null</code> if a matching d d m template could not be found
2628            * @throws SystemException if a system exception occurred
2629            */
2630            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByC_C_T_First(
2631                    long classNameId, long classPK, java.lang.String type,
2632                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2633                    throws com.liferay.portal.kernel.exception.SystemException {
2634                    return getPersistence()
2635                                       .fetchByC_C_T_First(classNameId, classPK, type,
2636                            orderByComparator);
2637            }
2638    
2639            /**
2640            * Returns the last d d m template in the ordered set where classNameId = &#63; and classPK = &#63; and type = &#63;.
2641            *
2642            * @param classNameId the class name ID
2643            * @param classPK the class p k
2644            * @param type the type
2645            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
2646            * @return the last matching d d m template
2647            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
2648            * @throws SystemException if a system exception occurred
2649            */
2650            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByC_C_T_Last(
2651                    long classNameId, long classPK, java.lang.String type,
2652                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2653                    throws com.liferay.portal.kernel.exception.SystemException,
2654                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
2655                    return getPersistence()
2656                                       .findByC_C_T_Last(classNameId, classPK, type,
2657                            orderByComparator);
2658            }
2659    
2660            /**
2661            * Returns the last d d m template in the ordered set where classNameId = &#63; and classPK = &#63; and type = &#63;.
2662            *
2663            * @param classNameId the class name ID
2664            * @param classPK the class p k
2665            * @param type the type
2666            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
2667            * @return the last matching d d m template, or <code>null</code> if a matching d d m template could not be found
2668            * @throws SystemException if a system exception occurred
2669            */
2670            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByC_C_T_Last(
2671                    long classNameId, long classPK, java.lang.String type,
2672                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2673                    throws com.liferay.portal.kernel.exception.SystemException {
2674                    return getPersistence()
2675                                       .fetchByC_C_T_Last(classNameId, classPK, type,
2676                            orderByComparator);
2677            }
2678    
2679            /**
2680            * 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;.
2681            *
2682            * @param templateId the primary key of the current d d m template
2683            * @param classNameId the class name ID
2684            * @param classPK the class p k
2685            * @param type the type
2686            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
2687            * @return the previous, current, and next d d m template
2688            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a d d m template with the primary key could not be found
2689            * @throws SystemException if a system exception occurred
2690            */
2691            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate[] findByC_C_T_PrevAndNext(
2692                    long templateId, long classNameId, long classPK, java.lang.String type,
2693                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2694                    throws com.liferay.portal.kernel.exception.SystemException,
2695                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
2696                    return getPersistence()
2697                                       .findByC_C_T_PrevAndNext(templateId, classNameId, classPK,
2698                            type, orderByComparator);
2699            }
2700    
2701            /**
2702            * Removes all the d d m templates where classNameId = &#63; and classPK = &#63; and type = &#63; from the database.
2703            *
2704            * @param classNameId the class name ID
2705            * @param classPK the class p k
2706            * @param type the type
2707            * @throws SystemException if a system exception occurred
2708            */
2709            public static void removeByC_C_T(long classNameId, long classPK,
2710                    java.lang.String type)
2711                    throws com.liferay.portal.kernel.exception.SystemException {
2712                    getPersistence().removeByC_C_T(classNameId, classPK, type);
2713            }
2714    
2715            /**
2716            * Returns the number of d d m templates where classNameId = &#63; and classPK = &#63; and type = &#63;.
2717            *
2718            * @param classNameId the class name ID
2719            * @param classPK the class p k
2720            * @param type the type
2721            * @return the number of matching d d m templates
2722            * @throws SystemException if a system exception occurred
2723            */
2724            public static int countByC_C_T(long classNameId, long classPK,
2725                    java.lang.String type)
2726                    throws com.liferay.portal.kernel.exception.SystemException {
2727                    return getPersistence().countByC_C_T(classNameId, classPK, type);
2728            }
2729    
2730            /**
2731            * Returns all the d d m templates where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63;.
2732            *
2733            * @param groupId the group ID
2734            * @param classNameId the class name ID
2735            * @param classPK the class p k
2736            * @param type the type
2737            * @return the matching d d m templates
2738            * @throws SystemException if a system exception occurred
2739            */
2740            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByG_C_C_T(
2741                    long groupId, long classNameId, long classPK, java.lang.String type)
2742                    throws com.liferay.portal.kernel.exception.SystemException {
2743                    return getPersistence()
2744                                       .findByG_C_C_T(groupId, classNameId, classPK, type);
2745            }
2746    
2747            /**
2748            * Returns a range of all the d d m templates where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63;.
2749            *
2750            * <p>
2751            * 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.
2752            * </p>
2753            *
2754            * @param groupId the group ID
2755            * @param classNameId the class name ID
2756            * @param classPK the class p k
2757            * @param type the type
2758            * @param start the lower bound of the range of d d m templates
2759            * @param end the upper bound of the range of d d m templates (not inclusive)
2760            * @return the range of matching d d m templates
2761            * @throws SystemException if a system exception occurred
2762            */
2763            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByG_C_C_T(
2764                    long groupId, long classNameId, long classPK, java.lang.String type,
2765                    int start, int end)
2766                    throws com.liferay.portal.kernel.exception.SystemException {
2767                    return getPersistence()
2768                                       .findByG_C_C_T(groupId, classNameId, classPK, type, start,
2769                            end);
2770            }
2771    
2772            /**
2773            * Returns an ordered range of all the d d m templates where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63;.
2774            *
2775            * <p>
2776            * 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.
2777            * </p>
2778            *
2779            * @param groupId the group ID
2780            * @param classNameId the class name ID
2781            * @param classPK the class p k
2782            * @param type the type
2783            * @param start the lower bound of the range of d d m templates
2784            * @param end the upper bound of the range of d d m templates (not inclusive)
2785            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
2786            * @return the ordered range of matching d d m templates
2787            * @throws SystemException if a system exception occurred
2788            */
2789            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByG_C_C_T(
2790                    long groupId, long classNameId, long classPK, java.lang.String type,
2791                    int start, int end,
2792                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2793                    throws com.liferay.portal.kernel.exception.SystemException {
2794                    return getPersistence()
2795                                       .findByG_C_C_T(groupId, classNameId, classPK, type, start,
2796                            end, orderByComparator);
2797            }
2798    
2799            /**
2800            * Returns the first d d m template in the ordered set where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63;.
2801            *
2802            * @param groupId the group ID
2803            * @param classNameId the class name ID
2804            * @param classPK the class p k
2805            * @param type the type
2806            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
2807            * @return the first matching d d m template
2808            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
2809            * @throws SystemException if a system exception occurred
2810            */
2811            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByG_C_C_T_First(
2812                    long groupId, long classNameId, long classPK, java.lang.String type,
2813                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2814                    throws com.liferay.portal.kernel.exception.SystemException,
2815                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
2816                    return getPersistence()
2817                                       .findByG_C_C_T_First(groupId, classNameId, classPK, type,
2818                            orderByComparator);
2819            }
2820    
2821            /**
2822            * Returns the first d d m template in the ordered set where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63;.
2823            *
2824            * @param groupId the group ID
2825            * @param classNameId the class name ID
2826            * @param classPK the class p k
2827            * @param type the type
2828            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
2829            * @return the first matching d d m template, or <code>null</code> if a matching d d m template could not be found
2830            * @throws SystemException if a system exception occurred
2831            */
2832            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByG_C_C_T_First(
2833                    long groupId, long classNameId, long classPK, java.lang.String type,
2834                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2835                    throws com.liferay.portal.kernel.exception.SystemException {
2836                    return getPersistence()
2837                                       .fetchByG_C_C_T_First(groupId, classNameId, classPK, type,
2838                            orderByComparator);
2839            }
2840    
2841            /**
2842            * Returns the last d d m template in the ordered set where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63;.
2843            *
2844            * @param groupId the group ID
2845            * @param classNameId the class name ID
2846            * @param classPK the class p k
2847            * @param type the type
2848            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
2849            * @return the last matching d d m template
2850            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
2851            * @throws SystemException if a system exception occurred
2852            */
2853            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByG_C_C_T_Last(
2854                    long groupId, long classNameId, long classPK, java.lang.String type,
2855                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2856                    throws com.liferay.portal.kernel.exception.SystemException,
2857                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
2858                    return getPersistence()
2859                                       .findByG_C_C_T_Last(groupId, classNameId, classPK, type,
2860                            orderByComparator);
2861            }
2862    
2863            /**
2864            * Returns the last d d m template in the ordered set where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63;.
2865            *
2866            * @param groupId the group ID
2867            * @param classNameId the class name ID
2868            * @param classPK the class p k
2869            * @param type the type
2870            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
2871            * @return the last matching d d m template, or <code>null</code> if a matching d d m template could not be found
2872            * @throws SystemException if a system exception occurred
2873            */
2874            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByG_C_C_T_Last(
2875                    long groupId, long classNameId, long classPK, java.lang.String type,
2876                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2877                    throws com.liferay.portal.kernel.exception.SystemException {
2878                    return getPersistence()
2879                                       .fetchByG_C_C_T_Last(groupId, classNameId, classPK, type,
2880                            orderByComparator);
2881            }
2882    
2883            /**
2884            * 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;.
2885            *
2886            * @param templateId the primary key of the current d d m template
2887            * @param groupId the group ID
2888            * @param classNameId the class name ID
2889            * @param classPK the class p k
2890            * @param type the type
2891            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
2892            * @return the previous, current, and next d d m template
2893            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a d d m template with the primary key could not be found
2894            * @throws SystemException if a system exception occurred
2895            */
2896            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate[] findByG_C_C_T_PrevAndNext(
2897                    long templateId, long groupId, long classNameId, long classPK,
2898                    java.lang.String type,
2899                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2900                    throws com.liferay.portal.kernel.exception.SystemException,
2901                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
2902                    return getPersistence()
2903                                       .findByG_C_C_T_PrevAndNext(templateId, groupId, classNameId,
2904                            classPK, type, orderByComparator);
2905            }
2906    
2907            /**
2908            * 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;.
2909            *
2910            * @param groupId the group ID
2911            * @param classNameId the class name ID
2912            * @param classPK the class p k
2913            * @param type the type
2914            * @return the matching d d m templates that the user has permission to view
2915            * @throws SystemException if a system exception occurred
2916            */
2917            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> filterFindByG_C_C_T(
2918                    long groupId, long classNameId, long classPK, java.lang.String type)
2919                    throws com.liferay.portal.kernel.exception.SystemException {
2920                    return getPersistence()
2921                                       .filterFindByG_C_C_T(groupId, classNameId, classPK, type);
2922            }
2923    
2924            /**
2925            * 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;.
2926            *
2927            * <p>
2928            * 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.
2929            * </p>
2930            *
2931            * @param groupId the group ID
2932            * @param classNameId the class name ID
2933            * @param classPK the class p k
2934            * @param type the type
2935            * @param start the lower bound of the range of d d m templates
2936            * @param end the upper bound of the range of d d m templates (not inclusive)
2937            * @return the range of matching d d m templates that the user has permission to view
2938            * @throws SystemException if a system exception occurred
2939            */
2940            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> filterFindByG_C_C_T(
2941                    long groupId, long classNameId, long classPK, java.lang.String type,
2942                    int start, int end)
2943                    throws com.liferay.portal.kernel.exception.SystemException {
2944                    return getPersistence()
2945                                       .filterFindByG_C_C_T(groupId, classNameId, classPK, type,
2946                            start, end);
2947            }
2948    
2949            /**
2950            * 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;.
2951            *
2952            * <p>
2953            * 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.
2954            * </p>
2955            *
2956            * @param groupId the group ID
2957            * @param classNameId the class name ID
2958            * @param classPK the class p k
2959            * @param type the type
2960            * @param start the lower bound of the range of d d m templates
2961            * @param end the upper bound of the range of d d m templates (not inclusive)
2962            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
2963            * @return the ordered range of matching d d m templates that the user has permission to view
2964            * @throws SystemException if a system exception occurred
2965            */
2966            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> filterFindByG_C_C_T(
2967                    long groupId, long classNameId, long classPK, java.lang.String type,
2968                    int start, int end,
2969                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2970                    throws com.liferay.portal.kernel.exception.SystemException {
2971                    return getPersistence()
2972                                       .filterFindByG_C_C_T(groupId, classNameId, classPK, type,
2973                            start, end, orderByComparator);
2974            }
2975    
2976            /**
2977            * 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;.
2978            *
2979            * @param templateId the primary key of the current d d m template
2980            * @param groupId the group ID
2981            * @param classNameId the class name ID
2982            * @param classPK the class p k
2983            * @param type the type
2984            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
2985            * @return the previous, current, and next d d m template
2986            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a d d m template with the primary key could not be found
2987            * @throws SystemException if a system exception occurred
2988            */
2989            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate[] filterFindByG_C_C_T_PrevAndNext(
2990                    long templateId, long groupId, long classNameId, long classPK,
2991                    java.lang.String type,
2992                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
2993                    throws com.liferay.portal.kernel.exception.SystemException,
2994                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
2995                    return getPersistence()
2996                                       .filterFindByG_C_C_T_PrevAndNext(templateId, groupId,
2997                            classNameId, classPK, type, orderByComparator);
2998            }
2999    
3000            /**
3001            * Removes all the d d m templates where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63; from the database.
3002            *
3003            * @param groupId the group ID
3004            * @param classNameId the class name ID
3005            * @param classPK the class p k
3006            * @param type the type
3007            * @throws SystemException if a system exception occurred
3008            */
3009            public static void removeByG_C_C_T(long groupId, long classNameId,
3010                    long classPK, java.lang.String type)
3011                    throws com.liferay.portal.kernel.exception.SystemException {
3012                    getPersistence().removeByG_C_C_T(groupId, classNameId, classPK, type);
3013            }
3014    
3015            /**
3016            * Returns the number of d d m templates where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63;.
3017            *
3018            * @param groupId the group ID
3019            * @param classNameId the class name ID
3020            * @param classPK the class p k
3021            * @param type the type
3022            * @return the number of matching d d m templates
3023            * @throws SystemException if a system exception occurred
3024            */
3025            public static int countByG_C_C_T(long groupId, long classNameId,
3026                    long classPK, java.lang.String type)
3027                    throws com.liferay.portal.kernel.exception.SystemException {
3028                    return getPersistence()
3029                                       .countByG_C_C_T(groupId, classNameId, classPK, type);
3030            }
3031    
3032            /**
3033            * 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;.
3034            *
3035            * @param groupId the group ID
3036            * @param classNameId the class name ID
3037            * @param classPK the class p k
3038            * @param type the type
3039            * @return the number of matching d d m templates that the user has permission to view
3040            * @throws SystemException if a system exception occurred
3041            */
3042            public static int filterCountByG_C_C_T(long groupId, long classNameId,
3043                    long classPK, java.lang.String type)
3044                    throws com.liferay.portal.kernel.exception.SystemException {
3045                    return getPersistence()
3046                                       .filterCountByG_C_C_T(groupId, classNameId, classPK, type);
3047            }
3048    
3049            /**
3050            * Returns all the d d m templates where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63; and mode = &#63;.
3051            *
3052            * @param groupId the group ID
3053            * @param classNameId the class name ID
3054            * @param classPK the class p k
3055            * @param type the type
3056            * @param mode the mode
3057            * @return the matching d d m templates
3058            * @throws SystemException if a system exception occurred
3059            */
3060            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByG_C_C_T_M(
3061                    long groupId, long classNameId, long classPK, java.lang.String type,
3062                    java.lang.String mode)
3063                    throws com.liferay.portal.kernel.exception.SystemException {
3064                    return getPersistence()
3065                                       .findByG_C_C_T_M(groupId, classNameId, classPK, type, mode);
3066            }
3067    
3068            /**
3069            * 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;.
3070            *
3071            * <p>
3072            * 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.
3073            * </p>
3074            *
3075            * @param groupId the group ID
3076            * @param classNameId the class name ID
3077            * @param classPK the class p k
3078            * @param type the type
3079            * @param mode the mode
3080            * @param start the lower bound of the range of d d m templates
3081            * @param end the upper bound of the range of d d m templates (not inclusive)
3082            * @return the range of matching d d m templates
3083            * @throws SystemException if a system exception occurred
3084            */
3085            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByG_C_C_T_M(
3086                    long groupId, long classNameId, long classPK, java.lang.String type,
3087                    java.lang.String mode, int start, int end)
3088                    throws com.liferay.portal.kernel.exception.SystemException {
3089                    return getPersistence()
3090                                       .findByG_C_C_T_M(groupId, classNameId, classPK, type, mode,
3091                            start, end);
3092            }
3093    
3094            /**
3095            * 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;.
3096            *
3097            * <p>
3098            * 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.
3099            * </p>
3100            *
3101            * @param groupId the group ID
3102            * @param classNameId the class name ID
3103            * @param classPK the class p k
3104            * @param type the type
3105            * @param mode the mode
3106            * @param start the lower bound of the range of d d m templates
3107            * @param end the upper bound of the range of d d m templates (not inclusive)
3108            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
3109            * @return the ordered range of matching d d m templates
3110            * @throws SystemException if a system exception occurred
3111            */
3112            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findByG_C_C_T_M(
3113                    long groupId, long classNameId, long classPK, java.lang.String type,
3114                    java.lang.String mode, int start, int end,
3115                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
3116                    throws com.liferay.portal.kernel.exception.SystemException {
3117                    return getPersistence()
3118                                       .findByG_C_C_T_M(groupId, classNameId, classPK, type, mode,
3119                            start, end, orderByComparator);
3120            }
3121    
3122            /**
3123            * 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;.
3124            *
3125            * @param groupId the group ID
3126            * @param classNameId the class name ID
3127            * @param classPK the class p k
3128            * @param type the type
3129            * @param mode the mode
3130            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
3131            * @return the first matching d d m template
3132            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
3133            * @throws SystemException if a system exception occurred
3134            */
3135            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByG_C_C_T_M_First(
3136                    long groupId, long classNameId, long classPK, java.lang.String type,
3137                    java.lang.String mode,
3138                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
3139                    throws com.liferay.portal.kernel.exception.SystemException,
3140                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
3141                    return getPersistence()
3142                                       .findByG_C_C_T_M_First(groupId, classNameId, classPK, type,
3143                            mode, orderByComparator);
3144            }
3145    
3146            /**
3147            * 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;.
3148            *
3149            * @param groupId the group ID
3150            * @param classNameId the class name ID
3151            * @param classPK the class p k
3152            * @param type the type
3153            * @param mode the mode
3154            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
3155            * @return the first matching d d m template, or <code>null</code> if a matching d d m template could not be found
3156            * @throws SystemException if a system exception occurred
3157            */
3158            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByG_C_C_T_M_First(
3159                    long groupId, long classNameId, long classPK, java.lang.String type,
3160                    java.lang.String mode,
3161                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
3162                    throws com.liferay.portal.kernel.exception.SystemException {
3163                    return getPersistence()
3164                                       .fetchByG_C_C_T_M_First(groupId, classNameId, classPK, type,
3165                            mode, orderByComparator);
3166            }
3167    
3168            /**
3169            * 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;.
3170            *
3171            * @param groupId the group ID
3172            * @param classNameId the class name ID
3173            * @param classPK the class p k
3174            * @param type the type
3175            * @param mode the mode
3176            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
3177            * @return the last matching d d m template
3178            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a matching d d m template could not be found
3179            * @throws SystemException if a system exception occurred
3180            */
3181            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByG_C_C_T_M_Last(
3182                    long groupId, long classNameId, long classPK, java.lang.String type,
3183                    java.lang.String mode,
3184                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
3185                    throws com.liferay.portal.kernel.exception.SystemException,
3186                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
3187                    return getPersistence()
3188                                       .findByG_C_C_T_M_Last(groupId, classNameId, classPK, type,
3189                            mode, orderByComparator);
3190            }
3191    
3192            /**
3193            * 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;.
3194            *
3195            * @param groupId the group ID
3196            * @param classNameId the class name ID
3197            * @param classPK the class p k
3198            * @param type the type
3199            * @param mode the mode
3200            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
3201            * @return the last matching d d m template, or <code>null</code> if a matching d d m template could not be found
3202            * @throws SystemException if a system exception occurred
3203            */
3204            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByG_C_C_T_M_Last(
3205                    long groupId, long classNameId, long classPK, java.lang.String type,
3206                    java.lang.String mode,
3207                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
3208                    throws com.liferay.portal.kernel.exception.SystemException {
3209                    return getPersistence()
3210                                       .fetchByG_C_C_T_M_Last(groupId, classNameId, classPK, type,
3211                            mode, orderByComparator);
3212            }
3213    
3214            /**
3215            * 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;.
3216            *
3217            * @param templateId the primary key of the current d d m template
3218            * @param groupId the group ID
3219            * @param classNameId the class name ID
3220            * @param classPK the class p k
3221            * @param type the type
3222            * @param mode the mode
3223            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
3224            * @return the previous, current, and next d d m template
3225            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a d d m template with the primary key could not be found
3226            * @throws SystemException if a system exception occurred
3227            */
3228            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate[] findByG_C_C_T_M_PrevAndNext(
3229                    long templateId, long groupId, long classNameId, long classPK,
3230                    java.lang.String type, java.lang.String mode,
3231                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
3232                    throws com.liferay.portal.kernel.exception.SystemException,
3233                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
3234                    return getPersistence()
3235                                       .findByG_C_C_T_M_PrevAndNext(templateId, groupId,
3236                            classNameId, classPK, type, mode, orderByComparator);
3237            }
3238    
3239            /**
3240            * 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;.
3241            *
3242            * @param groupId the group ID
3243            * @param classNameId the class name ID
3244            * @param classPK the class p k
3245            * @param type the type
3246            * @param mode the mode
3247            * @return the matching d d m templates that the user has permission to view
3248            * @throws SystemException if a system exception occurred
3249            */
3250            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> filterFindByG_C_C_T_M(
3251                    long groupId, long classNameId, long classPK, java.lang.String type,
3252                    java.lang.String mode)
3253                    throws com.liferay.portal.kernel.exception.SystemException {
3254                    return getPersistence()
3255                                       .filterFindByG_C_C_T_M(groupId, classNameId, classPK, type,
3256                            mode);
3257            }
3258    
3259            /**
3260            * 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;.
3261            *
3262            * <p>
3263            * 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.
3264            * </p>
3265            *
3266            * @param groupId the group ID
3267            * @param classNameId the class name ID
3268            * @param classPK the class p k
3269            * @param type the type
3270            * @param mode the mode
3271            * @param start the lower bound of the range of d d m templates
3272            * @param end the upper bound of the range of d d m templates (not inclusive)
3273            * @return the range of matching d d m templates that the user has permission to view
3274            * @throws SystemException if a system exception occurred
3275            */
3276            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> filterFindByG_C_C_T_M(
3277                    long groupId, long classNameId, long classPK, java.lang.String type,
3278                    java.lang.String mode, int start, int end)
3279                    throws com.liferay.portal.kernel.exception.SystemException {
3280                    return getPersistence()
3281                                       .filterFindByG_C_C_T_M(groupId, classNameId, classPK, type,
3282                            mode, start, end);
3283            }
3284    
3285            /**
3286            * 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;.
3287            *
3288            * <p>
3289            * 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.
3290            * </p>
3291            *
3292            * @param groupId the group ID
3293            * @param classNameId the class name ID
3294            * @param classPK the class p k
3295            * @param type the type
3296            * @param mode the mode
3297            * @param start the lower bound of the range of d d m templates
3298            * @param end the upper bound of the range of d d m templates (not inclusive)
3299            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
3300            * @return the ordered range of matching d d m templates that the user has permission to view
3301            * @throws SystemException if a system exception occurred
3302            */
3303            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> filterFindByG_C_C_T_M(
3304                    long groupId, long classNameId, long classPK, java.lang.String type,
3305                    java.lang.String mode, int start, int end,
3306                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
3307                    throws com.liferay.portal.kernel.exception.SystemException {
3308                    return getPersistence()
3309                                       .filterFindByG_C_C_T_M(groupId, classNameId, classPK, type,
3310                            mode, start, end, orderByComparator);
3311            }
3312    
3313            /**
3314            * 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;.
3315            *
3316            * @param templateId the primary key of the current d d m template
3317            * @param groupId the group ID
3318            * @param classNameId the class name ID
3319            * @param classPK the class p k
3320            * @param type the type
3321            * @param mode the mode
3322            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
3323            * @return the previous, current, and next d d m template
3324            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a d d m template with the primary key could not be found
3325            * @throws SystemException if a system exception occurred
3326            */
3327            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate[] filterFindByG_C_C_T_M_PrevAndNext(
3328                    long templateId, long groupId, long classNameId, long classPK,
3329                    java.lang.String type, java.lang.String mode,
3330                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
3331                    throws com.liferay.portal.kernel.exception.SystemException,
3332                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
3333                    return getPersistence()
3334                                       .filterFindByG_C_C_T_M_PrevAndNext(templateId, groupId,
3335                            classNameId, classPK, type, mode, orderByComparator);
3336            }
3337    
3338            /**
3339            * 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.
3340            *
3341            * @param groupId the group ID
3342            * @param classNameId the class name ID
3343            * @param classPK the class p k
3344            * @param type the type
3345            * @param mode the mode
3346            * @throws SystemException if a system exception occurred
3347            */
3348            public static void removeByG_C_C_T_M(long groupId, long classNameId,
3349                    long classPK, java.lang.String type, java.lang.String mode)
3350                    throws com.liferay.portal.kernel.exception.SystemException {
3351                    getPersistence()
3352                            .removeByG_C_C_T_M(groupId, classNameId, classPK, type, mode);
3353            }
3354    
3355            /**
3356            * Returns the number of d d m templates where groupId = &#63; and classNameId = &#63; and classPK = &#63; and type = &#63; and mode = &#63;.
3357            *
3358            * @param groupId the group ID
3359            * @param classNameId the class name ID
3360            * @param classPK the class p k
3361            * @param type the type
3362            * @param mode the mode
3363            * @return the number of matching d d m templates
3364            * @throws SystemException if a system exception occurred
3365            */
3366            public static int countByG_C_C_T_M(long groupId, long classNameId,
3367                    long classPK, java.lang.String type, java.lang.String mode)
3368                    throws com.liferay.portal.kernel.exception.SystemException {
3369                    return getPersistence()
3370                                       .countByG_C_C_T_M(groupId, classNameId, classPK, type, mode);
3371            }
3372    
3373            /**
3374            * 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;.
3375            *
3376            * @param groupId the group ID
3377            * @param classNameId the class name ID
3378            * @param classPK the class p k
3379            * @param type the type
3380            * @param mode the mode
3381            * @return the number of matching d d m templates that the user has permission to view
3382            * @throws SystemException if a system exception occurred
3383            */
3384            public static int filterCountByG_C_C_T_M(long groupId, long classNameId,
3385                    long classPK, java.lang.String type, java.lang.String mode)
3386                    throws com.liferay.portal.kernel.exception.SystemException {
3387                    return getPersistence()
3388                                       .filterCountByG_C_C_T_M(groupId, classNameId, classPK, type,
3389                            mode);
3390            }
3391    
3392            /**
3393            * Caches the d d m template in the entity cache if it is enabled.
3394            *
3395            * @param ddmTemplate the d d m template
3396            */
3397            public static void cacheResult(
3398                    com.liferay.portlet.dynamicdatamapping.model.DDMTemplate ddmTemplate) {
3399                    getPersistence().cacheResult(ddmTemplate);
3400            }
3401    
3402            /**
3403            * Caches the d d m templates in the entity cache if it is enabled.
3404            *
3405            * @param ddmTemplates the d d m templates
3406            */
3407            public static void cacheResult(
3408                    java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> ddmTemplates) {
3409                    getPersistence().cacheResult(ddmTemplates);
3410            }
3411    
3412            /**
3413            * Creates a new d d m template with the primary key. Does not add the d d m template to the database.
3414            *
3415            * @param templateId the primary key for the new d d m template
3416            * @return the new d d m template
3417            */
3418            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate create(
3419                    long templateId) {
3420                    return getPersistence().create(templateId);
3421            }
3422    
3423            /**
3424            * Removes the d d m template with the primary key from the database. Also notifies the appropriate model listeners.
3425            *
3426            * @param templateId the primary key of the d d m template
3427            * @return the d d m template that was removed
3428            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a d d m template with the primary key could not be found
3429            * @throws SystemException if a system exception occurred
3430            */
3431            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate remove(
3432                    long templateId)
3433                    throws com.liferay.portal.kernel.exception.SystemException,
3434                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
3435                    return getPersistence().remove(templateId);
3436            }
3437    
3438            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate updateImpl(
3439                    com.liferay.portlet.dynamicdatamapping.model.DDMTemplate ddmTemplate)
3440                    throws com.liferay.portal.kernel.exception.SystemException {
3441                    return getPersistence().updateImpl(ddmTemplate);
3442            }
3443    
3444            /**
3445            * 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.
3446            *
3447            * @param templateId the primary key of the d d m template
3448            * @return the d d m template
3449            * @throws com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException if a d d m template with the primary key could not be found
3450            * @throws SystemException if a system exception occurred
3451            */
3452            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate findByPrimaryKey(
3453                    long templateId)
3454                    throws com.liferay.portal.kernel.exception.SystemException,
3455                            com.liferay.portlet.dynamicdatamapping.NoSuchTemplateException {
3456                    return getPersistence().findByPrimaryKey(templateId);
3457            }
3458    
3459            /**
3460            * Returns the d d m template with the primary key or returns <code>null</code> if it could not be found.
3461            *
3462            * @param templateId the primary key of the d d m template
3463            * @return the d d m template, or <code>null</code> if a d d m template with the primary key could not be found
3464            * @throws SystemException if a system exception occurred
3465            */
3466            public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate fetchByPrimaryKey(
3467                    long templateId)
3468                    throws com.liferay.portal.kernel.exception.SystemException {
3469                    return getPersistence().fetchByPrimaryKey(templateId);
3470            }
3471    
3472            /**
3473            * Returns all the d d m templates.
3474            *
3475            * @return the d d m templates
3476            * @throws SystemException if a system exception occurred
3477            */
3478            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findAll()
3479                    throws com.liferay.portal.kernel.exception.SystemException {
3480                    return getPersistence().findAll();
3481            }
3482    
3483            /**
3484            * Returns a range of all the d d m templates.
3485            *
3486            * <p>
3487            * 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.
3488            * </p>
3489            *
3490            * @param start the lower bound of the range of d d m templates
3491            * @param end the upper bound of the range of d d m templates (not inclusive)
3492            * @return the range of d d m templates
3493            * @throws SystemException if a system exception occurred
3494            */
3495            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findAll(
3496                    int start, int end)
3497                    throws com.liferay.portal.kernel.exception.SystemException {
3498                    return getPersistence().findAll(start, end);
3499            }
3500    
3501            /**
3502            * Returns an ordered range of all the d d m templates.
3503            *
3504            * <p>
3505            * 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.
3506            * </p>
3507            *
3508            * @param start the lower bound of the range of d d m templates
3509            * @param end the upper bound of the range of d d m templates (not inclusive)
3510            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
3511            * @return the ordered range of d d m templates
3512            * @throws SystemException if a system exception occurred
3513            */
3514            public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> findAll(
3515                    int start, int end,
3516                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
3517                    throws com.liferay.portal.kernel.exception.SystemException {
3518                    return getPersistence().findAll(start, end, orderByComparator);
3519            }
3520    
3521            /**
3522            * Removes all the d d m templates from the database.
3523            *
3524            * @throws SystemException if a system exception occurred
3525            */
3526            public static void removeAll()
3527                    throws com.liferay.portal.kernel.exception.SystemException {
3528                    getPersistence().removeAll();
3529            }
3530    
3531            /**
3532            * Returns the number of d d m templates.
3533            *
3534            * @return the number of d d m templates
3535            * @throws SystemException if a system exception occurred
3536            */
3537            public static int countAll()
3538                    throws com.liferay.portal.kernel.exception.SystemException {
3539                    return getPersistence().countAll();
3540            }
3541    
3542            public static DDMTemplatePersistence getPersistence() {
3543                    if (_persistence == null) {
3544                            _persistence = (DDMTemplatePersistence)PortalBeanLocatorUtil.locate(DDMTemplatePersistence.class.getName());
3545    
3546                            ReferenceRegistry.registerReference(DDMTemplateUtil.class,
3547                                    "_persistence");
3548                    }
3549    
3550                    return _persistence;
3551            }
3552    
3553            /**
3554             * @deprecated As of 6.2.0
3555             */
3556            public void setPersistence(DDMTemplatePersistence persistence) {
3557            }
3558    
3559            private static DDMTemplatePersistence _persistence;
3560    }