Author: chris.laprun(a)jboss.com
Date: 2010-03-08 11:05:36 -0500 (Mon, 08 Mar 2010)
New Revision: 2038
Modified:
components/pc/trunk/api/src/main/java/org/gatein/pc/api/ActionURL.java
components/pc/trunk/api/src/main/java/org/gatein/pc/api/ContainerURL.java
components/pc/trunk/api/src/main/java/org/gatein/pc/api/PortletURL.java
components/pc/trunk/api/src/main/java/org/gatein/pc/api/RenderURL.java
components/pc/trunk/api/src/main/java/org/gatein/pc/api/ResourceURL.java
Log:
- Moved common methods to ContainerURL. Polymorphism is good!
Modified: components/pc/trunk/api/src/main/java/org/gatein/pc/api/ActionURL.java
===================================================================
--- components/pc/trunk/api/src/main/java/org/gatein/pc/api/ActionURL.java 2010-03-08
16:03:06 UTC (rev 2037)
+++ components/pc/trunk/api/src/main/java/org/gatein/pc/api/ActionURL.java 2010-03-08
16:05:36 UTC (rev 2038)
@@ -1,30 +1,27 @@
-/******************************************************************************
- * JBoss, a division of Red Hat *
- * Copyright 2006, Red Hat Middleware, LLC, 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. *
- ******************************************************************************/
+/*
+ * JBoss, a division of Red Hat
+ * Copyright 2010, Red Hat Middleware, LLC, 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.gatein.pc.api;
-import org.gatein.pc.api.PortletURL;
-import org.gatein.pc.api.StateString;
-
/**
* @author <a href="mailto:julien@jboss.org">Julien Viet</a>
* @version $Revision: 5448 $
@@ -37,11 +34,4 @@
* @return the interaction state
*/
StateString getInteractionState();
-
- /**
- * Return the navigational state that may be null.
- *
- * @return the navigational state
- */
- StateString getNavigationalState();
}
Modified: components/pc/trunk/api/src/main/java/org/gatein/pc/api/ContainerURL.java
===================================================================
--- components/pc/trunk/api/src/main/java/org/gatein/pc/api/ContainerURL.java 2010-03-08
16:03:06 UTC (rev 2037)
+++ components/pc/trunk/api/src/main/java/org/gatein/pc/api/ContainerURL.java 2010-03-08
16:05:36 UTC (rev 2038)
@@ -1,25 +1,25 @@
-/******************************************************************************
- * JBoss, a division of Red Hat *
- * Copyright 2006, Red Hat Middleware, LLC, 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. *
- ******************************************************************************/
+/*
+ * JBoss, a division of Red Hat
+ * Copyright 2010, Red Hat Middleware, LLC, 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.gatein.pc.api;
/**
@@ -28,4 +28,24 @@
*/
public interface ContainerURL
{
+ /**
+ * Returns the mode that may be null.
+ *
+ * @return the mode
+ */
+ Mode getMode();
+
+ /**
+ * Returns the window state that may be null.
+ *
+ * @return the window state
+ */
+ WindowState getWindowState();
+
+ /**
+ * Return the navigational state that may be null.
+ *
+ * @return the navigational state
+ */
+ StateString getNavigationalState();
}
Modified: components/pc/trunk/api/src/main/java/org/gatein/pc/api/PortletURL.java
===================================================================
--- components/pc/trunk/api/src/main/java/org/gatein/pc/api/PortletURL.java 2010-03-08
16:03:06 UTC (rev 2037)
+++ components/pc/trunk/api/src/main/java/org/gatein/pc/api/PortletURL.java 2010-03-08
16:05:36 UTC (rev 2038)
@@ -1,46 +1,31 @@
-/******************************************************************************
- * JBoss, a division of Red Hat *
- * Copyright 2006, Red Hat Middleware, LLC, 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. *
- ******************************************************************************/
+/*
+ * JBoss, a division of Red Hat
+ * Copyright 2010, Red Hat Middleware, LLC, 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.gatein.pc.api;
-import org.gatein.pc.api.ContainerURL;
-
/**
* @author <a href="mailto:julien@jboss.org">Julien Viet</a>
* @version $Revision: 5448 $
*/
public interface PortletURL extends ContainerURL
{
- /**
- * Returns the mode that may be null.
- *
- * @return the mode
- */
- org.gatein.pc.api.Mode getMode();
-
- /**
- * Returns the window state that may be null.
- *
- * @return the window state
- */
- org.gatein.pc.api.WindowState getWindowState();
}
Modified: components/pc/trunk/api/src/main/java/org/gatein/pc/api/RenderURL.java
===================================================================
--- components/pc/trunk/api/src/main/java/org/gatein/pc/api/RenderURL.java 2010-03-08
16:03:06 UTC (rev 2037)
+++ components/pc/trunk/api/src/main/java/org/gatein/pc/api/RenderURL.java 2010-03-08
16:05:36 UTC (rev 2038)
@@ -1,25 +1,25 @@
-/******************************************************************************
- * JBoss, a division of Red Hat *
- * Copyright 2006, Red Hat Middleware, LLC, 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. *
- ******************************************************************************/
+/*
+ * JBoss, a division of Red Hat
+ * Copyright 2010, Red Hat Middleware, LLC, 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.gatein.pc.api;
import java.util.Map;
@@ -31,13 +31,6 @@
public interface RenderURL extends PortletURL
{
/**
- * Return the navigational state that may be null.
- *
- * @return the navigational state
- */
- StateString getNavigationalState();
-
- /**
* Returns the public navigational state changes.
*
* @return the public navigational state changes
Modified: components/pc/trunk/api/src/main/java/org/gatein/pc/api/ResourceURL.java
===================================================================
--- components/pc/trunk/api/src/main/java/org/gatein/pc/api/ResourceURL.java 2010-03-08
16:03:06 UTC (rev 2037)
+++ components/pc/trunk/api/src/main/java/org/gatein/pc/api/ResourceURL.java 2010-03-08
16:05:36 UTC (rev 2038)
@@ -1,31 +1,28 @@
-/******************************************************************************
- * JBoss, a division of Red Hat *
- * Copyright 2006, Red Hat Middleware, LLC, 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. *
- ******************************************************************************/
+/*
+ * JBoss, a division of Red Hat
+ * Copyright 2010, Red Hat Middleware, LLC, 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.gatein.pc.api;
import org.gatein.pc.api.cache.CacheLevel;
-import org.gatein.pc.api.ContainerURL;
-import org.gatein.pc.api.Mode;
-import org.gatein.pc.api.WindowState;
/**
* @author <a href="mailto:julien@jboss.org">Julien Viet</a>
@@ -54,25 +51,4 @@
* @return the resource cacheability
*/
CacheLevel getCacheability();
-
- /**
- * Return the navigational state that may be null.
- *
- * @return the navigational state
- */
- StateString getNavigationalState();
-
- /**
- * Returns the mode that may be null.
- *
- * @return the mode
- */
- Mode getMode();
-
- /**
- * Returns the window state that may be null.
- *
- * @return the window state
- */
- WindowState getWindowState();
}