You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@cocoon.apache.org by an...@apache.org on 2007/07/10 23:49:16 UTC

svn commit: r555091 - in /cocoon/trunk/blocks/cocoon-xsp/cocoon-xsp-sample/src/main/resources/COB-INF: java/java5.xsp samples.xml

Author: anathaniel
Date: Tue Jul 10 14:49:15 2007
New Revision: 555091

URL: http://svn.apache.org/viewvc?view=rev&rev=555091
Log:
Add sample to show that XSPs allow Java5 syntax, if running under a 1.5+ JVM

Added:
    cocoon/trunk/blocks/cocoon-xsp/cocoon-xsp-sample/src/main/resources/COB-INF/java/java5.xsp
Modified:
    cocoon/trunk/blocks/cocoon-xsp/cocoon-xsp-sample/src/main/resources/COB-INF/samples.xml

Added: cocoon/trunk/blocks/cocoon-xsp/cocoon-xsp-sample/src/main/resources/COB-INF/java/java5.xsp
URL: http://svn.apache.org/viewvc/cocoon/trunk/blocks/cocoon-xsp/cocoon-xsp-sample/src/main/resources/COB-INF/java/java5.xsp?view=auto&rev=555091
==============================================================================
--- cocoon/trunk/blocks/cocoon-xsp/cocoon-xsp-sample/src/main/resources/COB-INF/java/java5.xsp (added)
+++ cocoon/trunk/blocks/cocoon-xsp/cocoon-xsp-sample/src/main/resources/COB-INF/java/java5.xsp Tue Jul 10 14:49:15 2007
@@ -0,0 +1,38 @@
+<?xml version="1.0"?>
+<!--
+  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.
+-->
+
+<!-- CVS $Id: hello.xsp 433543 2006-08-22 06:22:54Z crossley $ -->
+
+<xsp:page language="java"
+          xmlns:xsp="http://apache.org/xsp">
+
+  <page>
+    <title>Java5</title>
+    <content>
+      <para>
+        <xsp:logic>
+          String text = "XSP allows to use Java5 syntax, if running under a 1.5+ JVM.";
+          for ( String word : text.split(" ") ) {
+            <span><xsp:expr>word+" "</xsp:expr></span>
+          }
+        </xsp:logic>
+      </para>
+    </content>
+  </page>
+
+</xsp:page>

Modified: cocoon/trunk/blocks/cocoon-xsp/cocoon-xsp-sample/src/main/resources/COB-INF/samples.xml
URL: http://svn.apache.org/viewvc/cocoon/trunk/blocks/cocoon-xsp/cocoon-xsp-sample/src/main/resources/COB-INF/samples.xml?view=diff&rev=555091&r1=555090&r2=555091
==============================================================================
--- cocoon/trunk/blocks/cocoon-xsp/cocoon-xsp-sample/src/main/resources/COB-INF/samples.xml (original)
+++ cocoon/trunk/blocks/cocoon-xsp/cocoon-xsp-sample/src/main/resources/COB-INF/samples.xml Tue Jul 10 14:49:15 2007
@@ -77,6 +77,9 @@
    <sample name="Zipping" href="java/zipping.zip" xlink:role="dynamic">
     On-the-fly zipping of filtered files.
    </sample>
+   <sample name="Java5" href="java/java5" xlink:role="dynamic">
+    Java5 syntax allowed, if running under a 1.5+ JVM.
+   </sample>
   </group>
 
   <group name="eXtensible Server Pages in Javascript">