PortletImpl.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.driver; 22 23 import java.io.Serializable; 24 25 import org.apache.wsrp4j.producer.provider.Portlet; 26 import org.apache.wsrp4j.producer.provider.ProducerOfferedPortlet; 27 28 /** 29 * <p>This abstract class implements the Portlet interface encapsulating 30 * Portlet-objects. Provides setters and getters.</p> 31 * <p>Implements the Cloneable interface to enable cloning of portlets.</p> 32 * <p>Implements the Serializable interface to enable serialization, e.g. to 33 * an XML-file.</p> 34 * 35 * @author <a href="mailto:stefan.behl@de.ibm.com">Stefan Behl</a> 36 * 37 * @see ProducerOfferedPortlet 38 */ 39 public abstract class PortletImpl implements Portlet, Serializable { 40 41 private String handle = ""; 42 43 /** 44 * Returns the portletHandle. 45 * 46 * @return A String representing the portletHandle. 47 */ 48 public String getPortletHandle() { 49 return this.handle; 50 } 51 52 /** 53 * Sets the portletHandle to enable identification of the portlet. 54 * 55 * @param portletHandle String to be assigned to handle. 56 */ 57 public void setPortletHandle(String portletHandle) { 58 this.handle = portletHandle; 59 } 60 61 /** 62 * Redefines the clone-method of the Cloneable-interface. This is necessary 63 * as the clone-method is declared protected in the Object class. 64 * 65 * @return Object representing the cloned object. 66 */ 67 public abstract Object clone(); 68 }