PortletRegistrationFilter.java |
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 /* 18 19 */ 20 21 package org.apache.wsrp4j.producer.provider; 22 23 import java.util.Iterator; 24 25 /** 26 * This interface provides methods to inspect portlets that are 27 * accessible by a certain consumer. 28 * 29 * @author <a href="mailto:stefan.behl@de.ibm.com">Stefan Behl</a> 30 * 31 * @version 1.1 32 * 33 */ 34 public interface PortletRegistrationFilter { 35 36 /** 37 * Returns all portlet handles of portlets, a certain consumer (identified 38 * by regHandle) can utilize. Returns null if there are no entries for the provided 39 * regHandle. 40 * 41 * @param regHandle String representing the registration handle of a consumer 42 * 43 * @return Iterator of portlet handles 44 */ 45 public Iterator getAvailable(String regHandle); 46 47 /** 48 * Indicates whether a certain consumer is allowed to utilize the portlet identified 49 * by portletHandle or not. Returns false if there is no entry for the provided handles. 50 * 51 * @param regHandle String representing the registration handle of a consumer 52 * @param portletHandle String representing the portlet handle of an portlet 53 * 54 * @return boolean indicating whether the consumer corresponding to regHandle is 55 * allowed to use the portlet identified by portletHandle 56 */ 57 public boolean isAvailable(String regHandle, String portletHandle); 58 59 }