001    /**
002     * Copyright (c) 2000-2010 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 com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
018    
019    /**
020     * @author Brian Wing Shun Chan
021     */
022    public class OrganizationFinderUtil {
023            public static int countByKeywords(long companyId,
024                    long parentOrganizationId,
025                    java.lang.String parentOrganizationIdComparator,
026                    java.lang.String keywords, java.lang.String type,
027                    java.lang.Long regionId, java.lang.Long countryId,
028                    java.util.LinkedHashMap<java.lang.String, java.lang.Object> params)
029                    throws com.liferay.portal.kernel.exception.SystemException {
030                    return getFinder()
031                                       .countByKeywords(companyId, parentOrganizationId,
032                            parentOrganizationIdComparator, keywords, type, regionId,
033                            countryId, params);
034            }
035    
036            public static int countByO_U(long organizationId, long userId)
037                    throws com.liferay.portal.kernel.exception.SystemException {
038                    return getFinder().countByO_U(organizationId, userId);
039            }
040    
041            public static int countByC_PO_N_T_S_C_Z_R_C(long companyId,
042                    long parentOrganizationId,
043                    java.lang.String parentOrganizationIdComparator, java.lang.String name,
044                    java.lang.String type, java.lang.String street, java.lang.String city,
045                    java.lang.String zip, java.lang.Long regionId,
046                    java.lang.Long countryId,
047                    java.util.LinkedHashMap<java.lang.String, java.lang.Object> params,
048                    boolean andOperator)
049                    throws com.liferay.portal.kernel.exception.SystemException {
050                    return getFinder()
051                                       .countByC_PO_N_T_S_C_Z_R_C(companyId, parentOrganizationId,
052                            parentOrganizationIdComparator, name, type, street, city, zip,
053                            regionId, countryId, params, andOperator);
054            }
055    
056            public static int countByC_PO_N_T_S_C_Z_R_C(long companyId,
057                    long parentOrganizationId,
058                    java.lang.String parentOrganizationIdComparator,
059                    java.lang.String[] names, java.lang.String type,
060                    java.lang.String[] streets, java.lang.String[] cities,
061                    java.lang.String[] zips, java.lang.Long regionId,
062                    java.lang.Long countryId,
063                    java.util.LinkedHashMap<java.lang.String, java.lang.Object> params,
064                    boolean andOperator)
065                    throws com.liferay.portal.kernel.exception.SystemException {
066                    return getFinder()
067                                       .countByC_PO_N_T_S_C_Z_R_C(companyId, parentOrganizationId,
068                            parentOrganizationIdComparator, names, type, streets, cities, zips,
069                            regionId, countryId, params, andOperator);
070            }
071    
072            public static java.util.List<com.liferay.portal.model.Organization> findByKeywords(
073                    long companyId, long parentOrganizationId,
074                    java.lang.String parentOrganizationIdComparator,
075                    java.lang.String keywords, java.lang.String type,
076                    java.lang.Long regionId, java.lang.Long countryId,
077                    java.util.LinkedHashMap<java.lang.String, java.lang.Object> params,
078                    int start, int end, com.liferay.portal.kernel.util.OrderByComparator obc)
079                    throws com.liferay.portal.kernel.exception.SystemException {
080                    return getFinder()
081                                       .findByKeywords(companyId, parentOrganizationId,
082                            parentOrganizationIdComparator, keywords, type, regionId,
083                            countryId, params, start, end, obc);
084            }
085    
086            public static java.util.List<com.liferay.portal.model.Organization> findByC_PO_N_T_S_C_Z_R_C(
087                    long companyId, long parentOrganizationId,
088                    java.lang.String parentOrganizationIdComparator, java.lang.String name,
089                    java.lang.String type, java.lang.String street, java.lang.String city,
090                    java.lang.String zip, java.lang.Long regionId,
091                    java.lang.Long countryId,
092                    java.util.LinkedHashMap<java.lang.String, java.lang.Object> params,
093                    boolean andOperator, int start, int end,
094                    com.liferay.portal.kernel.util.OrderByComparator obc)
095                    throws com.liferay.portal.kernel.exception.SystemException {
096                    return getFinder()
097                                       .findByC_PO_N_T_S_C_Z_R_C(companyId, parentOrganizationId,
098                            parentOrganizationIdComparator, name, type, street, city, zip,
099                            regionId, countryId, params, andOperator, start, end, obc);
100            }
101    
102            public static java.util.List<com.liferay.portal.model.Organization> findByC_PO_N_T_S_C_Z_R_C(
103                    long companyId, long parentOrganizationId,
104                    java.lang.String parentOrganizationIdComparator,
105                    java.lang.String[] names, java.lang.String type,
106                    java.lang.String[] streets, java.lang.String[] cities,
107                    java.lang.String[] zips, java.lang.Long regionId,
108                    java.lang.Long countryId,
109                    java.util.LinkedHashMap<java.lang.String, java.lang.Object> params,
110                    boolean andOperator, int start, int end,
111                    com.liferay.portal.kernel.util.OrderByComparator obc)
112                    throws com.liferay.portal.kernel.exception.SystemException {
113                    return getFinder()
114                                       .findByC_PO_N_T_S_C_Z_R_C(companyId, parentOrganizationId,
115                            parentOrganizationIdComparator, names, type, streets, cities, zips,
116                            regionId, countryId, params, andOperator, start, end, obc);
117            }
118    
119            public static OrganizationFinder getFinder() {
120                    if (_finder == null) {
121                            _finder = (OrganizationFinder)PortalBeanLocatorUtil.locate(OrganizationFinder.class.getName());
122                    }
123    
124                    return _finder;
125            }
126    
127            public void setFinder(OrganizationFinder finder) {
128                    _finder = finder;
129            }
130    
131            private static OrganizationFinder _finder;
132    }