[jboss-cvs] jboss-portal/portlet/src/main/org/jboss/portal/portlet/state ...

Julien Viet julien at jboss.com
Thu Aug 24 09:21:38 EDT 2006


  User: julien  
  Date: 06/08/24 09:21:38

  Added:       portlet/src/main/org/jboss/portal/portlet/state 
                        DestroyCloneFailure.java
  Log:
  updated the implementation of destroyClone to now destroy a list of ids and return the list of non destroyed ids. updated the InstanceContainer accordingly
  
  Revision  Changes    Path
  1.1      date: 2006/08/24 13:21:38;  author: julien;  state: Exp;jboss-portal/portlet/src/main/org/jboss/portal/portlet/state/DestroyCloneFailure.java
  
  Index: DestroyCloneFailure.java
  ===================================================================
  /*
  * JBoss, Home of Professional Open Source
  * Copyright 2005, JBoss Inc., and individual contributors as indicated
  * by the @authors tag. See the copyright.txt in the distribution for a
  * full listing of individual contributors.
  *
  * This is free software; you can redistribute it and/or modify it
  * under the terms of the GNU Lesser General Public License as
  * published by the Free Software Foundation; either version 2.1 of
  * the License, or (at your option) any later version.
  *
  * This software is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  * Lesser General Public License for more details.
  *
  * You should have received a copy of the GNU Lesser General Public
  * License along with this software; if not, write to the Free
  * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
  * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
  */
  package org.jboss.portal.portlet.state;
  
  /**
   * @author <a href="mailto:julien at jboss.org">Julien Viet</a>
   * @version $Revision: 1.1 $
   */
  public class DestroyCloneFailure
  {
  
     /** The clone id. */
     private final String portletId;
  
     /** . */
     private final String message;
  
     public DestroyCloneFailure(String portletId, String message)
     {
        if (portletId == null)
        {
           throw new IllegalArgumentException("Must provide a portlet id");
        }
        this.portletId = portletId;
        this.message = message;
     }
  
     public DestroyCloneFailure(String portletId)
     {
        this(portletId, null);
     }
  
     public String getPortletId()
     {
        return portletId;
     }
  
     public String toString()
     {
        return "DestroyCloneFailure[" + portletId + "," + message + "]";
     }
  
     public int hashCode()
     {
        return portletId.hashCode();
     }
  
     public boolean equals(Object obj)
     {
        if (obj == this)
        {
           return true;
        }
        if (obj instanceof DestroyCloneFailure)
        {
           DestroyCloneFailure that = (DestroyCloneFailure)obj;
           return portletId.equals(that.portletId);
        }
        return false;
     }
  }
  
  
  



More information about the jboss-cvs-commits mailing list