001    /**
002     * Copyright (c) 2000-present 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.portal.service.persistence;
016    
017    import aQute.bnd.annotation.ProviderType;
018    
019    import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
020    import com.liferay.portal.kernel.dao.orm.DynamicQuery;
021    import com.liferay.portal.kernel.util.OrderByComparator;
022    import com.liferay.portal.kernel.util.ReferenceRegistry;
023    import com.liferay.portal.model.Organization;
024    import com.liferay.portal.service.ServiceContext;
025    
026    import java.util.List;
027    
028    /**
029     * The persistence utility for the organization service. This utility wraps {@link com.liferay.portal.service.persistence.impl.OrganizationPersistenceImpl} 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 OrganizationPersistence
037     * @see com.liferay.portal.service.persistence.impl.OrganizationPersistenceImpl
038     * @generated
039     */
040    @ProviderType
041    public class OrganizationUtil {
042            /*
043             * NOTE FOR DEVELOPERS:
044             *
045             * Never modify this class directly. Modify <code>service.xml</code> and rerun ServiceBuilder to regenerate this class.
046             */
047    
048            /**
049             * @see com.liferay.portal.service.persistence.BasePersistence#clearCache()
050             */
051            public static void clearCache() {
052                    getPersistence().clearCache();
053            }
054    
055            /**
056             * @see com.liferay.portal.service.persistence.BasePersistence#clearCache(com.liferay.portal.model.BaseModel)
057             */
058            public static void clearCache(Organization organization) {
059                    getPersistence().clearCache(organization);
060            }
061    
062            /**
063             * @see com.liferay.portal.service.persistence.BasePersistence#countWithDynamicQuery(DynamicQuery)
064             */
065            public static long countWithDynamicQuery(DynamicQuery dynamicQuery) {
066                    return getPersistence().countWithDynamicQuery(dynamicQuery);
067            }
068    
069            /**
070             * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery)
071             */
072            public static List<Organization> findWithDynamicQuery(
073                    DynamicQuery dynamicQuery) {
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<Organization> findWithDynamicQuery(
081                    DynamicQuery dynamicQuery, int start, int end) {
082                    return getPersistence().findWithDynamicQuery(dynamicQuery, start, end);
083            }
084    
085            /**
086             * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery, int, int, OrderByComparator)
087             */
088            public static List<Organization> findWithDynamicQuery(
089                    DynamicQuery dynamicQuery, int start, int end,
090                    OrderByComparator<Organization> orderByComparator) {
091                    return getPersistence()
092                                       .findWithDynamicQuery(dynamicQuery, start, end,
093                            orderByComparator);
094            }
095    
096            /**
097             * @see com.liferay.portal.service.persistence.BasePersistence#update(com.liferay.portal.model.BaseModel)
098             */
099            public static Organization update(Organization organization) {
100                    return getPersistence().update(organization);
101            }
102    
103            /**
104             * @see com.liferay.portal.service.persistence.BasePersistence#update(com.liferay.portal.model.BaseModel, ServiceContext)
105             */
106            public static Organization update(Organization organization,
107                    ServiceContext serviceContext) {
108                    return getPersistence().update(organization, serviceContext);
109            }
110    
111            /**
112            * Returns all the organizations where uuid = &#63;.
113            *
114            * @param uuid the uuid
115            * @return the matching organizations
116            */
117            public static List<Organization> findByUuid(java.lang.String uuid) {
118                    return getPersistence().findByUuid(uuid);
119            }
120    
121            /**
122            * Returns a range of all the organizations where uuid = &#63;.
123            *
124            * <p>
125            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link OrganizationModelImpl}. 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.
126            * </p>
127            *
128            * @param uuid the uuid
129            * @param start the lower bound of the range of organizations
130            * @param end the upper bound of the range of organizations (not inclusive)
131            * @return the range of matching organizations
132            */
133            public static List<Organization> findByUuid(java.lang.String uuid,
134                    int start, int end) {
135                    return getPersistence().findByUuid(uuid, start, end);
136            }
137    
138            /**
139            * Returns an ordered range of all the organizations where uuid = &#63;.
140            *
141            * <p>
142            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link OrganizationModelImpl}. 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.
143            * </p>
144            *
145            * @param uuid the uuid
146            * @param start the lower bound of the range of organizations
147            * @param end the upper bound of the range of organizations (not inclusive)
148            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
149            * @return the ordered range of matching organizations
150            */
151            public static List<Organization> findByUuid(java.lang.String uuid,
152                    int start, int end, OrderByComparator<Organization> orderByComparator) {
153                    return getPersistence().findByUuid(uuid, start, end, orderByComparator);
154            }
155    
156            /**
157            * Returns the first organization in the ordered set where uuid = &#63;.
158            *
159            * @param uuid the uuid
160            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
161            * @return the first matching organization
162            * @throws NoSuchOrganizationException if a matching organization could not be found
163            */
164            public static Organization findByUuid_First(java.lang.String uuid,
165                    OrderByComparator<Organization> orderByComparator)
166                    throws com.liferay.portal.NoSuchOrganizationException {
167                    return getPersistence().findByUuid_First(uuid, orderByComparator);
168            }
169    
170            /**
171            * Returns the first organization in the ordered set where uuid = &#63;.
172            *
173            * @param uuid the uuid
174            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
175            * @return the first matching organization, or <code>null</code> if a matching organization could not be found
176            */
177            public static Organization fetchByUuid_First(java.lang.String uuid,
178                    OrderByComparator<Organization> orderByComparator) {
179                    return getPersistence().fetchByUuid_First(uuid, orderByComparator);
180            }
181    
182            /**
183            * Returns the last organization in the ordered set where uuid = &#63;.
184            *
185            * @param uuid the uuid
186            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
187            * @return the last matching organization
188            * @throws NoSuchOrganizationException if a matching organization could not be found
189            */
190            public static Organization findByUuid_Last(java.lang.String uuid,
191                    OrderByComparator<Organization> orderByComparator)
192                    throws com.liferay.portal.NoSuchOrganizationException {
193                    return getPersistence().findByUuid_Last(uuid, orderByComparator);
194            }
195    
196            /**
197            * Returns the last organization in the ordered set where uuid = &#63;.
198            *
199            * @param uuid the uuid
200            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
201            * @return the last matching organization, or <code>null</code> if a matching organization could not be found
202            */
203            public static Organization fetchByUuid_Last(java.lang.String uuid,
204                    OrderByComparator<Organization> orderByComparator) {
205                    return getPersistence().fetchByUuid_Last(uuid, orderByComparator);
206            }
207    
208            /**
209            * Returns the organizations before and after the current organization in the ordered set where uuid = &#63;.
210            *
211            * @param organizationId the primary key of the current organization
212            * @param uuid the uuid
213            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
214            * @return the previous, current, and next organization
215            * @throws NoSuchOrganizationException if a organization with the primary key could not be found
216            */
217            public static Organization[] findByUuid_PrevAndNext(long organizationId,
218                    java.lang.String uuid, OrderByComparator<Organization> orderByComparator)
219                    throws com.liferay.portal.NoSuchOrganizationException {
220                    return getPersistence()
221                                       .findByUuid_PrevAndNext(organizationId, uuid,
222                            orderByComparator);
223            }
224    
225            /**
226            * Returns all the organizations that the user has permission to view where uuid = &#63;.
227            *
228            * @param uuid the uuid
229            * @return the matching organizations that the user has permission to view
230            */
231            public static List<Organization> filterFindByUuid(java.lang.String uuid) {
232                    return getPersistence().filterFindByUuid(uuid);
233            }
234    
235            /**
236            * Returns a range of all the organizations that the user has permission to view where uuid = &#63;.
237            *
238            * <p>
239            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link OrganizationModelImpl}. 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.
240            * </p>
241            *
242            * @param uuid the uuid
243            * @param start the lower bound of the range of organizations
244            * @param end the upper bound of the range of organizations (not inclusive)
245            * @return the range of matching organizations that the user has permission to view
246            */
247            public static List<Organization> filterFindByUuid(java.lang.String uuid,
248                    int start, int end) {
249                    return getPersistence().filterFindByUuid(uuid, start, end);
250            }
251    
252            /**
253            * Returns an ordered range of all the organizations that the user has permissions to view where uuid = &#63;.
254            *
255            * <p>
256            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link OrganizationModelImpl}. 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.
257            * </p>
258            *
259            * @param uuid the uuid
260            * @param start the lower bound of the range of organizations
261            * @param end the upper bound of the range of organizations (not inclusive)
262            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
263            * @return the ordered range of matching organizations that the user has permission to view
264            */
265            public static List<Organization> filterFindByUuid(java.lang.String uuid,
266                    int start, int end, OrderByComparator<Organization> orderByComparator) {
267                    return getPersistence()
268                                       .filterFindByUuid(uuid, start, end, orderByComparator);
269            }
270    
271            /**
272            * Returns the organizations before and after the current organization in the ordered set of organizations that the user has permission to view where uuid = &#63;.
273            *
274            * @param organizationId the primary key of the current organization
275            * @param uuid the uuid
276            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
277            * @return the previous, current, and next organization
278            * @throws NoSuchOrganizationException if a organization with the primary key could not be found
279            */
280            public static Organization[] filterFindByUuid_PrevAndNext(
281                    long organizationId, java.lang.String uuid,
282                    OrderByComparator<Organization> orderByComparator)
283                    throws com.liferay.portal.NoSuchOrganizationException {
284                    return getPersistence()
285                                       .filterFindByUuid_PrevAndNext(organizationId, uuid,
286                            orderByComparator);
287            }
288    
289            /**
290            * Removes all the organizations where uuid = &#63; from the database.
291            *
292            * @param uuid the uuid
293            */
294            public static void removeByUuid(java.lang.String uuid) {
295                    getPersistence().removeByUuid(uuid);
296            }
297    
298            /**
299            * Returns the number of organizations where uuid = &#63;.
300            *
301            * @param uuid the uuid
302            * @return the number of matching organizations
303            */
304            public static int countByUuid(java.lang.String uuid) {
305                    return getPersistence().countByUuid(uuid);
306            }
307    
308            /**
309            * Returns the number of organizations that the user has permission to view where uuid = &#63;.
310            *
311            * @param uuid the uuid
312            * @return the number of matching organizations that the user has permission to view
313            */
314            public static int filterCountByUuid(java.lang.String uuid) {
315                    return getPersistence().filterCountByUuid(uuid);
316            }
317    
318            /**
319            * Returns all the organizations where uuid = &#63; and companyId = &#63;.
320            *
321            * @param uuid the uuid
322            * @param companyId the company ID
323            * @return the matching organizations
324            */
325            public static List<Organization> findByUuid_C(java.lang.String uuid,
326                    long companyId) {
327                    return getPersistence().findByUuid_C(uuid, companyId);
328            }
329    
330            /**
331            * Returns a range of all the organizations where uuid = &#63; and companyId = &#63;.
332            *
333            * <p>
334            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link OrganizationModelImpl}. 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.
335            * </p>
336            *
337            * @param uuid the uuid
338            * @param companyId the company ID
339            * @param start the lower bound of the range of organizations
340            * @param end the upper bound of the range of organizations (not inclusive)
341            * @return the range of matching organizations
342            */
343            public static List<Organization> findByUuid_C(java.lang.String uuid,
344                    long companyId, int start, int end) {
345                    return getPersistence().findByUuid_C(uuid, companyId, start, end);
346            }
347    
348            /**
349            * Returns an ordered range of all the organizations where uuid = &#63; and companyId = &#63;.
350            *
351            * <p>
352            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link OrganizationModelImpl}. 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.
353            * </p>
354            *
355            * @param uuid the uuid
356            * @param companyId the company ID
357            * @param start the lower bound of the range of organizations
358            * @param end the upper bound of the range of organizations (not inclusive)
359            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
360            * @return the ordered range of matching organizations
361            */
362            public static List<Organization> findByUuid_C(java.lang.String uuid,
363                    long companyId, int start, int end,
364                    OrderByComparator<Organization> orderByComparator) {
365                    return getPersistence()
366                                       .findByUuid_C(uuid, companyId, start, end, orderByComparator);
367            }
368    
369            /**
370            * Returns the first organization in the ordered set where uuid = &#63; and companyId = &#63;.
371            *
372            * @param uuid the uuid
373            * @param companyId the company ID
374            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
375            * @return the first matching organization
376            * @throws NoSuchOrganizationException if a matching organization could not be found
377            */
378            public static Organization findByUuid_C_First(java.lang.String uuid,
379                    long companyId, OrderByComparator<Organization> orderByComparator)
380                    throws com.liferay.portal.NoSuchOrganizationException {
381                    return getPersistence()
382                                       .findByUuid_C_First(uuid, companyId, orderByComparator);
383            }
384    
385            /**
386            * Returns the first organization in the ordered set where uuid = &#63; and companyId = &#63;.
387            *
388            * @param uuid the uuid
389            * @param companyId the company ID
390            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
391            * @return the first matching organization, or <code>null</code> if a matching organization could not be found
392            */
393            public static Organization fetchByUuid_C_First(java.lang.String uuid,
394                    long companyId, OrderByComparator<Organization> orderByComparator) {
395                    return getPersistence()
396                                       .fetchByUuid_C_First(uuid, companyId, orderByComparator);
397            }
398    
399            /**
400            * Returns the last organization in the ordered set where uuid = &#63; and companyId = &#63;.
401            *
402            * @param uuid the uuid
403            * @param companyId the company ID
404            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
405            * @return the last matching organization
406            * @throws NoSuchOrganizationException if a matching organization could not be found
407            */
408            public static Organization findByUuid_C_Last(java.lang.String uuid,
409                    long companyId, OrderByComparator<Organization> orderByComparator)
410                    throws com.liferay.portal.NoSuchOrganizationException {
411                    return getPersistence()
412                                       .findByUuid_C_Last(uuid, companyId, orderByComparator);
413            }
414    
415            /**
416            * Returns the last organization in the ordered set where uuid = &#63; and companyId = &#63;.
417            *
418            * @param uuid the uuid
419            * @param companyId the company ID
420            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
421            * @return the last matching organization, or <code>null</code> if a matching organization could not be found
422            */
423            public static Organization fetchByUuid_C_Last(java.lang.String uuid,
424                    long companyId, OrderByComparator<Organization> orderByComparator) {
425                    return getPersistence()
426                                       .fetchByUuid_C_Last(uuid, companyId, orderByComparator);
427            }
428    
429            /**
430            * Returns the organizations before and after the current organization in the ordered set where uuid = &#63; and companyId = &#63;.
431            *
432            * @param organizationId the primary key of the current organization
433            * @param uuid the uuid
434            * @param companyId the company ID
435            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
436            * @return the previous, current, and next organization
437            * @throws NoSuchOrganizationException if a organization with the primary key could not be found
438            */
439            public static Organization[] findByUuid_C_PrevAndNext(long organizationId,
440                    java.lang.String uuid, long companyId,
441                    OrderByComparator<Organization> orderByComparator)
442                    throws com.liferay.portal.NoSuchOrganizationException {
443                    return getPersistence()
444                                       .findByUuid_C_PrevAndNext(organizationId, uuid, companyId,
445                            orderByComparator);
446            }
447    
448            /**
449            * Returns all the organizations that the user has permission to view where uuid = &#63; and companyId = &#63;.
450            *
451            * @param uuid the uuid
452            * @param companyId the company ID
453            * @return the matching organizations that the user has permission to view
454            */
455            public static List<Organization> filterFindByUuid_C(java.lang.String uuid,
456                    long companyId) {
457                    return getPersistence().filterFindByUuid_C(uuid, companyId);
458            }
459    
460            /**
461            * Returns a range of all the organizations that the user has permission to view where uuid = &#63; and companyId = &#63;.
462            *
463            * <p>
464            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link OrganizationModelImpl}. 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.
465            * </p>
466            *
467            * @param uuid the uuid
468            * @param companyId the company ID
469            * @param start the lower bound of the range of organizations
470            * @param end the upper bound of the range of organizations (not inclusive)
471            * @return the range of matching organizations that the user has permission to view
472            */
473            public static List<Organization> filterFindByUuid_C(java.lang.String uuid,
474                    long companyId, int start, int end) {
475                    return getPersistence().filterFindByUuid_C(uuid, companyId, start, end);
476            }
477    
478            /**
479            * Returns an ordered range of all the organizations that the user has permissions to view where uuid = &#63; and companyId = &#63;.
480            *
481            * <p>
482            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link OrganizationModelImpl}. 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.
483            * </p>
484            *
485            * @param uuid the uuid
486            * @param companyId the company ID
487            * @param start the lower bound of the range of organizations
488            * @param end the upper bound of the range of organizations (not inclusive)
489            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
490            * @return the ordered range of matching organizations that the user has permission to view
491            */
492            public static List<Organization> filterFindByUuid_C(java.lang.String uuid,
493                    long companyId, int start, int end,
494                    OrderByComparator<Organization> orderByComparator) {
495                    return getPersistence()
496                                       .filterFindByUuid_C(uuid, companyId, start, end,
497                            orderByComparator);
498            }
499    
500            /**
501            * Returns the organizations before and after the current organization in the ordered set of organizations that the user has permission to view where uuid = &#63; and companyId = &#63;.
502            *
503            * @param organizationId the primary key of the current organization
504            * @param uuid the uuid
505            * @param companyId the company ID
506            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
507            * @return the previous, current, and next organization
508            * @throws NoSuchOrganizationException if a organization with the primary key could not be found
509            */
510            public static Organization[] filterFindByUuid_C_PrevAndNext(
511                    long organizationId, java.lang.String uuid, long companyId,
512                    OrderByComparator<Organization> orderByComparator)
513                    throws com.liferay.portal.NoSuchOrganizationException {
514                    return getPersistence()
515                                       .filterFindByUuid_C_PrevAndNext(organizationId, uuid,
516                            companyId, orderByComparator);
517            }
518    
519            /**
520            * Removes all the organizations where uuid = &#63; and companyId = &#63; from the database.
521            *
522            * @param uuid the uuid
523            * @param companyId the company ID
524            */
525            public static void removeByUuid_C(java.lang.String uuid, long companyId) {
526                    getPersistence().removeByUuid_C(uuid, companyId);
527            }
528    
529            /**
530            * Returns the number of organizations where uuid = &#63; and companyId = &#63;.
531            *
532            * @param uuid the uuid
533            * @param companyId the company ID
534            * @return the number of matching organizations
535            */
536            public static int countByUuid_C(java.lang.String uuid, long companyId) {
537                    return getPersistence().countByUuid_C(uuid, companyId);
538            }
539    
540            /**
541            * Returns the number of organizations that the user has permission to view where uuid = &#63; and companyId = &#63;.
542            *
543            * @param uuid the uuid
544            * @param companyId the company ID
545            * @return the number of matching organizations that the user has permission to view
546            */
547            public static int filterCountByUuid_C(java.lang.String uuid, long companyId) {
548                    return getPersistence().filterCountByUuid_C(uuid, companyId);
549            }
550    
551            /**
552            * Returns all the organizations where companyId = &#63;.
553            *
554            * @param companyId the company ID
555            * @return the matching organizations
556            */
557            public static List<Organization> findByCompanyId(long companyId) {
558                    return getPersistence().findByCompanyId(companyId);
559            }
560    
561            /**
562            * Returns a range of all the organizations where companyId = &#63;.
563            *
564            * <p>
565            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link OrganizationModelImpl}. 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.
566            * </p>
567            *
568            * @param companyId the company ID
569            * @param start the lower bound of the range of organizations
570            * @param end the upper bound of the range of organizations (not inclusive)
571            * @return the range of matching organizations
572            */
573            public static List<Organization> findByCompanyId(long companyId, int start,
574                    int end) {
575                    return getPersistence().findByCompanyId(companyId, start, end);
576            }
577    
578            /**
579            * Returns an ordered range of all the organizations where companyId = &#63;.
580            *
581            * <p>
582            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link OrganizationModelImpl}. 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.
583            * </p>
584            *
585            * @param companyId the company ID
586            * @param start the lower bound of the range of organizations
587            * @param end the upper bound of the range of organizations (not inclusive)
588            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
589            * @return the ordered range of matching organizations
590            */
591            public static List<Organization> findByCompanyId(long companyId, int start,
592                    int end, OrderByComparator<Organization> orderByComparator) {
593                    return getPersistence()
594                                       .findByCompanyId(companyId, start, end, orderByComparator);
595            }
596    
597            /**
598            * Returns the first organization in the ordered set where companyId = &#63;.
599            *
600            * @param companyId the company ID
601            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
602            * @return the first matching organization
603            * @throws NoSuchOrganizationException if a matching organization could not be found
604            */
605            public static Organization findByCompanyId_First(long companyId,
606                    OrderByComparator<Organization> orderByComparator)
607                    throws com.liferay.portal.NoSuchOrganizationException {
608                    return getPersistence()
609                                       .findByCompanyId_First(companyId, orderByComparator);
610            }
611    
612            /**
613            * Returns the first organization in the ordered set where companyId = &#63;.
614            *
615            * @param companyId the company ID
616            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
617            * @return the first matching organization, or <code>null</code> if a matching organization could not be found
618            */
619            public static Organization fetchByCompanyId_First(long companyId,
620                    OrderByComparator<Organization> orderByComparator) {
621                    return getPersistence()
622                                       .fetchByCompanyId_First(companyId, orderByComparator);
623            }
624    
625            /**
626            * Returns the last organization in the ordered set where companyId = &#63;.
627            *
628            * @param companyId the company ID
629            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
630            * @return the last matching organization
631            * @throws NoSuchOrganizationException if a matching organization could not be found
632            */
633            public static Organization findByCompanyId_Last(long companyId,
634                    OrderByComparator<Organization> orderByComparator)
635                    throws com.liferay.portal.NoSuchOrganizationException {
636                    return getPersistence()
637                                       .findByCompanyId_Last(companyId, orderByComparator);
638            }
639    
640            /**
641            * Returns the last organization in the ordered set where companyId = &#63;.
642            *
643            * @param companyId the company ID
644            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
645            * @return the last matching organization, or <code>null</code> if a matching organization could not be found
646            */
647            public static Organization fetchByCompanyId_Last(long companyId,
648                    OrderByComparator<Organization> orderByComparator) {
649                    return getPersistence()
650                                       .fetchByCompanyId_Last(companyId, orderByComparator);
651            }
652    
653            /**
654            * Returns the organizations before and after the current organization in the ordered set where companyId = &#63;.
655            *
656            * @param organizationId the primary key of the current organization
657            * @param companyId the company ID
658            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
659            * @return the previous, current, and next organization
660            * @throws NoSuchOrganizationException if a organization with the primary key could not be found
661            */
662            public static Organization[] findByCompanyId_PrevAndNext(
663                    long organizationId, long companyId,
664                    OrderByComparator<Organization> orderByComparator)
665                    throws com.liferay.portal.NoSuchOrganizationException {
666                    return getPersistence()
667                                       .findByCompanyId_PrevAndNext(organizationId, companyId,
668                            orderByComparator);
669            }
670    
671            /**
672            * Returns all the organizations that the user has permission to view where companyId = &#63;.
673            *
674            * @param companyId the company ID
675            * @return the matching organizations that the user has permission to view
676            */
677            public static List<Organization> filterFindByCompanyId(long companyId) {
678                    return getPersistence().filterFindByCompanyId(companyId);
679            }
680    
681            /**
682            * Returns a range of all the organizations that the user has permission to view where companyId = &#63;.
683            *
684            * <p>
685            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link OrganizationModelImpl}. 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.
686            * </p>
687            *
688            * @param companyId the company ID
689            * @param start the lower bound of the range of organizations
690            * @param end the upper bound of the range of organizations (not inclusive)
691            * @return the range of matching organizations that the user has permission to view
692            */
693            public static List<Organization> filterFindByCompanyId(long companyId,
694                    int start, int end) {
695                    return getPersistence().filterFindByCompanyId(companyId, start, end);
696            }
697    
698            /**
699            * Returns an ordered range of all the organizations that the user has permissions to view where companyId = &#63;.
700            *
701            * <p>
702            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link OrganizationModelImpl}. 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.
703            * </p>
704            *
705            * @param companyId the company ID
706            * @param start the lower bound of the range of organizations
707            * @param end the upper bound of the range of organizations (not inclusive)
708            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
709            * @return the ordered range of matching organizations that the user has permission to view
710            */
711            public static List<Organization> filterFindByCompanyId(long companyId,
712                    int start, int end, OrderByComparator<Organization> orderByComparator) {
713                    return getPersistence()
714                                       .filterFindByCompanyId(companyId, start, end,
715                            orderByComparator);
716            }
717    
718            /**
719            * Returns the organizations before and after the current organization in the ordered set of organizations that the user has permission to view where companyId = &#63;.
720            *
721            * @param organizationId the primary key of the current organization
722            * @param companyId the company ID
723            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
724            * @return the previous, current, and next organization
725            * @throws NoSuchOrganizationException if a organization with the primary key could not be found
726            */
727            public static Organization[] filterFindByCompanyId_PrevAndNext(
728                    long organizationId, long companyId,
729                    OrderByComparator<Organization> orderByComparator)
730                    throws com.liferay.portal.NoSuchOrganizationException {
731                    return getPersistence()
732                                       .filterFindByCompanyId_PrevAndNext(organizationId,
733                            companyId, orderByComparator);
734            }
735    
736            /**
737            * Removes all the organizations where companyId = &#63; from the database.
738            *
739            * @param companyId the company ID
740            */
741            public static void removeByCompanyId(long companyId) {
742                    getPersistence().removeByCompanyId(companyId);
743            }
744    
745            /**
746            * Returns the number of organizations where companyId = &#63;.
747            *
748            * @param companyId the company ID
749            * @return the number of matching organizations
750            */
751            public static int countByCompanyId(long companyId) {
752                    return getPersistence().countByCompanyId(companyId);
753            }
754    
755            /**
756            * Returns the number of organizations that the user has permission to view where companyId = &#63;.
757            *
758            * @param companyId the company ID
759            * @return the number of matching organizations that the user has permission to view
760            */
761            public static int filterCountByCompanyId(long companyId) {
762                    return getPersistence().filterCountByCompanyId(companyId);
763            }
764    
765            /**
766            * Returns all the organizations where companyId = &#63;.
767            *
768            * @param companyId the company ID
769            * @return the matching organizations
770            */
771            public static List<Organization> findByLocations(long companyId) {
772                    return getPersistence().findByLocations(companyId);
773            }
774    
775            /**
776            * Returns a range of all the organizations where companyId = &#63;.
777            *
778            * <p>
779            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link OrganizationModelImpl}. 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.
780            * </p>
781            *
782            * @param companyId the company ID
783            * @param start the lower bound of the range of organizations
784            * @param end the upper bound of the range of organizations (not inclusive)
785            * @return the range of matching organizations
786            */
787            public static List<Organization> findByLocations(long companyId, int start,
788                    int end) {
789                    return getPersistence().findByLocations(companyId, start, end);
790            }
791    
792            /**
793            * Returns an ordered range of all the organizations where companyId = &#63;.
794            *
795            * <p>
796            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link OrganizationModelImpl}. 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.
797            * </p>
798            *
799            * @param companyId the company ID
800            * @param start the lower bound of the range of organizations
801            * @param end the upper bound of the range of organizations (not inclusive)
802            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
803            * @return the ordered range of matching organizations
804            */
805            public static List<Organization> findByLocations(long companyId, int start,
806                    int end, OrderByComparator<Organization> orderByComparator) {
807                    return getPersistence()
808                                       .findByLocations(companyId, start, end, orderByComparator);
809            }
810    
811            /**
812            * Returns the first organization in the ordered set where companyId = &#63;.
813            *
814            * @param companyId the company ID
815            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
816            * @return the first matching organization
817            * @throws NoSuchOrganizationException if a matching organization could not be found
818            */
819            public static Organization findByLocations_First(long companyId,
820                    OrderByComparator<Organization> orderByComparator)
821                    throws com.liferay.portal.NoSuchOrganizationException {
822                    return getPersistence()
823                                       .findByLocations_First(companyId, orderByComparator);
824            }
825    
826            /**
827            * Returns the first organization in the ordered set where companyId = &#63;.
828            *
829            * @param companyId the company ID
830            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
831            * @return the first matching organization, or <code>null</code> if a matching organization could not be found
832            */
833            public static Organization fetchByLocations_First(long companyId,
834                    OrderByComparator<Organization> orderByComparator) {
835                    return getPersistence()
836                                       .fetchByLocations_First(companyId, orderByComparator);
837            }
838    
839            /**
840            * Returns the last organization in the ordered set where companyId = &#63;.
841            *
842            * @param companyId the company ID
843            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
844            * @return the last matching organization
845            * @throws NoSuchOrganizationException if a matching organization could not be found
846            */
847            public static Organization findByLocations_Last(long companyId,
848                    OrderByComparator<Organization> orderByComparator)
849                    throws com.liferay.portal.NoSuchOrganizationException {
850                    return getPersistence()
851                                       .findByLocations_Last(companyId, orderByComparator);
852            }
853    
854            /**
855            * Returns the last organization in the ordered set where companyId = &#63;.
856            *
857            * @param companyId the company ID
858            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
859            * @return the last matching organization, or <code>null</code> if a matching organization could not be found
860            */
861            public static Organization fetchByLocations_Last(long companyId,
862                    OrderByComparator<Organization> orderByComparator) {
863                    return getPersistence()
864                                       .fetchByLocations_Last(companyId, orderByComparator);
865            }
866    
867            /**
868            * Returns the organizations before and after the current organization in the ordered set where companyId = &#63;.
869            *
870            * @param organizationId the primary key of the current organization
871            * @param companyId the company ID
872            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
873            * @return the previous, current, and next organization
874            * @throws NoSuchOrganizationException if a organization with the primary key could not be found
875            */
876            public static Organization[] findByLocations_PrevAndNext(
877                    long organizationId, long companyId,
878                    OrderByComparator<Organization> orderByComparator)
879                    throws com.liferay.portal.NoSuchOrganizationException {
880                    return getPersistence()
881                                       .findByLocations_PrevAndNext(organizationId, companyId,
882                            orderByComparator);
883            }
884    
885            /**
886            * Returns all the organizations that the user has permission to view where companyId = &#63;.
887            *
888            * @param companyId the company ID
889            * @return the matching organizations that the user has permission to view
890            */
891            public static List<Organization> filterFindByLocations(long companyId) {
892                    return getPersistence().filterFindByLocations(companyId);
893            }
894    
895            /**
896            * Returns a range of all the organizations that the user has permission to view where companyId = &#63;.
897            *
898            * <p>
899            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link OrganizationModelImpl}. 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.
900            * </p>
901            *
902            * @param companyId the company ID
903            * @param start the lower bound of the range of organizations
904            * @param end the upper bound of the range of organizations (not inclusive)
905            * @return the range of matching organizations that the user has permission to view
906            */
907            public static List<Organization> filterFindByLocations(long companyId,
908                    int start, int end) {
909                    return getPersistence().filterFindByLocations(companyId, start, end);
910            }
911    
912            /**
913            * Returns an ordered range of all the organizations that the user has permissions to view where companyId = &#63;.
914            *
915            * <p>
916            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link OrganizationModelImpl}. 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.
917            * </p>
918            *
919            * @param companyId the company ID
920            * @param start the lower bound of the range of organizations
921            * @param end the upper bound of the range of organizations (not inclusive)
922            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
923            * @return the ordered range of matching organizations that the user has permission to view
924            */
925            public static List<Organization> filterFindByLocations(long companyId,
926                    int start, int end, OrderByComparator<Organization> orderByComparator) {
927                    return getPersistence()
928                                       .filterFindByLocations(companyId, start, end,
929                            orderByComparator);
930            }
931    
932            /**
933            * Returns the organizations before and after the current organization in the ordered set of organizations that the user has permission to view where companyId = &#63;.
934            *
935            * @param organizationId the primary key of the current organization
936            * @param companyId the company ID
937            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
938            * @return the previous, current, and next organization
939            * @throws NoSuchOrganizationException if a organization with the primary key could not be found
940            */
941            public static Organization[] filterFindByLocations_PrevAndNext(
942                    long organizationId, long companyId,
943                    OrderByComparator<Organization> orderByComparator)
944                    throws com.liferay.portal.NoSuchOrganizationException {
945                    return getPersistence()
946                                       .filterFindByLocations_PrevAndNext(organizationId,
947                            companyId, orderByComparator);
948            }
949    
950            /**
951            * Removes all the organizations where companyId = &#63; from the database.
952            *
953            * @param companyId the company ID
954            */
955            public static void removeByLocations(long companyId) {
956                    getPersistence().removeByLocations(companyId);
957            }
958    
959            /**
960            * Returns the number of organizations where companyId = &#63;.
961            *
962            * @param companyId the company ID
963            * @return the number of matching organizations
964            */
965            public static int countByLocations(long companyId) {
966                    return getPersistence().countByLocations(companyId);
967            }
968    
969            /**
970            * Returns the number of organizations that the user has permission to view where companyId = &#63;.
971            *
972            * @param companyId the company ID
973            * @return the number of matching organizations that the user has permission to view
974            */
975            public static int filterCountByLocations(long companyId) {
976                    return getPersistence().filterCountByLocations(companyId);
977            }
978    
979            /**
980            * Returns all the organizations where companyId = &#63; and parentOrganizationId = &#63;.
981            *
982            * @param companyId the company ID
983            * @param parentOrganizationId the parent organization ID
984            * @return the matching organizations
985            */
986            public static List<Organization> findByC_P(long companyId,
987                    long parentOrganizationId) {
988                    return getPersistence().findByC_P(companyId, parentOrganizationId);
989            }
990    
991            /**
992            * Returns a range of all the organizations where companyId = &#63; and parentOrganizationId = &#63;.
993            *
994            * <p>
995            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link OrganizationModelImpl}. 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.
996            * </p>
997            *
998            * @param companyId the company ID
999            * @param parentOrganizationId the parent organization ID
1000            * @param start the lower bound of the range of organizations
1001            * @param end the upper bound of the range of organizations (not inclusive)
1002            * @return the range of matching organizations
1003            */
1004            public static List<Organization> findByC_P(long companyId,
1005                    long parentOrganizationId, int start, int end) {
1006                    return getPersistence()
1007                                       .findByC_P(companyId, parentOrganizationId, start, end);
1008            }
1009    
1010            /**
1011            * Returns an ordered range of all the organizations where companyId = &#63; and parentOrganizationId = &#63;.
1012            *
1013            * <p>
1014            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link OrganizationModelImpl}. 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.
1015            * </p>
1016            *
1017            * @param companyId the company ID
1018            * @param parentOrganizationId the parent organization ID
1019            * @param start the lower bound of the range of organizations
1020            * @param end the upper bound of the range of organizations (not inclusive)
1021            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1022            * @return the ordered range of matching organizations
1023            */
1024            public static List<Organization> findByC_P(long companyId,
1025                    long parentOrganizationId, int start, int end,
1026                    OrderByComparator<Organization> orderByComparator) {
1027                    return getPersistence()
1028                                       .findByC_P(companyId, parentOrganizationId, start, end,
1029                            orderByComparator);
1030            }
1031    
1032            /**
1033            * Returns the first organization in the ordered set where companyId = &#63; and parentOrganizationId = &#63;.
1034            *
1035            * @param companyId the company ID
1036            * @param parentOrganizationId the parent organization ID
1037            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1038            * @return the first matching organization
1039            * @throws NoSuchOrganizationException if a matching organization could not be found
1040            */
1041            public static Organization findByC_P_First(long companyId,
1042                    long parentOrganizationId,
1043                    OrderByComparator<Organization> orderByComparator)
1044                    throws com.liferay.portal.NoSuchOrganizationException {
1045                    return getPersistence()
1046                                       .findByC_P_First(companyId, parentOrganizationId,
1047                            orderByComparator);
1048            }
1049    
1050            /**
1051            * Returns the first organization in the ordered set where companyId = &#63; and parentOrganizationId = &#63;.
1052            *
1053            * @param companyId the company ID
1054            * @param parentOrganizationId the parent organization ID
1055            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1056            * @return the first matching organization, or <code>null</code> if a matching organization could not be found
1057            */
1058            public static Organization fetchByC_P_First(long companyId,
1059                    long parentOrganizationId,
1060                    OrderByComparator<Organization> orderByComparator) {
1061                    return getPersistence()
1062                                       .fetchByC_P_First(companyId, parentOrganizationId,
1063                            orderByComparator);
1064            }
1065    
1066            /**
1067            * Returns the last organization in the ordered set where companyId = &#63; and parentOrganizationId = &#63;.
1068            *
1069            * @param companyId the company ID
1070            * @param parentOrganizationId the parent organization ID
1071            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1072            * @return the last matching organization
1073            * @throws NoSuchOrganizationException if a matching organization could not be found
1074            */
1075            public static Organization findByC_P_Last(long companyId,
1076                    long parentOrganizationId,
1077                    OrderByComparator<Organization> orderByComparator)
1078                    throws com.liferay.portal.NoSuchOrganizationException {
1079                    return getPersistence()
1080                                       .findByC_P_Last(companyId, parentOrganizationId,
1081                            orderByComparator);
1082            }
1083    
1084            /**
1085            * Returns the last organization in the ordered set where companyId = &#63; and parentOrganizationId = &#63;.
1086            *
1087            * @param companyId the company ID
1088            * @param parentOrganizationId the parent organization ID
1089            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1090            * @return the last matching organization, or <code>null</code> if a matching organization could not be found
1091            */
1092            public static Organization fetchByC_P_Last(long companyId,
1093                    long parentOrganizationId,
1094                    OrderByComparator<Organization> orderByComparator) {
1095                    return getPersistence()
1096                                       .fetchByC_P_Last(companyId, parentOrganizationId,
1097                            orderByComparator);
1098            }
1099    
1100            /**
1101            * Returns the organizations before and after the current organization in the ordered set where companyId = &#63; and parentOrganizationId = &#63;.
1102            *
1103            * @param organizationId the primary key of the current organization
1104            * @param companyId the company ID
1105            * @param parentOrganizationId the parent organization ID
1106            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1107            * @return the previous, current, and next organization
1108            * @throws NoSuchOrganizationException if a organization with the primary key could not be found
1109            */
1110            public static Organization[] findByC_P_PrevAndNext(long organizationId,
1111                    long companyId, long parentOrganizationId,
1112                    OrderByComparator<Organization> orderByComparator)
1113                    throws com.liferay.portal.NoSuchOrganizationException {
1114                    return getPersistence()
1115                                       .findByC_P_PrevAndNext(organizationId, companyId,
1116                            parentOrganizationId, orderByComparator);
1117            }
1118    
1119            /**
1120            * Returns all the organizations that the user has permission to view where companyId = &#63; and parentOrganizationId = &#63;.
1121            *
1122            * @param companyId the company ID
1123            * @param parentOrganizationId the parent organization ID
1124            * @return the matching organizations that the user has permission to view
1125            */
1126            public static List<Organization> filterFindByC_P(long companyId,
1127                    long parentOrganizationId) {
1128                    return getPersistence().filterFindByC_P(companyId, parentOrganizationId);
1129            }
1130    
1131            /**
1132            * Returns a range of all the organizations that the user has permission to view where companyId = &#63; and parentOrganizationId = &#63;.
1133            *
1134            * <p>
1135            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link OrganizationModelImpl}. 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.
1136            * </p>
1137            *
1138            * @param companyId the company ID
1139            * @param parentOrganizationId the parent organization ID
1140            * @param start the lower bound of the range of organizations
1141            * @param end the upper bound of the range of organizations (not inclusive)
1142            * @return the range of matching organizations that the user has permission to view
1143            */
1144            public static List<Organization> filterFindByC_P(long companyId,
1145                    long parentOrganizationId, int start, int end) {
1146                    return getPersistence()
1147                                       .filterFindByC_P(companyId, parentOrganizationId, start, end);
1148            }
1149    
1150            /**
1151            * Returns an ordered range of all the organizations that the user has permissions to view where companyId = &#63; and parentOrganizationId = &#63;.
1152            *
1153            * <p>
1154            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link OrganizationModelImpl}. 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.
1155            * </p>
1156            *
1157            * @param companyId the company ID
1158            * @param parentOrganizationId the parent organization ID
1159            * @param start the lower bound of the range of organizations
1160            * @param end the upper bound of the range of organizations (not inclusive)
1161            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1162            * @return the ordered range of matching organizations that the user has permission to view
1163            */
1164            public static List<Organization> filterFindByC_P(long companyId,
1165                    long parentOrganizationId, int start, int end,
1166                    OrderByComparator<Organization> orderByComparator) {
1167                    return getPersistence()
1168                                       .filterFindByC_P(companyId, parentOrganizationId, start,
1169                            end, orderByComparator);
1170            }
1171    
1172            /**
1173            * Returns the organizations before and after the current organization in the ordered set of organizations that the user has permission to view where companyId = &#63; and parentOrganizationId = &#63;.
1174            *
1175            * @param organizationId the primary key of the current organization
1176            * @param companyId the company ID
1177            * @param parentOrganizationId the parent organization ID
1178            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1179            * @return the previous, current, and next organization
1180            * @throws NoSuchOrganizationException if a organization with the primary key could not be found
1181            */
1182            public static Organization[] filterFindByC_P_PrevAndNext(
1183                    long organizationId, long companyId, long parentOrganizationId,
1184                    OrderByComparator<Organization> orderByComparator)
1185                    throws com.liferay.portal.NoSuchOrganizationException {
1186                    return getPersistence()
1187                                       .filterFindByC_P_PrevAndNext(organizationId, companyId,
1188                            parentOrganizationId, orderByComparator);
1189            }
1190    
1191            /**
1192            * Removes all the organizations where companyId = &#63; and parentOrganizationId = &#63; from the database.
1193            *
1194            * @param companyId the company ID
1195            * @param parentOrganizationId the parent organization ID
1196            */
1197            public static void removeByC_P(long companyId, long parentOrganizationId) {
1198                    getPersistence().removeByC_P(companyId, parentOrganizationId);
1199            }
1200    
1201            /**
1202            * Returns the number of organizations where companyId = &#63; and parentOrganizationId = &#63;.
1203            *
1204            * @param companyId the company ID
1205            * @param parentOrganizationId the parent organization ID
1206            * @return the number of matching organizations
1207            */
1208            public static int countByC_P(long companyId, long parentOrganizationId) {
1209                    return getPersistence().countByC_P(companyId, parentOrganizationId);
1210            }
1211    
1212            /**
1213            * Returns the number of organizations that the user has permission to view where companyId = &#63; and parentOrganizationId = &#63;.
1214            *
1215            * @param companyId the company ID
1216            * @param parentOrganizationId the parent organization ID
1217            * @return the number of matching organizations that the user has permission to view
1218            */
1219            public static int filterCountByC_P(long companyId, long parentOrganizationId) {
1220                    return getPersistence().filterCountByC_P(companyId, parentOrganizationId);
1221            }
1222    
1223            /**
1224            * Returns all the organizations where companyId = &#63; and treePath LIKE &#63;.
1225            *
1226            * @param companyId the company ID
1227            * @param treePath the tree path
1228            * @return the matching organizations
1229            */
1230            public static List<Organization> findByC_T(long companyId,
1231                    java.lang.String treePath) {
1232                    return getPersistence().findByC_T(companyId, treePath);
1233            }
1234    
1235            /**
1236            * Returns a range of all the organizations where companyId = &#63; and treePath LIKE &#63;.
1237            *
1238            * <p>
1239            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link OrganizationModelImpl}. 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.
1240            * </p>
1241            *
1242            * @param companyId the company ID
1243            * @param treePath the tree path
1244            * @param start the lower bound of the range of organizations
1245            * @param end the upper bound of the range of organizations (not inclusive)
1246            * @return the range of matching organizations
1247            */
1248            public static List<Organization> findByC_T(long companyId,
1249                    java.lang.String treePath, int start, int end) {
1250                    return getPersistence().findByC_T(companyId, treePath, start, end);
1251            }
1252    
1253            /**
1254            * Returns an ordered range of all the organizations where companyId = &#63; and treePath LIKE &#63;.
1255            *
1256            * <p>
1257            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link OrganizationModelImpl}. 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.
1258            * </p>
1259            *
1260            * @param companyId the company ID
1261            * @param treePath the tree path
1262            * @param start the lower bound of the range of organizations
1263            * @param end the upper bound of the range of organizations (not inclusive)
1264            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1265            * @return the ordered range of matching organizations
1266            */
1267            public static List<Organization> findByC_T(long companyId,
1268                    java.lang.String treePath, int start, int end,
1269                    OrderByComparator<Organization> orderByComparator) {
1270                    return getPersistence()
1271                                       .findByC_T(companyId, treePath, start, end, orderByComparator);
1272            }
1273    
1274            /**
1275            * Returns the first organization in the ordered set where companyId = &#63; and treePath LIKE &#63;.
1276            *
1277            * @param companyId the company ID
1278            * @param treePath the tree path
1279            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1280            * @return the first matching organization
1281            * @throws NoSuchOrganizationException if a matching organization could not be found
1282            */
1283            public static Organization findByC_T_First(long companyId,
1284                    java.lang.String treePath,
1285                    OrderByComparator<Organization> orderByComparator)
1286                    throws com.liferay.portal.NoSuchOrganizationException {
1287                    return getPersistence()
1288                                       .findByC_T_First(companyId, treePath, orderByComparator);
1289            }
1290    
1291            /**
1292            * Returns the first organization in the ordered set where companyId = &#63; and treePath LIKE &#63;.
1293            *
1294            * @param companyId the company ID
1295            * @param treePath the tree path
1296            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1297            * @return the first matching organization, or <code>null</code> if a matching organization could not be found
1298            */
1299            public static Organization fetchByC_T_First(long companyId,
1300                    java.lang.String treePath,
1301                    OrderByComparator<Organization> orderByComparator) {
1302                    return getPersistence()
1303                                       .fetchByC_T_First(companyId, treePath, orderByComparator);
1304            }
1305    
1306            /**
1307            * Returns the last organization in the ordered set where companyId = &#63; and treePath LIKE &#63;.
1308            *
1309            * @param companyId the company ID
1310            * @param treePath the tree path
1311            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1312            * @return the last matching organization
1313            * @throws NoSuchOrganizationException if a matching organization could not be found
1314            */
1315            public static Organization findByC_T_Last(long companyId,
1316                    java.lang.String treePath,
1317                    OrderByComparator<Organization> orderByComparator)
1318                    throws com.liferay.portal.NoSuchOrganizationException {
1319                    return getPersistence()
1320                                       .findByC_T_Last(companyId, treePath, orderByComparator);
1321            }
1322    
1323            /**
1324            * Returns the last organization in the ordered set where companyId = &#63; and treePath LIKE &#63;.
1325            *
1326            * @param companyId the company ID
1327            * @param treePath the tree path
1328            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1329            * @return the last matching organization, or <code>null</code> if a matching organization could not be found
1330            */
1331            public static Organization fetchByC_T_Last(long companyId,
1332                    java.lang.String treePath,
1333                    OrderByComparator<Organization> orderByComparator) {
1334                    return getPersistence()
1335                                       .fetchByC_T_Last(companyId, treePath, orderByComparator);
1336            }
1337    
1338            /**
1339            * Returns the organizations before and after the current organization in the ordered set where companyId = &#63; and treePath LIKE &#63;.
1340            *
1341            * @param organizationId the primary key of the current organization
1342            * @param companyId the company ID
1343            * @param treePath the tree path
1344            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1345            * @return the previous, current, and next organization
1346            * @throws NoSuchOrganizationException if a organization with the primary key could not be found
1347            */
1348            public static Organization[] findByC_T_PrevAndNext(long organizationId,
1349                    long companyId, java.lang.String treePath,
1350                    OrderByComparator<Organization> orderByComparator)
1351                    throws com.liferay.portal.NoSuchOrganizationException {
1352                    return getPersistence()
1353                                       .findByC_T_PrevAndNext(organizationId, companyId, treePath,
1354                            orderByComparator);
1355            }
1356    
1357            /**
1358            * Returns all the organizations that the user has permission to view where companyId = &#63; and treePath LIKE &#63;.
1359            *
1360            * @param companyId the company ID
1361            * @param treePath the tree path
1362            * @return the matching organizations that the user has permission to view
1363            */
1364            public static List<Organization> filterFindByC_T(long companyId,
1365                    java.lang.String treePath) {
1366                    return getPersistence().filterFindByC_T(companyId, treePath);
1367            }
1368    
1369            /**
1370            * Returns a range of all the organizations that the user has permission to view where companyId = &#63; and treePath LIKE &#63;.
1371            *
1372            * <p>
1373            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link OrganizationModelImpl}. 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.
1374            * </p>
1375            *
1376            * @param companyId the company ID
1377            * @param treePath the tree path
1378            * @param start the lower bound of the range of organizations
1379            * @param end the upper bound of the range of organizations (not inclusive)
1380            * @return the range of matching organizations that the user has permission to view
1381            */
1382            public static List<Organization> filterFindByC_T(long companyId,
1383                    java.lang.String treePath, int start, int end) {
1384                    return getPersistence().filterFindByC_T(companyId, treePath, start, end);
1385            }
1386    
1387            /**
1388            * Returns an ordered range of all the organizations that the user has permissions to view where companyId = &#63; and treePath LIKE &#63;.
1389            *
1390            * <p>
1391            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link OrganizationModelImpl}. 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.
1392            * </p>
1393            *
1394            * @param companyId the company ID
1395            * @param treePath the tree path
1396            * @param start the lower bound of the range of organizations
1397            * @param end the upper bound of the range of organizations (not inclusive)
1398            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1399            * @return the ordered range of matching organizations that the user has permission to view
1400            */
1401            public static List<Organization> filterFindByC_T(long companyId,
1402                    java.lang.String treePath, int start, int end,
1403                    OrderByComparator<Organization> orderByComparator) {
1404                    return getPersistence()
1405                                       .filterFindByC_T(companyId, treePath, start, end,
1406                            orderByComparator);
1407            }
1408    
1409            /**
1410            * Returns the organizations before and after the current organization in the ordered set of organizations that the user has permission to view where companyId = &#63; and treePath LIKE &#63;.
1411            *
1412            * @param organizationId the primary key of the current organization
1413            * @param companyId the company ID
1414            * @param treePath the tree path
1415            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1416            * @return the previous, current, and next organization
1417            * @throws NoSuchOrganizationException if a organization with the primary key could not be found
1418            */
1419            public static Organization[] filterFindByC_T_PrevAndNext(
1420                    long organizationId, long companyId, java.lang.String treePath,
1421                    OrderByComparator<Organization> orderByComparator)
1422                    throws com.liferay.portal.NoSuchOrganizationException {
1423                    return getPersistence()
1424                                       .filterFindByC_T_PrevAndNext(organizationId, companyId,
1425                            treePath, orderByComparator);
1426            }
1427    
1428            /**
1429            * Removes all the organizations where companyId = &#63; and treePath LIKE &#63; from the database.
1430            *
1431            * @param companyId the company ID
1432            * @param treePath the tree path
1433            */
1434            public static void removeByC_T(long companyId, java.lang.String treePath) {
1435                    getPersistence().removeByC_T(companyId, treePath);
1436            }
1437    
1438            /**
1439            * Returns the number of organizations where companyId = &#63; and treePath LIKE &#63;.
1440            *
1441            * @param companyId the company ID
1442            * @param treePath the tree path
1443            * @return the number of matching organizations
1444            */
1445            public static int countByC_T(long companyId, java.lang.String treePath) {
1446                    return getPersistence().countByC_T(companyId, treePath);
1447            }
1448    
1449            /**
1450            * Returns the number of organizations that the user has permission to view where companyId = &#63; and treePath LIKE &#63;.
1451            *
1452            * @param companyId the company ID
1453            * @param treePath the tree path
1454            * @return the number of matching organizations that the user has permission to view
1455            */
1456            public static int filterCountByC_T(long companyId, java.lang.String treePath) {
1457                    return getPersistence().filterCountByC_T(companyId, treePath);
1458            }
1459    
1460            /**
1461            * Returns the organization where companyId = &#63; and name = &#63; or throws a {@link NoSuchOrganizationException} if it could not be found.
1462            *
1463            * @param companyId the company ID
1464            * @param name the name
1465            * @return the matching organization
1466            * @throws NoSuchOrganizationException if a matching organization could not be found
1467            */
1468            public static Organization findByC_N(long companyId, java.lang.String name)
1469                    throws com.liferay.portal.NoSuchOrganizationException {
1470                    return getPersistence().findByC_N(companyId, name);
1471            }
1472    
1473            /**
1474            * Returns the organization where companyId = &#63; and name = &#63; or returns <code>null</code> if it could not be found. Uses the finder cache.
1475            *
1476            * @param companyId the company ID
1477            * @param name the name
1478            * @return the matching organization, or <code>null</code> if a matching organization could not be found
1479            */
1480            public static Organization fetchByC_N(long companyId, java.lang.String name) {
1481                    return getPersistence().fetchByC_N(companyId, name);
1482            }
1483    
1484            /**
1485            * Returns the organization where companyId = &#63; and name = &#63; or returns <code>null</code> if it could not be found, optionally using the finder cache.
1486            *
1487            * @param companyId the company ID
1488            * @param name the name
1489            * @param retrieveFromCache whether to use the finder cache
1490            * @return the matching organization, or <code>null</code> if a matching organization could not be found
1491            */
1492            public static Organization fetchByC_N(long companyId,
1493                    java.lang.String name, boolean retrieveFromCache) {
1494                    return getPersistence().fetchByC_N(companyId, name, retrieveFromCache);
1495            }
1496    
1497            /**
1498            * Removes the organization where companyId = &#63; and name = &#63; from the database.
1499            *
1500            * @param companyId the company ID
1501            * @param name the name
1502            * @return the organization that was removed
1503            */
1504            public static Organization removeByC_N(long companyId, java.lang.String name)
1505                    throws com.liferay.portal.NoSuchOrganizationException {
1506                    return getPersistence().removeByC_N(companyId, name);
1507            }
1508    
1509            /**
1510            * Returns the number of organizations where companyId = &#63; and name = &#63;.
1511            *
1512            * @param companyId the company ID
1513            * @param name the name
1514            * @return the number of matching organizations
1515            */
1516            public static int countByC_N(long companyId, java.lang.String name) {
1517                    return getPersistence().countByC_N(companyId, name);
1518            }
1519    
1520            /**
1521            * Returns all the organizations where organizationId &gt; &#63; and companyId = &#63; and parentOrganizationId = &#63;.
1522            *
1523            * @param organizationId the organization ID
1524            * @param companyId the company ID
1525            * @param parentOrganizationId the parent organization ID
1526            * @return the matching organizations
1527            */
1528            public static List<Organization> findByO_C_P(long organizationId,
1529                    long companyId, long parentOrganizationId) {
1530                    return getPersistence()
1531                                       .findByO_C_P(organizationId, companyId, parentOrganizationId);
1532            }
1533    
1534            /**
1535            * Returns a range of all the organizations where organizationId &gt; &#63; and companyId = &#63; and parentOrganizationId = &#63;.
1536            *
1537            * <p>
1538            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link OrganizationModelImpl}. 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.
1539            * </p>
1540            *
1541            * @param organizationId the organization ID
1542            * @param companyId the company ID
1543            * @param parentOrganizationId the parent organization ID
1544            * @param start the lower bound of the range of organizations
1545            * @param end the upper bound of the range of organizations (not inclusive)
1546            * @return the range of matching organizations
1547            */
1548            public static List<Organization> findByO_C_P(long organizationId,
1549                    long companyId, long parentOrganizationId, int start, int end) {
1550                    return getPersistence()
1551                                       .findByO_C_P(organizationId, companyId,
1552                            parentOrganizationId, start, end);
1553            }
1554    
1555            /**
1556            * Returns an ordered range of all the organizations where organizationId &gt; &#63; and companyId = &#63; and parentOrganizationId = &#63;.
1557            *
1558            * <p>
1559            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link OrganizationModelImpl}. 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.
1560            * </p>
1561            *
1562            * @param organizationId the organization ID
1563            * @param companyId the company ID
1564            * @param parentOrganizationId the parent organization ID
1565            * @param start the lower bound of the range of organizations
1566            * @param end the upper bound of the range of organizations (not inclusive)
1567            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1568            * @return the ordered range of matching organizations
1569            */
1570            public static List<Organization> findByO_C_P(long organizationId,
1571                    long companyId, long parentOrganizationId, int start, int end,
1572                    OrderByComparator<Organization> orderByComparator) {
1573                    return getPersistence()
1574                                       .findByO_C_P(organizationId, companyId,
1575                            parentOrganizationId, start, end, orderByComparator);
1576            }
1577    
1578            /**
1579            * Returns the first organization in the ordered set where organizationId &gt; &#63; and companyId = &#63; and parentOrganizationId = &#63;.
1580            *
1581            * @param organizationId the organization ID
1582            * @param companyId the company ID
1583            * @param parentOrganizationId the parent organization ID
1584            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1585            * @return the first matching organization
1586            * @throws NoSuchOrganizationException if a matching organization could not be found
1587            */
1588            public static Organization findByO_C_P_First(long organizationId,
1589                    long companyId, long parentOrganizationId,
1590                    OrderByComparator<Organization> orderByComparator)
1591                    throws com.liferay.portal.NoSuchOrganizationException {
1592                    return getPersistence()
1593                                       .findByO_C_P_First(organizationId, companyId,
1594                            parentOrganizationId, orderByComparator);
1595            }
1596    
1597            /**
1598            * Returns the first organization in the ordered set where organizationId &gt; &#63; and companyId = &#63; and parentOrganizationId = &#63;.
1599            *
1600            * @param organizationId the organization ID
1601            * @param companyId the company ID
1602            * @param parentOrganizationId the parent organization ID
1603            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1604            * @return the first matching organization, or <code>null</code> if a matching organization could not be found
1605            */
1606            public static Organization fetchByO_C_P_First(long organizationId,
1607                    long companyId, long parentOrganizationId,
1608                    OrderByComparator<Organization> orderByComparator) {
1609                    return getPersistence()
1610                                       .fetchByO_C_P_First(organizationId, companyId,
1611                            parentOrganizationId, orderByComparator);
1612            }
1613    
1614            /**
1615            * Returns the last organization in the ordered set where organizationId &gt; &#63; and companyId = &#63; and parentOrganizationId = &#63;.
1616            *
1617            * @param organizationId the organization ID
1618            * @param companyId the company ID
1619            * @param parentOrganizationId the parent organization ID
1620            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1621            * @return the last matching organization
1622            * @throws NoSuchOrganizationException if a matching organization could not be found
1623            */
1624            public static Organization findByO_C_P_Last(long organizationId,
1625                    long companyId, long parentOrganizationId,
1626                    OrderByComparator<Organization> orderByComparator)
1627                    throws com.liferay.portal.NoSuchOrganizationException {
1628                    return getPersistence()
1629                                       .findByO_C_P_Last(organizationId, companyId,
1630                            parentOrganizationId, orderByComparator);
1631            }
1632    
1633            /**
1634            * Returns the last organization in the ordered set where organizationId &gt; &#63; and companyId = &#63; and parentOrganizationId = &#63;.
1635            *
1636            * @param organizationId the organization ID
1637            * @param companyId the company ID
1638            * @param parentOrganizationId the parent organization ID
1639            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1640            * @return the last matching organization, or <code>null</code> if a matching organization could not be found
1641            */
1642            public static Organization fetchByO_C_P_Last(long organizationId,
1643                    long companyId, long parentOrganizationId,
1644                    OrderByComparator<Organization> orderByComparator) {
1645                    return getPersistence()
1646                                       .fetchByO_C_P_Last(organizationId, companyId,
1647                            parentOrganizationId, orderByComparator);
1648            }
1649    
1650            /**
1651            * Returns all the organizations that the user has permission to view where organizationId &gt; &#63; and companyId = &#63; and parentOrganizationId = &#63;.
1652            *
1653            * @param organizationId the organization ID
1654            * @param companyId the company ID
1655            * @param parentOrganizationId the parent organization ID
1656            * @return the matching organizations that the user has permission to view
1657            */
1658            public static List<Organization> filterFindByO_C_P(long organizationId,
1659                    long companyId, long parentOrganizationId) {
1660                    return getPersistence()
1661                                       .filterFindByO_C_P(organizationId, companyId,
1662                            parentOrganizationId);
1663            }
1664    
1665            /**
1666            * Returns a range of all the organizations that the user has permission to view where organizationId &gt; &#63; and companyId = &#63; and parentOrganizationId = &#63;.
1667            *
1668            * <p>
1669            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link OrganizationModelImpl}. 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.
1670            * </p>
1671            *
1672            * @param organizationId the organization ID
1673            * @param companyId the company ID
1674            * @param parentOrganizationId the parent organization ID
1675            * @param start the lower bound of the range of organizations
1676            * @param end the upper bound of the range of organizations (not inclusive)
1677            * @return the range of matching organizations that the user has permission to view
1678            */
1679            public static List<Organization> filterFindByO_C_P(long organizationId,
1680                    long companyId, long parentOrganizationId, int start, int end) {
1681                    return getPersistence()
1682                                       .filterFindByO_C_P(organizationId, companyId,
1683                            parentOrganizationId, start, end);
1684            }
1685    
1686            /**
1687            * Returns an ordered range of all the organizations that the user has permissions to view where organizationId &gt; &#63; and companyId = &#63; and parentOrganizationId = &#63;.
1688            *
1689            * <p>
1690            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link OrganizationModelImpl}. 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.
1691            * </p>
1692            *
1693            * @param organizationId the organization ID
1694            * @param companyId the company ID
1695            * @param parentOrganizationId the parent organization ID
1696            * @param start the lower bound of the range of organizations
1697            * @param end the upper bound of the range of organizations (not inclusive)
1698            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1699            * @return the ordered range of matching organizations that the user has permission to view
1700            */
1701            public static List<Organization> filterFindByO_C_P(long organizationId,
1702                    long companyId, long parentOrganizationId, int start, int end,
1703                    OrderByComparator<Organization> orderByComparator) {
1704                    return getPersistence()
1705                                       .filterFindByO_C_P(organizationId, companyId,
1706                            parentOrganizationId, start, end, orderByComparator);
1707            }
1708    
1709            /**
1710            * Removes all the organizations where organizationId &gt; &#63; and companyId = &#63; and parentOrganizationId = &#63; from the database.
1711            *
1712            * @param organizationId the organization ID
1713            * @param companyId the company ID
1714            * @param parentOrganizationId the parent organization ID
1715            */
1716            public static void removeByO_C_P(long organizationId, long companyId,
1717                    long parentOrganizationId) {
1718                    getPersistence()
1719                            .removeByO_C_P(organizationId, companyId, parentOrganizationId);
1720            }
1721    
1722            /**
1723            * Returns the number of organizations where organizationId &gt; &#63; and companyId = &#63; and parentOrganizationId = &#63;.
1724            *
1725            * @param organizationId the organization ID
1726            * @param companyId the company ID
1727            * @param parentOrganizationId the parent organization ID
1728            * @return the number of matching organizations
1729            */
1730            public static int countByO_C_P(long organizationId, long companyId,
1731                    long parentOrganizationId) {
1732                    return getPersistence()
1733                                       .countByO_C_P(organizationId, companyId, parentOrganizationId);
1734            }
1735    
1736            /**
1737            * Returns the number of organizations that the user has permission to view where organizationId &gt; &#63; and companyId = &#63; and parentOrganizationId = &#63;.
1738            *
1739            * @param organizationId the organization ID
1740            * @param companyId the company ID
1741            * @param parentOrganizationId the parent organization ID
1742            * @return the number of matching organizations that the user has permission to view
1743            */
1744            public static int filterCountByO_C_P(long organizationId, long companyId,
1745                    long parentOrganizationId) {
1746                    return getPersistence()
1747                                       .filterCountByO_C_P(organizationId, companyId,
1748                            parentOrganizationId);
1749            }
1750    
1751            /**
1752            * Caches the organization in the entity cache if it is enabled.
1753            *
1754            * @param organization the organization
1755            */
1756            public static void cacheResult(Organization organization) {
1757                    getPersistence().cacheResult(organization);
1758            }
1759    
1760            /**
1761            * Caches the organizations in the entity cache if it is enabled.
1762            *
1763            * @param organizations the organizations
1764            */
1765            public static void cacheResult(List<Organization> organizations) {
1766                    getPersistence().cacheResult(organizations);
1767            }
1768    
1769            /**
1770            * Creates a new organization with the primary key. Does not add the organization to the database.
1771            *
1772            * @param organizationId the primary key for the new organization
1773            * @return the new organization
1774            */
1775            public static Organization create(long organizationId) {
1776                    return getPersistence().create(organizationId);
1777            }
1778    
1779            /**
1780            * Removes the organization with the primary key from the database. Also notifies the appropriate model listeners.
1781            *
1782            * @param organizationId the primary key of the organization
1783            * @return the organization that was removed
1784            * @throws NoSuchOrganizationException if a organization with the primary key could not be found
1785            */
1786            public static Organization remove(long organizationId)
1787                    throws com.liferay.portal.NoSuchOrganizationException {
1788                    return getPersistence().remove(organizationId);
1789            }
1790    
1791            public static Organization updateImpl(Organization organization) {
1792                    return getPersistence().updateImpl(organization);
1793            }
1794    
1795            /**
1796            * Returns the organization with the primary key or throws a {@link NoSuchOrganizationException} if it could not be found.
1797            *
1798            * @param organizationId the primary key of the organization
1799            * @return the organization
1800            * @throws NoSuchOrganizationException if a organization with the primary key could not be found
1801            */
1802            public static Organization findByPrimaryKey(long organizationId)
1803                    throws com.liferay.portal.NoSuchOrganizationException {
1804                    return getPersistence().findByPrimaryKey(organizationId);
1805            }
1806    
1807            /**
1808            * Returns the organization with the primary key or returns <code>null</code> if it could not be found.
1809            *
1810            * @param organizationId the primary key of the organization
1811            * @return the organization, or <code>null</code> if a organization with the primary key could not be found
1812            */
1813            public static Organization fetchByPrimaryKey(long organizationId) {
1814                    return getPersistence().fetchByPrimaryKey(organizationId);
1815            }
1816    
1817            public static java.util.Map<java.io.Serializable, Organization> fetchByPrimaryKeys(
1818                    java.util.Set<java.io.Serializable> primaryKeys) {
1819                    return getPersistence().fetchByPrimaryKeys(primaryKeys);
1820            }
1821    
1822            /**
1823            * Returns all the organizations.
1824            *
1825            * @return the organizations
1826            */
1827            public static List<Organization> findAll() {
1828                    return getPersistence().findAll();
1829            }
1830    
1831            /**
1832            * Returns a range of all the organizations.
1833            *
1834            * <p>
1835            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link OrganizationModelImpl}. 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.
1836            * </p>
1837            *
1838            * @param start the lower bound of the range of organizations
1839            * @param end the upper bound of the range of organizations (not inclusive)
1840            * @return the range of organizations
1841            */
1842            public static List<Organization> findAll(int start, int end) {
1843                    return getPersistence().findAll(start, end);
1844            }
1845    
1846            /**
1847            * Returns an ordered range of all the organizations.
1848            *
1849            * <p>
1850            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link OrganizationModelImpl}. 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.
1851            * </p>
1852            *
1853            * @param start the lower bound of the range of organizations
1854            * @param end the upper bound of the range of organizations (not inclusive)
1855            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1856            * @return the ordered range of organizations
1857            */
1858            public static List<Organization> findAll(int start, int end,
1859                    OrderByComparator<Organization> orderByComparator) {
1860                    return getPersistence().findAll(start, end, orderByComparator);
1861            }
1862    
1863            /**
1864            * Removes all the organizations from the database.
1865            */
1866            public static void removeAll() {
1867                    getPersistence().removeAll();
1868            }
1869    
1870            /**
1871            * Returns the number of organizations.
1872            *
1873            * @return the number of organizations
1874            */
1875            public static int countAll() {
1876                    return getPersistence().countAll();
1877            }
1878    
1879            /**
1880            * Returns the primaryKeys of groups associated with the organization.
1881            *
1882            * @param pk the primary key of the organization
1883            * @return long[] of the primaryKeys of groups associated with the organization
1884            */
1885            public static long[] getGroupPrimaryKeys(long pk) {
1886                    return getPersistence().getGroupPrimaryKeys(pk);
1887            }
1888    
1889            /**
1890            * Returns all the groups associated with the organization.
1891            *
1892            * @param pk the primary key of the organization
1893            * @return the groups associated with the organization
1894            */
1895            public static List<com.liferay.portal.model.Group> getGroups(long pk) {
1896                    return getPersistence().getGroups(pk);
1897            }
1898    
1899            /**
1900            * Returns a range of all the groups associated with the organization.
1901            *
1902            * <p>
1903            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link OrganizationModelImpl}. 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.
1904            * </p>
1905            *
1906            * @param pk the primary key of the organization
1907            * @param start the lower bound of the range of organizations
1908            * @param end the upper bound of the range of organizations (not inclusive)
1909            * @return the range of groups associated with the organization
1910            */
1911            public static List<com.liferay.portal.model.Group> getGroups(long pk,
1912                    int start, int end) {
1913                    return getPersistence().getGroups(pk, start, end);
1914            }
1915    
1916            /**
1917            * Returns an ordered range of all the groups associated with the organization.
1918            *
1919            * <p>
1920            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link OrganizationModelImpl}. 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.
1921            * </p>
1922            *
1923            * @param pk the primary key of the organization
1924            * @param start the lower bound of the range of organizations
1925            * @param end the upper bound of the range of organizations (not inclusive)
1926            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1927            * @return the ordered range of groups associated with the organization
1928            */
1929            public static List<com.liferay.portal.model.Group> getGroups(long pk,
1930                    int start, int end,
1931                    OrderByComparator<com.liferay.portal.model.Group> orderByComparator) {
1932                    return getPersistence().getGroups(pk, start, end, orderByComparator);
1933            }
1934    
1935            /**
1936            * Returns the number of groups associated with the organization.
1937            *
1938            * @param pk the primary key of the organization
1939            * @return the number of groups associated with the organization
1940            */
1941            public static int getGroupsSize(long pk) {
1942                    return getPersistence().getGroupsSize(pk);
1943            }
1944    
1945            /**
1946            * Returns <code>true</code> if the group is associated with the organization.
1947            *
1948            * @param pk the primary key of the organization
1949            * @param groupPK the primary key of the group
1950            * @return <code>true</code> if the group is associated with the organization; <code>false</code> otherwise
1951            */
1952            public static boolean containsGroup(long pk, long groupPK) {
1953                    return getPersistence().containsGroup(pk, groupPK);
1954            }
1955    
1956            /**
1957            * Returns <code>true</code> if the organization has any groups associated with it.
1958            *
1959            * @param pk the primary key of the organization to check for associations with groups
1960            * @return <code>true</code> if the organization has any groups associated with it; <code>false</code> otherwise
1961            */
1962            public static boolean containsGroups(long pk) {
1963                    return getPersistence().containsGroups(pk);
1964            }
1965    
1966            /**
1967            * Adds an association between the organization and the group. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1968            *
1969            * @param pk the primary key of the organization
1970            * @param groupPK the primary key of the group
1971            */
1972            public static void addGroup(long pk, long groupPK) {
1973                    getPersistence().addGroup(pk, groupPK);
1974            }
1975    
1976            /**
1977            * Adds an association between the organization and the group. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1978            *
1979            * @param pk the primary key of the organization
1980            * @param group the group
1981            */
1982            public static void addGroup(long pk, com.liferay.portal.model.Group group) {
1983                    getPersistence().addGroup(pk, group);
1984            }
1985    
1986            /**
1987            * Adds an association between the organization and the groups. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1988            *
1989            * @param pk the primary key of the organization
1990            * @param groupPKs the primary keys of the groups
1991            */
1992            public static void addGroups(long pk, long[] groupPKs) {
1993                    getPersistence().addGroups(pk, groupPKs);
1994            }
1995    
1996            /**
1997            * Adds an association between the organization and the groups. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1998            *
1999            * @param pk the primary key of the organization
2000            * @param groups the groups
2001            */
2002            public static void addGroups(long pk,
2003                    List<com.liferay.portal.model.Group> groups) {
2004                    getPersistence().addGroups(pk, groups);
2005            }
2006    
2007            /**
2008            * Clears all associations between the organization and its groups. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2009            *
2010            * @param pk the primary key of the organization to clear the associated groups from
2011            */
2012            public static void clearGroups(long pk) {
2013                    getPersistence().clearGroups(pk);
2014            }
2015    
2016            /**
2017            * Removes the association between the organization and the group. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2018            *
2019            * @param pk the primary key of the organization
2020            * @param groupPK the primary key of the group
2021            */
2022            public static void removeGroup(long pk, long groupPK) {
2023                    getPersistence().removeGroup(pk, groupPK);
2024            }
2025    
2026            /**
2027            * Removes the association between the organization and the group. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2028            *
2029            * @param pk the primary key of the organization
2030            * @param group the group
2031            */
2032            public static void removeGroup(long pk, com.liferay.portal.model.Group group) {
2033                    getPersistence().removeGroup(pk, group);
2034            }
2035    
2036            /**
2037            * Removes the association between the organization and the groups. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2038            *
2039            * @param pk the primary key of the organization
2040            * @param groupPKs the primary keys of the groups
2041            */
2042            public static void removeGroups(long pk, long[] groupPKs) {
2043                    getPersistence().removeGroups(pk, groupPKs);
2044            }
2045    
2046            /**
2047            * Removes the association between the organization and the groups. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2048            *
2049            * @param pk the primary key of the organization
2050            * @param groups the groups
2051            */
2052            public static void removeGroups(long pk,
2053                    List<com.liferay.portal.model.Group> groups) {
2054                    getPersistence().removeGroups(pk, groups);
2055            }
2056    
2057            /**
2058            * Sets the groups associated with the organization, removing and adding associations as necessary. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2059            *
2060            * @param pk the primary key of the organization
2061            * @param groupPKs the primary keys of the groups to be associated with the organization
2062            */
2063            public static void setGroups(long pk, long[] groupPKs) {
2064                    getPersistence().setGroups(pk, groupPKs);
2065            }
2066    
2067            /**
2068            * Sets the groups associated with the organization, removing and adding associations as necessary. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2069            *
2070            * @param pk the primary key of the organization
2071            * @param groups the groups to be associated with the organization
2072            */
2073            public static void setGroups(long pk,
2074                    List<com.liferay.portal.model.Group> groups) {
2075                    getPersistence().setGroups(pk, groups);
2076            }
2077    
2078            /**
2079            * Returns the primaryKeys of users associated with the organization.
2080            *
2081            * @param pk the primary key of the organization
2082            * @return long[] of the primaryKeys of users associated with the organization
2083            */
2084            public static long[] getUserPrimaryKeys(long pk) {
2085                    return getPersistence().getUserPrimaryKeys(pk);
2086            }
2087    
2088            /**
2089            * Returns all the users associated with the organization.
2090            *
2091            * @param pk the primary key of the organization
2092            * @return the users associated with the organization
2093            */
2094            public static List<com.liferay.portal.model.User> getUsers(long pk) {
2095                    return getPersistence().getUsers(pk);
2096            }
2097    
2098            /**
2099            * Returns a range of all the users associated with the organization.
2100            *
2101            * <p>
2102            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link OrganizationModelImpl}. 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.
2103            * </p>
2104            *
2105            * @param pk the primary key of the organization
2106            * @param start the lower bound of the range of organizations
2107            * @param end the upper bound of the range of organizations (not inclusive)
2108            * @return the range of users associated with the organization
2109            */
2110            public static List<com.liferay.portal.model.User> getUsers(long pk,
2111                    int start, int end) {
2112                    return getPersistence().getUsers(pk, start, end);
2113            }
2114    
2115            /**
2116            * Returns an ordered range of all the users associated with the organization.
2117            *
2118            * <p>
2119            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link OrganizationModelImpl}. 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.
2120            * </p>
2121            *
2122            * @param pk the primary key of the organization
2123            * @param start the lower bound of the range of organizations
2124            * @param end the upper bound of the range of organizations (not inclusive)
2125            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
2126            * @return the ordered range of users associated with the organization
2127            */
2128            public static List<com.liferay.portal.model.User> getUsers(long pk,
2129                    int start, int end,
2130                    OrderByComparator<com.liferay.portal.model.User> orderByComparator) {
2131                    return getPersistence().getUsers(pk, start, end, orderByComparator);
2132            }
2133    
2134            /**
2135            * Returns the number of users associated with the organization.
2136            *
2137            * @param pk the primary key of the organization
2138            * @return the number of users associated with the organization
2139            */
2140            public static int getUsersSize(long pk) {
2141                    return getPersistence().getUsersSize(pk);
2142            }
2143    
2144            /**
2145            * Returns <code>true</code> if the user is associated with the organization.
2146            *
2147            * @param pk the primary key of the organization
2148            * @param userPK the primary key of the user
2149            * @return <code>true</code> if the user is associated with the organization; <code>false</code> otherwise
2150            */
2151            public static boolean containsUser(long pk, long userPK) {
2152                    return getPersistence().containsUser(pk, userPK);
2153            }
2154    
2155            /**
2156            * Returns <code>true</code> if the organization has any users associated with it.
2157            *
2158            * @param pk the primary key of the organization to check for associations with users
2159            * @return <code>true</code> if the organization has any users associated with it; <code>false</code> otherwise
2160            */
2161            public static boolean containsUsers(long pk) {
2162                    return getPersistence().containsUsers(pk);
2163            }
2164    
2165            /**
2166            * Adds an association between the organization and the user. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2167            *
2168            * @param pk the primary key of the organization
2169            * @param userPK the primary key of the user
2170            */
2171            public static void addUser(long pk, long userPK) {
2172                    getPersistence().addUser(pk, userPK);
2173            }
2174    
2175            /**
2176            * Adds an association between the organization and the user. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2177            *
2178            * @param pk the primary key of the organization
2179            * @param user the user
2180            */
2181            public static void addUser(long pk, com.liferay.portal.model.User user) {
2182                    getPersistence().addUser(pk, user);
2183            }
2184    
2185            /**
2186            * Adds an association between the organization and the users. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2187            *
2188            * @param pk the primary key of the organization
2189            * @param userPKs the primary keys of the users
2190            */
2191            public static void addUsers(long pk, long[] userPKs) {
2192                    getPersistence().addUsers(pk, userPKs);
2193            }
2194    
2195            /**
2196            * Adds an association between the organization and the users. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2197            *
2198            * @param pk the primary key of the organization
2199            * @param users the users
2200            */
2201            public static void addUsers(long pk,
2202                    List<com.liferay.portal.model.User> users) {
2203                    getPersistence().addUsers(pk, users);
2204            }
2205    
2206            /**
2207            * Clears all associations between the organization and its users. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2208            *
2209            * @param pk the primary key of the organization to clear the associated users from
2210            */
2211            public static void clearUsers(long pk) {
2212                    getPersistence().clearUsers(pk);
2213            }
2214    
2215            /**
2216            * Removes the association between the organization and the user. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2217            *
2218            * @param pk the primary key of the organization
2219            * @param userPK the primary key of the user
2220            */
2221            public static void removeUser(long pk, long userPK) {
2222                    getPersistence().removeUser(pk, userPK);
2223            }
2224    
2225            /**
2226            * Removes the association between the organization and the user. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2227            *
2228            * @param pk the primary key of the organization
2229            * @param user the user
2230            */
2231            public static void removeUser(long pk, com.liferay.portal.model.User user) {
2232                    getPersistence().removeUser(pk, user);
2233            }
2234    
2235            /**
2236            * Removes the association between the organization and the users. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2237            *
2238            * @param pk the primary key of the organization
2239            * @param userPKs the primary keys of the users
2240            */
2241            public static void removeUsers(long pk, long[] userPKs) {
2242                    getPersistence().removeUsers(pk, userPKs);
2243            }
2244    
2245            /**
2246            * Removes the association between the organization and the users. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2247            *
2248            * @param pk the primary key of the organization
2249            * @param users the users
2250            */
2251            public static void removeUsers(long pk,
2252                    List<com.liferay.portal.model.User> users) {
2253                    getPersistence().removeUsers(pk, users);
2254            }
2255    
2256            /**
2257            * Sets the users associated with the organization, removing and adding associations as necessary. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2258            *
2259            * @param pk the primary key of the organization
2260            * @param userPKs the primary keys of the users to be associated with the organization
2261            */
2262            public static void setUsers(long pk, long[] userPKs) {
2263                    getPersistence().setUsers(pk, userPKs);
2264            }
2265    
2266            /**
2267            * Sets the users associated with the organization, removing and adding associations as necessary. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2268            *
2269            * @param pk the primary key of the organization
2270            * @param users the users to be associated with the organization
2271            */
2272            public static void setUsers(long pk,
2273                    List<com.liferay.portal.model.User> users) {
2274                    getPersistence().setUsers(pk, users);
2275            }
2276    
2277            public static OrganizationPersistence getPersistence() {
2278                    if (_persistence == null) {
2279                            _persistence = (OrganizationPersistence)PortalBeanLocatorUtil.locate(OrganizationPersistence.class.getName());
2280    
2281                            ReferenceRegistry.registerReference(OrganizationUtil.class,
2282                                    "_persistence");
2283                    }
2284    
2285                    return _persistence;
2286            }
2287    
2288            /**
2289             * @deprecated As of 6.2.0
2290             */
2291            @Deprecated
2292            public void setPersistence(OrganizationPersistence persistence) {
2293            }
2294    
2295            private static OrganizationPersistence _persistence;
2296    }