Author: apetrelli
Date: Thu Jul 3 12:10:56 2008
New Revision: 673767
URL: http://svn.apache.org/viewvc?rev=673767&view=rev
Log:
TILES-83
Added "inherit" attribute to <tiles:putListAttribute>.
Added Selenium tests.
Added:
tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/PutListAttributeTagParent.java
(with props)
tiles/framework/trunk/tiles-test/src/main/webapp/testdef_list_inherit.jsp
(with props)
tiles/framework/trunk/tiles-test/src/main/webapp/testimportattribute_inherit.jsp
(with props)
tiles/framework/trunk/tiles-test/src/main/webapp/testputlist_inherit.jsp
(with props)
tiles/framework/trunk/tiles-test/src/test/selenium/DefinitionTagListInheritTest.html
(with props)
tiles/framework/trunk/tiles-test/src/test/selenium/ImportAttributeTagInheritTest.html
(with props)
tiles/framework/trunk/tiles-test/src/test/selenium/PutListTagInheritTest.html
(with props)
Modified:
tiles/framework/trunk/tiles-api/src/main/java/org/apache/tiles/ListAttribute.java
tiles/framework/trunk/tiles-core/src/main/java/org/apache/tiles/context/ListAttribute.java
tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/AddAttributeTag.java
tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/InsertDefinitionTag.java
tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/InsertTemplateTag.java
tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/PutAttributeTag.java
tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/PutListAttributeTag.java
tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/RenderTagSupport.java
tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/definition/DefinitionTag.java
tiles/framework/trunk/tiles-jsp/src/main/resources/META-INF/tld/tiles-jsp.tld
tiles/framework/trunk/tiles-test/src/main/webapp/WEB-INF/tiles-defs.xml
tiles/framework/trunk/tiles-test/src/main/webapp/index.jsp
tiles/framework/trunk/tiles-test/src/test/selenium/TestSuite.html
Modified:
tiles/framework/trunk/tiles-api/src/main/java/org/apache/tiles/ListAttribute.java
URL:
http://svn.apache.org/viewvc/tiles/framework/trunk/tiles-api/src/main/java/org/apache/tiles/ListAttribute.java?rev=673767&r1=673766&r2=673767&view=diff
==============================================================================
---
tiles/framework/trunk/tiles-api/src/main/java/org/apache/tiles/ListAttribute.java
(original)
+++
tiles/framework/trunk/tiles-api/src/main/java/org/apache/tiles/ListAttribute.java
Thu Jul 3 12:10:56 2008
@@ -56,12 +56,11 @@
/**
* Constructor.
*
- * @param name Name.
* @param value List.
* @since 2.1.0
*/
- public ListAttribute(String name, List<Object> value) {
- super(name, value);
+ public ListAttribute(List<? extends Object> value) {
+ super(value);
}
/**
Modified:
tiles/framework/trunk/tiles-core/src/main/java/org/apache/tiles/context/ListAttribute.java
URL:
http://svn.apache.org/viewvc/tiles/framework/trunk/tiles-core/src/main/java/org/apache/tiles/context/ListAttribute.java?rev=673767&r1=673766&r2=673767&view=diff
==============================================================================
---
tiles/framework/trunk/tiles-core/src/main/java/org/apache/tiles/context/ListAttribute.java
(original)
+++
tiles/framework/trunk/tiles-core/src/main/java/org/apache/tiles/context/ListAttribute.java
Thu Jul 3 12:10:56 2008
@@ -21,6 +21,8 @@
package org.apache.tiles.context;
+import java.util.List;
+
/**
* An attribute as a <code>List</code>.
* This attribute associates a name with a list. The list can be found by the
@@ -32,4 +34,23 @@
* @deprecated Use [EMAIL PROTECTED] org.apache.tiles.ListAttribute}.
*/
public class ListAttribute extends org.apache.tiles.ListAttribute {
+
+ /**
+ * Constructor.
+ */
+ public ListAttribute() {
+ super();
+ }
+
+ /**
+ * Constructor.
+ *
+ * @param name Name.
+ * @param value List.
+ * @since 2.1.0
+ */
+ public ListAttribute(String name, List<Object> value) {
+ super(value);
+ setName(name);
+ }
}
Modified:
tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/AddAttributeTag.java
URL:
http://svn.apache.org/viewvc/tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/AddAttributeTag.java?rev=673767&r1=673766&r2=673767&view=diff
==============================================================================
---
tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/AddAttributeTag.java
(original)
+++
tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/AddAttributeTag.java
Thu Jul 3 12:10:56 2008
@@ -192,7 +192,11 @@
}
}
- /** [EMAIL PROTECTED] */
+ /**
+ * Executes the processing of this tag, calling its parent tag.
+ *
+ * @throws TilesJspException If something goes wrong during execution.
+ */
protected void execute() throws TilesJspException {
AddAttributeTagParent parent = (AddAttributeTagParent)
TagSupport.findAncestorWithClass(this,
AddAttributeTagParent.class);
Modified:
tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/InsertDefinitionTag.java
URL:
http://svn.apache.org/viewvc/tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/InsertDefinitionTag.java?rev=673767&r1=673766&r2=673767&view=diff
==============================================================================
---
tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/InsertDefinitionTag.java
(original)
+++
tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/InsertDefinitionTag.java
Thu Jul 3 12:10:56 2008
@@ -27,8 +27,7 @@
*
* @version $Rev$ $Date$
*/
-public class InsertDefinitionTag extends InsertTemplateTag implements
- PutAttributeTagParent {
+public class InsertDefinitionTag extends InsertTemplateTag {
/**
* The definition name.
Modified:
tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/InsertTemplateTag.java
URL:
http://svn.apache.org/viewvc/tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/InsertTemplateTag.java?rev=673767&r1=673766&r2=673767&view=diff
==============================================================================
---
tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/InsertTemplateTag.java
(original)
+++
tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/InsertTemplateTag.java
Thu Jul 3 12:10:56 2008
@@ -31,8 +31,7 @@
*
* @version $Rev$ $Date$
*/
-public class InsertTemplateTag extends RenderTagSupport implements
- PutAttributeTagParent {
+public class InsertTemplateTag extends RenderTagSupport {
/**
* A string representing the URI of a template (for example, a JSP page).
Modified:
tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/PutAttributeTag.java
URL:
http://svn.apache.org/viewvc/tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/PutAttributeTag.java?rev=673767&r1=673766&r2=673767&view=diff
==============================================================================
---
tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/PutAttributeTag.java
(original)
+++
tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/PutAttributeTag.java
Thu Jul 3 12:10:56 2008
@@ -133,6 +133,7 @@
}
/** [EMAIL PROTECTED] */
+ @Override
protected void execute() throws TilesJspException {
PutAttributeTagParent parent = (PutAttributeTagParent)
TagSupport.findAncestorWithClass(this,
PutAttributeTagParent.class);
Modified:
tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/PutListAttributeTag.java
URL:
http://svn.apache.org/viewvc/tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/PutListAttributeTag.java?rev=673767&r1=673766&r2=673767&view=diff
==============================================================================
---
tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/PutListAttributeTag.java
(original)
+++
tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/PutListAttributeTag.java
Thu Jul 3 12:10:56 2008
@@ -26,6 +26,8 @@
import java.util.ArrayList;
import java.util.List;
+import javax.servlet.jsp.tagext.TagSupport;
+
/**
* PutList tag implementation.
*
@@ -36,6 +38,37 @@
implements AddAttributeTagParent {
/**
+ * If true, the attribute will put the elements of the attribute with the
+ * same name of the parent definition before the ones specified here. By
+ * default, it is 'false'.
+ */
+ private boolean inherit = false;
+
+ /**
+ * If true, the attribute will put the elements of the attribute with the
+ * same name of the parent definition before the ones specified here. By
+ * default, it is 'false'
+ *
+ * @param inherit The "inherit" value.
+ * @since 2.1.0
+ */
+ public void setInherit(boolean inherit) {
+ this.inherit = inherit;
+ }
+
+ /**
+ * If true, the attribute will put the elements of the attribute with the
+ * same name of the parent definition before the ones specified here. By
+ * default, it is 'false'
+ *
+ * @return The "inherit" value.
+ * @since 2.1.0
+ */
+ public boolean getInherit() {
+ return inherit;
+ }
+
+ /**
* Get list defined in tag.
*
* @return The value of this list attribute.
@@ -72,6 +105,7 @@
* clearing the contents of the list.
*/
public void release() {
+ inherit = false;
super.setValue(null);
super.release();
}
@@ -101,4 +135,18 @@
private void addValue(Attribute attribute) {
this.getAttributes().add(attribute);
}
+
+ /** [EMAIL PROTECTED] */
+ @Override
+ protected void execute() throws TilesJspException {
+ PutListAttributeTagParent parent = (PutListAttributeTagParent)
TagSupport
+ .findAncestorWithClass(this, PutListAttributeTagParent.class);
+
+ if (parent == null) {
+ // Try with the old method.
+ super.execute();
+ }
+
+ parent.processNestedTag(this);
+ }
}
Added:
tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/PutListAttributeTagParent.java
URL:
http://svn.apache.org/viewvc/tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/PutListAttributeTagParent.java?rev=673767&view=auto
==============================================================================
---
tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/PutListAttributeTagParent.java
(added)
+++
tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/PutListAttributeTagParent.java
Thu Jul 3 12:10:56 2008
@@ -0,0 +1,43 @@
+/*
+ * $Id$
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+
+package org.apache.tiles.jsp.taglib;
+
+/**
+ * Tag classes implementing this interface can contain nested
+ * [EMAIL PROTECTED] PutListAttributeTag}. This interface defines a method
called by nested
+ * tags.
+ *
+ * @version $Rev$ $Date$
+ * @since 2.1.0
+ */
+public interface PutListAttributeTagParent {
+ /**
+ * Process the nested tag.
+ *
+ * @param nestedTag Nested tag to process.
+ * @throws TilesJspException If something goes wrong during processing.
+ * @since 2.1.0
+ */
+ void processNestedTag(PutListAttributeTag nestedTag) throws
TilesJspException;
+
+}
Propchange:
tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/PutListAttributeTagParent.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange:
tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/PutListAttributeTagParent.java
------------------------------------------------------------------------------
svn:keywords = Date Author Id Revision HeadURL
Modified:
tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/RenderTagSupport.java
URL:
http://svn.apache.org/viewvc/tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/RenderTagSupport.java?rev=673767&r1=673766&r2=673767&view=diff
==============================================================================
---
tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/RenderTagSupport.java
(original)
+++
tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/RenderTagSupport.java
Thu Jul 3 12:10:56 2008
@@ -24,6 +24,7 @@
import org.apache.commons.logging.LogFactory;
import org.apache.tiles.Attribute;
import org.apache.tiles.AttributeContext;
+import org.apache.tiles.ListAttribute;
import org.apache.tiles.TilesContainer;
import org.apache.tiles.jsp.context.JspUtil;
@@ -50,7 +51,7 @@
* @version $Rev$ $Date$
*/
public abstract class RenderTagSupport extends BodyTagSupport implements
- PutAttributeTagParent {
+ PutAttributeTagParent, PutListAttributeTagParent {
/**
* The log instance for this tag.
@@ -281,6 +282,16 @@
.isCascade());
}
+ /** [EMAIL PROTECTED] */
+ public void processNestedTag(PutListAttributeTag nestedTag) {
+ ListAttribute attribute = new ListAttribute(nestedTag.getAttributes());
+ attribute.setRole(nestedTag.getRole());
+ attribute.setInherit(nestedTag.getInherit());
+
+ attributeContext.putAttribute(nestedTag.getName(), attribute, nestedTag
+ .isCascade());
+ }
+
/**
* Checks if the user is inside the specified role.
*
Modified:
tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/definition/DefinitionTag.java
URL:
http://svn.apache.org/viewvc/tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/definition/DefinitionTag.java?rev=673767&r1=673766&r2=673767&view=diff
==============================================================================
---
tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/definition/DefinitionTag.java
(original)
+++
tiles/framework/trunk/tiles-jsp/src/main/java/org/apache/tiles/jsp/taglib/definition/DefinitionTag.java
Thu Jul 3 12:10:56 2008
@@ -22,10 +22,13 @@
import org.apache.tiles.Attribute;
import org.apache.tiles.Definition;
+import org.apache.tiles.ListAttribute;
import org.apache.tiles.TilesContainer;
import org.apache.tiles.jsp.context.JspUtil;
import org.apache.tiles.jsp.taglib.PutAttributeTag;
import org.apache.tiles.jsp.taglib.PutAttributeTagParent;
+import org.apache.tiles.jsp.taglib.PutListAttributeTag;
+import org.apache.tiles.jsp.taglib.PutListAttributeTagParent;
import org.apache.tiles.jsp.taglib.TilesJspException;
import org.apache.tiles.mgmt.MutableTilesContainer;
@@ -38,8 +41,8 @@
*
* @version $Rev$ $Date$
*/
-public class DefinitionTag extends TagSupport
- implements PutAttributeTagParent {
+public class DefinitionTag extends TagSupport implements PutAttributeTagParent,
+ PutListAttributeTagParent {
/**
@@ -224,6 +227,15 @@
.isCascade());
}
+ /** [EMAIL PROTECTED] */
+ public void processNestedTag(PutListAttributeTag nestedTag) {
+ ListAttribute attribute = new ListAttribute(nestedTag.getAttributes());
+ attribute.setRole(nestedTag.getRole());
+ attribute.setInherit(nestedTag.getInherit());
+ definition.putAttribute(nestedTag.getName(), attribute, nestedTag
+ .isCascade());
+ }
+
/**
* Find parent tag which must implement [EMAIL PROTECTED]
DefinitionTagParent}.
* @throws TilesJspException If we can't find an appropriate enclosing tag.
Modified:
tiles/framework/trunk/tiles-jsp/src/main/resources/META-INF/tld/tiles-jsp.tld
URL:
http://svn.apache.org/viewvc/tiles/framework/trunk/tiles-jsp/src/main/resources/META-INF/tld/tiles-jsp.tld?rev=673767&r1=673766&r2=673767&view=diff
==============================================================================
---
tiles/framework/trunk/tiles-jsp/src/main/resources/META-INF/tld/tiles-jsp.tld
(original)
+++
tiles/framework/trunk/tiles-jsp/src/main/resources/META-INF/tld/tiles-jsp.tld
Thu Jul 3 12:10:56 2008
@@ -525,6 +525,19 @@
]]>
</description>
</attribute>
+ <attribute>
+ <name>inherit</name>
+ <required>false</required>
+ <rtexprvalue>false</rtexprvalue>
+ <type>boolean</type>
+ <description>
+ <![CDATA[
+ <p>If true, the attribute will put the elements of the attribute
+ with the same name of the parent definition before the ones
+ specified here. By default, it is 'false'.</p>
+ ]]>
+ </description>
+ </attribute>
</tag>
<tag>
<name>addAttribute</name>
Modified:
tiles/framework/trunk/tiles-test/src/main/webapp/WEB-INF/tiles-defs.xml
URL:
http://svn.apache.org/viewvc/tiles/framework/trunk/tiles-test/src/main/webapp/WEB-INF/tiles-defs.xml?rev=673767&r1=673766&r2=673767&view=diff
==============================================================================
--- tiles/framework/trunk/tiles-test/src/main/webapp/WEB-INF/tiles-defs.xml
(original)
+++ tiles/framework/trunk/tiles-test/src/main/webapp/WEB-INF/tiles-defs.xml Thu
Jul 3 12:10:56 2008
@@ -80,6 +80,24 @@
</put-list-attribute>
</definition>
+ <definition name="test.putAttributes.inherit" extends="test.putAttributes">
+ <put-list-attribute name="list" inherit="true">
+ <add-attribute value="valueFour" type="string" />
+ </put-list-attribute>
+ </definition>
+
+ <definition name="test.putAttributes.inherit" extends="test.putAttributes">
+ <put-list-attribute name="list" inherit="true">
+ <add-attribute value="valueFour" type="string" />
+ </put-list-attribute>
+ </definition>
+
+ <definition name="test.putAttributes.inherit" extends="test.putAttributes">
+ <put-list-attribute name="list" inherit="true">
+ <add-attribute value="valueFour" type="string" />
+ </put-list-attribute>
+ </definition>
+
<definition name="test.putAllAttributes"
template="/putallattributeslayout.jsp">
<put-attribute name="one" value="There should be three more strings"
type="string" />
<put-attribute name="two" value="One" type="string" />
Modified: tiles/framework/trunk/tiles-test/src/main/webapp/index.jsp
URL:
http://svn.apache.org/viewvc/tiles/framework/trunk/tiles-test/src/main/webapp/index.jsp?rev=673767&r1=673766&r2=673767&view=diff
==============================================================================
--- tiles/framework/trunk/tiles-test/src/main/webapp/index.jsp (original)
+++ tiles/framework/trunk/tiles-test/src/main/webapp/index.jsp Thu Jul 3
12:10:56 2008
@@ -71,8 +71,10 @@
<a href="testput_reversed_explicit.jsp">Test Put Tag with Reversed
Explicit Attribute</a><br/>
<a href="testputlist.jsp">Test Put List Tag</a><br/>
<a href="testputlist_cascaded.jsp">Test Put List Cascaded Tag</a><br/>
+ <a href="testputlist_inherit.jsp">Test Put List Tag with Inherit</a><br/>
<a href="testimportattribute.jsp">Test importAttribute Tag</a><br/>
<a href="testimportattribute_all.jsp">Test importAttribute Tag with no
name</a><br/>
+ <a href="testimportattribute_inherit.jsp">Test importAttribute Tag with
List Inherit</a><br/>
<a href="testdecorationfilter.jsp">Test Tiles Definition Filter</a><br/>
<a href="testdispatchservlet.tiles">Test Tiles Dispatch Servlet</a><br/>
<a href="selectlocale.jsp">Test Localization</a><br/>
@@ -83,6 +85,7 @@
<a href="testdef.jsp">Test Definition Tag</a><br/>
<a href="testdef_extend.jsp">Test Definition Tag extending configured and
custom definitions</a><br/>
<a href="testdef_preparer.jsp">Test Definition Tag with Preparer</a><br/>
+ <a href="testdef_list_inherit.jsp">Test Definition Tag with a List
Inherit</a><br/>
<a href="testinsertdefinition_composite_tags_includes_configured.jsp">Test
Insert Definition that contains another definition inside (configured via
tiles-defs.xml) using JSP tags</a><br/>
<a href="testinsertdefinition_composite_tags.jsp">Test Insert Definition
that contains another definition inside using JSP tags</a><br/>
<a
href="testinsertdefinition_composite_tags_includes_configured_notype.jsp">Test
Insert Definition that contains another definition inside (configured via
tiles-defs.xml) using JSP tags without types</a><br/>
Added: tiles/framework/trunk/tiles-test/src/main/webapp/testdef_list_inherit.jsp
URL:
http://svn.apache.org/viewvc/tiles/framework/trunk/tiles-test/src/main/webapp/testdef_list_inherit.jsp?rev=673767&view=auto
==============================================================================
--- tiles/framework/trunk/tiles-test/src/main/webapp/testdef_list_inherit.jsp
(added)
+++ tiles/framework/trunk/tiles-test/src/main/webapp/testdef_list_inherit.jsp
Thu Jul 3 12:10:56 2008
@@ -0,0 +1,33 @@
+<%@ page session="false" %>
+<%--
+/*
+ * $Id$
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ *
+ */
+--%>
+<%@ taglib uri="http://tiles.apache.org/tags-tiles" prefix="tiles" %>
+
+<tiles:definition name="templateDefinition" extends="test.putAttributes">
+ <tiles:putAttribute name="stringTest" value="This is a string"
type="string"/>
+ <tiles:putListAttribute name="list" inherit="true">
+ <tiles:addAttribute value="valueFour" type="string" />
+ </tiles:putListAttribute>
+</tiles:definition>
+<tiles:insertDefinition name="templateDefinition" />
Propchange:
tiles/framework/trunk/tiles-test/src/main/webapp/testdef_list_inherit.jsp
------------------------------------------------------------------------------
svn:eol-style = native
Propchange:
tiles/framework/trunk/tiles-test/src/main/webapp/testdef_list_inherit.jsp
------------------------------------------------------------------------------
svn:keywords = Date Author Id Revision HeadURL
Added:
tiles/framework/trunk/tiles-test/src/main/webapp/testimportattribute_inherit.jsp
URL:
http://svn.apache.org/viewvc/tiles/framework/trunk/tiles-test/src/main/webapp/testimportattribute_inherit.jsp?rev=673767&view=auto
==============================================================================
---
tiles/framework/trunk/tiles-test/src/main/webapp/testimportattribute_inherit.jsp
(added)
+++
tiles/framework/trunk/tiles-test/src/main/webapp/testimportattribute_inherit.jsp
Thu Jul 3 12:10:56 2008
@@ -0,0 +1,27 @@
+<%@ page session="false" %>
+<%--
+/*
+ * $Id$
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ *
+ */
+--%>
+<%@ taglib uri="http://tiles.apache.org/tags-tiles" prefix="tiles" %>
+
+<tiles:insertDefinition name="test.putAttributes.inherit" />
Propchange:
tiles/framework/trunk/tiles-test/src/main/webapp/testimportattribute_inherit.jsp
------------------------------------------------------------------------------
svn:eol-style = native
Propchange:
tiles/framework/trunk/tiles-test/src/main/webapp/testimportattribute_inherit.jsp
------------------------------------------------------------------------------
svn:keywords = Date Author Id Revision HeadURL
Added: tiles/framework/trunk/tiles-test/src/main/webapp/testputlist_inherit.jsp
URL:
http://svn.apache.org/viewvc/tiles/framework/trunk/tiles-test/src/main/webapp/testputlist_inherit.jsp?rev=673767&view=auto
==============================================================================
--- tiles/framework/trunk/tiles-test/src/main/webapp/testputlist_inherit.jsp
(added)
+++ tiles/framework/trunk/tiles-test/src/main/webapp/testputlist_inherit.jsp
Thu Jul 3 12:10:56 2008
@@ -0,0 +1,31 @@
+<%@ page session="false" %>
+<%--
+/*
+ * $Id$
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ *
+ */
+--%>
+<%@ taglib uri="http://tiles.apache.org/tags-tiles" prefix="tiles" %>
+
+<tiles:insertDefinition name="test.putAttributes">
+ <tiles:putListAttribute name="list" inherit="true">
+ <tiles:addAttribute value="valueFour" type="string" />
+ </tiles:putListAttribute>
+</tiles:insertDefinition>
Propchange:
tiles/framework/trunk/tiles-test/src/main/webapp/testputlist_inherit.jsp
------------------------------------------------------------------------------
svn:eol-style = native
Propchange:
tiles/framework/trunk/tiles-test/src/main/webapp/testputlist_inherit.jsp
------------------------------------------------------------------------------
svn:keywords = Date Author Id Revision HeadURL
Added:
tiles/framework/trunk/tiles-test/src/test/selenium/DefinitionTagListInheritTest.html
URL:
http://svn.apache.org/viewvc/tiles/framework/trunk/tiles-test/src/test/selenium/DefinitionTagListInheritTest.html?rev=673767&view=auto
==============================================================================
---
tiles/framework/trunk/tiles-test/src/test/selenium/DefinitionTagListInheritTest.html
(added)
+++
tiles/framework/trunk/tiles-test/src/test/selenium/DefinitionTagListInheritTest.html
Thu Jul 3 12:10:56 2008
@@ -0,0 +1,71 @@
+<!--
+/*
+ * $Id$
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+-->
+<html>
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
+<title>Definition Tag List Inherit Test</title>
+</head>
+<body>
+<table cellpadding="1" cellspacing="1" border="1">
+<thead>
+<tr><td rowspan="1" colspan="3">Definition Tag List Inherit Test</td></tr>
+</thead><tbody>
+<tr>
+ <td>open</td>
+ <td>/tiles-test/index.jsp</td>
+ <td></td>
+</tr>
+<tr>
+ <td>clickAndWait</td>
+ <td>link=Test Definition Tag with a List Inherit</td>
+ <td></td>
+</tr>
+<tr>
+ <td>assertTextPresent</td>
+ <td>Single attribute "stringTest" value: This is a string </td>
+ <td></td>
+</tr>
+<tr>
+ <td>assertTextPresent</td>
+ <td>valueOne</td>
+ <td></td>
+</tr>
+<tr>
+ <td>assertTextPresent</td>
+ <td>valueTwo</td>
+ <td></td>
+</tr>
+<tr>
+ <td>assertTextPresent</td>
+ <td>valueThree</td>
+ <td></td>
+</tr>
+<tr>
+ <td>assertTextPresent</td>
+ <td>valueFour</td>
+ <td></td>
+</tr>
+
+</tbody></table>
+</body>
+</html>
Propchange:
tiles/framework/trunk/tiles-test/src/test/selenium/DefinitionTagListInheritTest.html
------------------------------------------------------------------------------
svn:eol-style = native
Propchange:
tiles/framework/trunk/tiles-test/src/test/selenium/DefinitionTagListInheritTest.html
------------------------------------------------------------------------------
svn:keywords = Date Author Id Revision HeadURL
Added:
tiles/framework/trunk/tiles-test/src/test/selenium/ImportAttributeTagInheritTest.html
URL:
http://svn.apache.org/viewvc/tiles/framework/trunk/tiles-test/src/test/selenium/ImportAttributeTagInheritTest.html?rev=673767&view=auto
==============================================================================
---
tiles/framework/trunk/tiles-test/src/test/selenium/ImportAttributeTagInheritTest.html
(added)
+++
tiles/framework/trunk/tiles-test/src/test/selenium/ImportAttributeTagInheritTest.html
Thu Jul 3 12:10:56 2008
@@ -0,0 +1,71 @@
+<!--
+/*
+ * $Id$
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+-->
+<html>
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
+<title>Import Attribute Tag Inherit Test</title>
+</head>
+<body>
+<table cellpadding="1" cellspacing="1" border="1">
+<thead>
+<tr><td rowspan="1" colspan="3">Import Attribute Tag Inherit Test</td></tr>
+</thead><tbody>
+<tr>
+ <td>open</td>
+ <td>/tiles-test/index.jsp</td>
+ <td></td>
+</tr>
+<tr>
+ <td>clickAndWait</td>
+ <td>link=Test Put List Tag with Inherit</td>
+ <td></td>
+</tr>
+<tr>
+ <td>assertTextPresent</td>
+ <td>Single attribute "stringTest" value: This is a string </td>
+ <td></td>
+</tr>
+<tr>
+ <td>assertTextPresent</td>
+ <td>valueOne</td>
+ <td></td>
+</tr>
+<tr>
+ <td>assertTextPresent</td>
+ <td>valueTwo</td>
+ <td></td>
+</tr>
+<tr>
+ <td>assertTextPresent</td>
+ <td>valueThree</td>
+ <td></td>
+</tr>
+<tr>
+ <td>assertTextPresent</td>
+ <td>valueFour</td>
+ <td></td>
+</tr>
+
+</tbody></table>
+</body>
+</html>
Propchange:
tiles/framework/trunk/tiles-test/src/test/selenium/ImportAttributeTagInheritTest.html
------------------------------------------------------------------------------
svn:eol-style = native
Propchange:
tiles/framework/trunk/tiles-test/src/test/selenium/ImportAttributeTagInheritTest.html
------------------------------------------------------------------------------
svn:keywords = Date Author Id Revision HeadURL
Added:
tiles/framework/trunk/tiles-test/src/test/selenium/PutListTagInheritTest.html
URL:
http://svn.apache.org/viewvc/tiles/framework/trunk/tiles-test/src/test/selenium/PutListTagInheritTest.html?rev=673767&view=auto
==============================================================================
---
tiles/framework/trunk/tiles-test/src/test/selenium/PutListTagInheritTest.html
(added)
+++
tiles/framework/trunk/tiles-test/src/test/selenium/PutListTagInheritTest.html
Thu Jul 3 12:10:56 2008
@@ -0,0 +1,71 @@
+<!--
+/*
+ * $Id$
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+-->
+<html>
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
+<title>Put List Tag Inherit Test</title>
+</head>
+<body>
+<table cellpadding="1" cellspacing="1" border="1">
+<thead>
+<tr><td rowspan="1" colspan="3">Put List Tag Inherit Test</td></tr>
+</thead><tbody>
+<tr>
+ <td>open</td>
+ <td>/tiles-test/index.jsp</td>
+ <td></td>
+</tr>
+<tr>
+ <td>clickAndWait</td>
+ <td>link=Test Put List Tag with Inherit</td>
+ <td></td>
+</tr>
+<tr>
+ <td>assertTextPresent</td>
+ <td>Single attribute "stringTest" value: This is a string </td>
+ <td></td>
+</tr>
+<tr>
+ <td>assertTextPresent</td>
+ <td>valueOne</td>
+ <td></td>
+</tr>
+<tr>
+ <td>assertTextPresent</td>
+ <td>valueTwo</td>
+ <td></td>
+</tr>
+<tr>
+ <td>assertTextPresent</td>
+ <td>valueThree</td>
+ <td></td>
+</tr>
+<tr>
+ <td>assertTextPresent</td>
+ <td>valueFour</td>
+ <td></td>
+</tr>
+
+</tbody></table>
+</body>
+</html>
Propchange:
tiles/framework/trunk/tiles-test/src/test/selenium/PutListTagInheritTest.html
------------------------------------------------------------------------------
svn:eol-style = native
Propchange:
tiles/framework/trunk/tiles-test/src/test/selenium/PutListTagInheritTest.html
------------------------------------------------------------------------------
svn:keywords = Date Author Id Revision HeadURL
Modified: tiles/framework/trunk/tiles-test/src/test/selenium/TestSuite.html
URL:
http://svn.apache.org/viewvc/tiles/framework/trunk/tiles-test/src/test/selenium/TestSuite.html?rev=673767&r1=673766&r2=673767&view=diff
==============================================================================
--- tiles/framework/trunk/tiles-test/src/test/selenium/TestSuite.html (original)
+++ tiles/framework/trunk/tiles-test/src/test/selenium/TestSuite.html Thu Jul
3 12:10:56 2008
@@ -145,6 +145,9 @@
<td><a href="PutListCascadedTagTest.html">Put List Cascaded Tag
Test</a></td>
</tr>
<tr>
+ <td><a href="PutListTagInheritTest.html">Put List Tag Inherit
Test</a></td>
+ </tr>
+ <tr>
<td><a href="LocalizationTest.html">Localization Test</a></td>
</tr>
<tr>
@@ -154,6 +157,9 @@
<td><a href="ImportAttributeTagAllTest.html">Import Attribute Tag with
no Name Specified Test</a></td>
</tr>
<tr>
+ <td><a href="ImportAttributeTagInheritTest.html">Import Attribute Tag
Inherit Test</a></td>
+ </tr>
+ <tr>
<td><a href="TilesDefinitionFilterTest.html">Tiles Definition Filter
Test</a></td>
</tr>
<tr>
@@ -169,6 +175,9 @@
<td><a href="DefinitionTagExtendTest.html">Definition Tag Extend
Test</a></td>
</tr>
<tr>
+ <td><a href="DefinitionTagListInheritTest.html">Definition Tag List
Inherit Test</a></td>
+ </tr>
+ <tr>
<td><a href="DefinitionTagPreparerTest.html">Definition Tag with
Preparer Test</a></td>
</tr>
<tr>