001    /**
002     * Copyright (c) 2000-2013 Liferay, Inc. All rights reserved.
003     *
004     * The contents of this file are subject to the terms of the Liferay Enterprise
005     * Subscription License ("License"). You may not use this file except in
006     * compliance with the License. You can obtain a copy of the License by
007     * contacting Liferay, Inc. See the License for the specific language governing
008     * permissions and limitations under the License, including but not limited to
009     * distribution rights of the Software.
010     *
011     *
012     *
013     */
014    
015    package com.liferay.portlet;
016    
017    import com.liferay.portal.model.Group;
018    import com.liferay.portal.model.Portlet;
019    import com.liferay.portal.security.permission.PermissionChecker;
020    import com.liferay.portal.theme.ThemeDisplay;
021    
022    /**
023     * @author Jorge Ferrer
024     */
025    public interface ControlPanelEntry {
026    
027            public boolean hasAccessPermission(
028                            PermissionChecker permissionChecker, Group group, Portlet portlet)
029                    throws Exception;
030    
031            /**
032             * @deprecated As of 6.2.0, with no direct replacement.<p>This method was
033             *             originally defined to determine if a portlet should be
034             *             displayed in the Control Panel. In this version, this method
035             *             should always return <code>false</code> and remains only to
036             *             preserve binary compatibility. This method will be
037             *             permanently removed in a future version.</p><p>In lieu of
038             *             this method, the Control Panel now uses {@link
039             *             #hasAccessPermission} to determine if a portlet should be
040             *             displayed in the Control Panel.</p>
041             */
042            public boolean isVisible(
043                            PermissionChecker permissionChecker, Portlet portlet)
044                    throws Exception;
045    
046            /**
047             * @deprecated As of 6.2.0, with no direct replacement.<p>This method was
048             *             originally defined to determine if a portlet should be
049             *             displayed in the Control Panel. In this version, this method
050             *             should always return <code>false</code> and remains only to
051             *             preserve binary compatibility. This method will be
052             *             permanently removed in a future version.</p><p>In lieu of
053             *             this method, the Control Panel now uses {@link
054             *             #hasAccessPermission} to determine if a portlet should be
055             *             displayed in the Control Panel.</p>
056             */
057            public boolean isVisible(
058                            Portlet portlet, String category, ThemeDisplay themeDisplay)
059                    throws Exception;
060    
061    }