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;
016    
017    import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
018    
019    /**
020     * <p>
021     * This class provides static methods for the
022     * {@link PasswordPolicyService} bean. The static methods of
023     * this class calls the same methods of the bean instance. It's convenient to be
024     * able to just write one line to call a method on a bean instead of writing a
025     * lookup call and a method call.
026     * </p>
027     *
028     * @author    Brian Wing Shun Chan
029     * @see       PasswordPolicyService
030     * @generated
031     */
032    public class PasswordPolicyServiceUtil {
033            public static com.liferay.portal.model.PasswordPolicy addPasswordPolicy(
034                    java.lang.String name, java.lang.String description,
035                    boolean changeable, boolean changeRequired, long minAge,
036                    boolean checkSyntax, boolean allowDictionaryWords, int minAlphanumeric,
037                    int minLength, int minLowerCase, int minNumbers, int minSymbols,
038                    int minUpperCase, boolean history, int historyCount,
039                    boolean expireable, long maxAge, long warningTime, int graceLimit,
040                    boolean lockout, int maxFailure, long lockoutDuration,
041                    long resetFailureCount, long resetTicketMaxAge)
042                    throws com.liferay.portal.kernel.exception.PortalException,
043                            com.liferay.portal.kernel.exception.SystemException {
044                    return getService()
045                                       .addPasswordPolicy(name, description, changeable,
046                            changeRequired, minAge, checkSyntax, allowDictionaryWords,
047                            minAlphanumeric, minLength, minLowerCase, minNumbers, minSymbols,
048                            minUpperCase, history, historyCount, expireable, maxAge,
049                            warningTime, graceLimit, lockout, maxFailure, lockoutDuration,
050                            resetFailureCount, resetTicketMaxAge);
051            }
052    
053            public static void deletePasswordPolicy(long passwordPolicyId)
054                    throws com.liferay.portal.kernel.exception.PortalException,
055                            com.liferay.portal.kernel.exception.SystemException {
056                    getService().deletePasswordPolicy(passwordPolicyId);
057            }
058    
059            public static com.liferay.portal.model.PasswordPolicy updatePasswordPolicy(
060                    long passwordPolicyId, java.lang.String name,
061                    java.lang.String description, boolean changeable,
062                    boolean changeRequired, long minAge, boolean checkSyntax,
063                    boolean allowDictionaryWords, int minAlphanumeric, int minLength,
064                    int minLowerCase, int minNumbers, int minSymbols, int minUpperCase,
065                    boolean history, int historyCount, boolean expireable, long maxAge,
066                    long warningTime, int graceLimit, boolean lockout, int maxFailure,
067                    long lockoutDuration, long resetFailureCount, long resetTicketMaxAge)
068                    throws com.liferay.portal.kernel.exception.PortalException,
069                            com.liferay.portal.kernel.exception.SystemException {
070                    return getService()
071                                       .updatePasswordPolicy(passwordPolicyId, name, description,
072                            changeable, changeRequired, minAge, checkSyntax,
073                            allowDictionaryWords, minAlphanumeric, minLength, minLowerCase,
074                            minNumbers, minSymbols, minUpperCase, history, historyCount,
075                            expireable, maxAge, warningTime, graceLimit, lockout, maxFailure,
076                            lockoutDuration, resetFailureCount, resetTicketMaxAge);
077            }
078    
079            public static PasswordPolicyService getService() {
080                    if (_service == null) {
081                            _service = (PasswordPolicyService)PortalBeanLocatorUtil.locate(PasswordPolicyService.class.getName());
082                    }
083    
084                    return _service;
085            }
086    
087            public void setService(PasswordPolicyService service) {
088                    _service = service;
089            }
090    
091            private static PasswordPolicyService _service;
092    }