001 /** 002 * Copyright (c) 2000-2012 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.kernel.portletdisplaytemplate; 016 017 import java.util.List; 018 019 /** 020 * @author Juan Fernández 021 */ 022 public interface PortletDisplayTemplateHandlerRegistry { 023 024 public long[] getClassNameIds(); 025 026 /** 027 * Returns the portlet display template handler associated with the class 028 * name ID. 029 * 030 * @param classNameId the class name ID of the portlet display template 031 * @return the portlet display template handler associated with the class 032 * name ID 033 */ 034 public PortletDisplayTemplateHandler getPortletDisplayTemplateHandler( 035 long classNameId); 036 037 /** 038 * Returns the portlet display template handler associated with the class 039 * name. 040 * 041 * @param className the class name of the portlet display template 042 * @return the portlet display template handler associated with the class 043 * name 044 */ 045 public PortletDisplayTemplateHandler getPortletDisplayTemplateHandler( 046 String className); 047 048 /** 049 * Returns all the portlet display template handlers. 050 * 051 * @return the portlet display template handlers 052 */ 053 public List<PortletDisplayTemplateHandler> 054 getPortletDisplayTemplateHandlers(); 055 056 /** 057 * Registers the portlet display template handler. 058 * 059 * @param portletDisplayTemplateHandler the portlet display template handler 060 * to register 061 */ 062 public void register( 063 PortletDisplayTemplateHandler portletDisplayTemplateHandler); 064 065 /** 066 * Unregisters the portlet display template handler. 067 * 068 * @param portletDisplayTemplateHandler the portlet display template handler 069 * to unregister 070 */ 071 public void unregister( 072 PortletDisplayTemplateHandler portletDisplayTemplateHandler); 073 074 }