1 /* 2 * Copyright 2000-2001,2004 The Apache Software Foundation. 3 * 4 * Licensed under the Apache License, Version 2.0 (the "License"); 5 * you may not use this file except in compliance with the License. 6 * You may obtain a copy of the License at 7 * 8 * http://www.apache.org/licenses/LICENSE-2.0 9 * 10 * Unless required by applicable law or agreed to in writing, software 11 * distributed under the License is distributed on an "AS IS" BASIS, 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 * See the License for the specific language governing permissions and 14 * limitations under the License. 15 */ 16 17 package org.apache.jetspeed.om.registry; 18 19 import java.util.Iterator; 20 21 /*** 22 Represents a portlet registry. 23 24 @author <a href="mailto:taylor@apache.org">David Sean Taylor</a> 25 @version $Id: PortletRegistry.java,v 1.8 2004/02/23 03:11:39 jford Exp $ 26 */ 27 28 public interface PortletRegistry extends Registry 29 { 30 31 /* 32 * List all portlets in this registry, sorted by category 33 * 34 * @return Iterator The result as an iterator. 35 */ 36 public Iterator listByCategory(); 37 38 /* 39 * Find portlets in this registry, looking up by category in the default category group. 40 * 41 * @param category The category and optional subcategories. 42 * @return Iterator The result as an iterator. 43 */ 44 public Iterator findPortletsByCategory(String category); 45 46 /* 47 * Find portlets in this registry, looking up by category and category group. 48 * 49 * @param group The group to search for categories in. 50 * @param category The category and optional subcategories. 51 * @return Iterator The result as an iterator. 52 */ 53 public Iterator findPortletsByGroupCategory(String group, String category); 54 55 /* 56 * Returns the category key for a given Portlet Registry entry's category object. 57 * This key is used to look up entries in the Portlet Registry by category. 58 * 59 * @param category The registry portlet entry category sub-object. 60 * @return String The category key for looking up this entry by category. 61 */ 62 public String getCategoryKey( Category category ); 63 64 } 65 66