INT-1380 added file sample
0
adapter-development/readme.txt
Normal file
0
api/readme.txt
Normal file
11
case-studies/loanshark/.classpath
Normal file
@@ -0,0 +1,11 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<classpath>
|
||||
<classpathentry kind="src" output="target/classes" path="src/main/java"/>
|
||||
<classpathentry excluding="**" kind="src" output="target/classes" path="src/main/resources"/>
|
||||
<classpathentry kind="src" output="target/test-classes" path="src/test/java"/>
|
||||
<classpathentry excluding="**" kind="src" output="target/test-classes" path="src/test/resources"/>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.6"/>
|
||||
<classpathentry kind="con" path="org.maven.ide.eclipse.MAVEN2_CLASSPATH_CONTAINER"/>
|
||||
<classpathentry kind="con" path="org.eclipse.ajdt.core.ASPECTJRT_CONTAINER"/>
|
||||
<classpathentry kind="output" path="target/classes"/>
|
||||
</classpath>
|
||||
53
case-studies/loanshark/.project
Normal file
@@ -0,0 +1,53 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<projectDescription>
|
||||
<name>loanshark</name>
|
||||
<comment></comment>
|
||||
<projects>
|
||||
</projects>
|
||||
<buildSpec>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.ajdt.core.ajbuilder</name>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.wst.common.project.facet.core.builder</name>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.wst.validation.validationbuilder</name>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.ajdt.core.ajbuilder</name>
|
||||
<arguments>
|
||||
<dictionary>
|
||||
<key>aspectPath</key>
|
||||
<value>org.springframework.aspects</value>
|
||||
</dictionary>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
<buildCommand>
|
||||
<name>org.springframework.ide.eclipse.core.springbuilder</name>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
<buildCommand>
|
||||
<name>org.maven.ide.eclipse.maven2Builder</name>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
</buildSpec>
|
||||
<natures>
|
||||
<nature>org.maven.ide.eclipse.maven2Nature</nature>
|
||||
<nature>org.eclipse.wst.common.project.facet.core.nature</nature>
|
||||
<nature>org.eclipse.ajdt.ui.ajnature</nature>
|
||||
<nature>org.eclipse.jdt.core.javanature</nature>
|
||||
<nature>org.eclipse.wst.common.modulecore.ModuleCoreNature</nature>
|
||||
<nature>org.eclipse.jem.workbench.JavaEMFNature</nature>
|
||||
<nature>com.springsource.sts.roo.core.nature</nature>
|
||||
<nature>org.springframework.ide.eclipse.core.springnature</nature>
|
||||
</natures>
|
||||
</projectDescription>
|
||||
@@ -0,0 +1,5 @@
|
||||
#Tue Sep 07 17:11:57 EDT 2010
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6
|
||||
eclipse.preferences.version=1
|
||||
org.eclipse.jdt.core.compiler.source=1.6
|
||||
org.eclipse.jdt.core.compiler.compliance=1.6
|
||||
@@ -0,0 +1,166 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project-modules id="moduleCoreId" project-version="1.5.0">
|
||||
<wb-module deploy-name="loanshark">
|
||||
<property name="context-root" value="loanshark"/>
|
||||
<wb-resource deploy-path="/" source-path="src/main/webapp"/>
|
||||
<property name="java-output-path" value="/target/classes"/>
|
||||
<dependent-module archiveName="antlr-2.7.6.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/antlr/antlr/2.7.6/antlr-2.7.6.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="aopalliance-1.0.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/aopalliance/aopalliance/1.0/aopalliance-1.0.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="aspectjrt-1.6.10.M1.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/org/aspectj/aspectjrt/1.6.10.M1/aspectjrt-1.6.10.M1.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="cglib-nodep-2.2.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/cglib/cglib-nodep/2.2/cglib-nodep-2.2.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="commons-beanutils-1.8.0.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/commons-beanutils/commons-beanutils/1.8.0/commons-beanutils-1.8.0.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="commons-collections-3.1.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/commons-collections/commons-collections/3.1/commons-collections-3.1.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="commons-dbcp-1.3.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/commons-dbcp/commons-dbcp/1.3/commons-dbcp-1.3.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="commons-digester-2.0.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/commons-digester/commons-digester/2.0/commons-digester-2.0.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="commons-fileupload-1.2.1.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/commons-fileupload/commons-fileupload/1.2.1/commons-fileupload-1.2.1.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="commons-pool-1.5.4.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/commons-pool/commons-pool/1.5.4/commons-pool-1.5.4.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="dom4j-1.6.1.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/dom4j/dom4j/1.6.1/dom4j-1.6.1.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="flexjson-2.0.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/net/sf/flexjson/flexjson/2.0/flexjson-2.0.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="hibernate-annotations-3.5.5-Final.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/org/hibernate/hibernate-annotations/3.5.5-Final/hibernate-annotations-3.5.5-Final.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="hibernate-commons-annotations-3.2.0.Final.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/org/hibernate/hibernate-commons-annotations/3.2.0.Final/hibernate-commons-annotations-3.2.0.Final.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="hibernate-core-3.5.5-Final.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/org/hibernate/hibernate-core/3.5.5-Final/hibernate-core-3.5.5-Final.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="hibernate-entitymanager-3.5.5-Final.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/org/hibernate/hibernate-entitymanager/3.5.5-Final/hibernate-entitymanager-3.5.5-Final.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="hibernate-jpa-2.0-api-1.0.0.Final.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/org/hibernate/javax/persistence/hibernate-jpa-2.0-api/1.0.0.Final/hibernate-jpa-2.0-api-1.0.0.Final.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="hibernate-validator-4.1.0.Final.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/org/hibernate/hibernate-validator/4.1.0.Final/hibernate-validator-4.1.0.Final.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="hsqldb-2.0.0.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/org/hsqldb/hsqldb/2.0.0/hsqldb-2.0.0.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="javassist-3.9.0.GA.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/javassist/javassist/3.9.0.GA/javassist-3.9.0.GA.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="jcl-over-slf4j-1.6.1.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/org/slf4j/jcl-over-slf4j/1.6.1/jcl-over-slf4j-1.6.1.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="joda-time-1.6.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/joda-time/joda-time/1.6/joda-time-1.6.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="jstl-1.2.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/javax/servlet/jstl/1.2/jstl-1.2.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="jta-1.1.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/javax/transaction/jta/1.1/jta-1.1.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="log4j-1.2.16.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/log4j/log4j/1.2.16/log4j-1.2.16.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="slf4j-api-1.6.1.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/org/slf4j/slf4j-api/1.6.1/slf4j-api-1.6.1.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="slf4j-log4j12-1.6.1.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/org/slf4j/slf4j-log4j12/1.6.1/slf4j-log4j12-1.6.1.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="spring-aop-3.0.4.RELEASE.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/org/springframework/spring-aop/3.0.4.RELEASE/spring-aop-3.0.4.RELEASE.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="spring-asm-3.0.4.RELEASE.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/org/springframework/spring-asm/3.0.4.RELEASE/spring-asm-3.0.4.RELEASE.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="spring-aspects-3.0.4.RELEASE.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/org/springframework/spring-aspects/3.0.4.RELEASE/spring-aspects-3.0.4.RELEASE.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="spring-beans-3.0.4.RELEASE.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/org/springframework/spring-beans/3.0.4.RELEASE/spring-beans-3.0.4.RELEASE.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="spring-commons-serializer-1.0.0.M1.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/org/springframework/commons/spring-commons-serializer/1.0.0.M1/spring-commons-serializer-1.0.0.M1.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="spring-context-3.0.4.RELEASE.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/org/springframework/spring-context/3.0.4.RELEASE/spring-context-3.0.4.RELEASE.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="spring-context-support-3.0.4.RELEASE.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/org/springframework/spring-context-support/3.0.4.RELEASE/spring-context-support-3.0.4.RELEASE.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="spring-core-3.0.4.RELEASE.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/org/springframework/spring-core/3.0.4.RELEASE/spring-core-3.0.4.RELEASE.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="spring-expression-3.0.4.RELEASE.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/org/springframework/spring-expression/3.0.4.RELEASE/spring-expression-3.0.4.RELEASE.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="spring-integration-core-2.0.0.M7.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/org/springframework/integration/spring-integration-core/2.0.0.M7/spring-integration-core-2.0.0.M7.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="spring-integration-ip-2.0.0.M7.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/org/springframework/integration/spring-integration-ip/2.0.0.M7/spring-integration-ip-2.0.0.M7.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="spring-integration-stream-2.0.0.M7.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/org/springframework/integration/spring-integration-stream/2.0.0.M7/spring-integration-stream-2.0.0.M7.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="spring-jdbc-3.0.4.RELEASE.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/org/springframework/spring-jdbc/3.0.4.RELEASE/spring-jdbc-3.0.4.RELEASE.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="spring-js-2.1.1.RELEASE.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/org/springframework/webflow/spring-js/2.1.1.RELEASE/spring-js-2.1.1.RELEASE.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="spring-orm-3.0.4.RELEASE.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/org/springframework/spring-orm/3.0.4.RELEASE/spring-orm-3.0.4.RELEASE.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="spring-tx-3.0.4.RELEASE.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/org/springframework/spring-tx/3.0.4.RELEASE/spring-tx-3.0.4.RELEASE.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="spring-web-3.0.4.RELEASE.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/org/springframework/spring-web/3.0.4.RELEASE/spring-web-3.0.4.RELEASE.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="spring-webmvc-3.0.4.RELEASE.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/org/springframework/spring-webmvc/3.0.4.RELEASE/spring-webmvc-3.0.4.RELEASE.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="tiles-api-2.2.1.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/org/apache/tiles/tiles-api/2.2.1/tiles-api-2.2.1.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="tiles-core-2.2.1.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/org/apache/tiles/tiles-core/2.2.1/tiles-core-2.2.1.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="tiles-jsp-2.2.1.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/org/apache/tiles/tiles-jsp/2.2.1/tiles-jsp-2.2.1.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="tiles-servlet-2.2.1.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/org/apache/tiles/tiles-servlet/2.2.1/tiles-servlet-2.2.1.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="tiles-template-2.2.1.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/org/apache/tiles/tiles-template/2.2.1/tiles-template-2.2.1.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="validation-api-1.0.0.GA.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/javax/validation/validation-api/1.0.0.GA/validation-api-1.0.0.GA.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<dependent-module archiveName="xml-apis-1.0.b2.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/var/M2_REPO/xml-apis/xml-apis/1.0.b2/xml-apis-1.0.b2.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<wb-resource deploy-path="/WEB-INF/classes" source-path="src/main/java"/>
|
||||
<wb-resource deploy-path="/WEB-INF/classes" source-path="src/main/resources"/>
|
||||
</wb-module>
|
||||
</project-modules>
|
||||
@@ -0,0 +1,6 @@
|
||||
<faceted-project>
|
||||
<fixed facet="jst.java"/>
|
||||
<fixed facet="jst.web"/>
|
||||
<installed facet="jst.web" version="2.5"/>
|
||||
<installed facet="jst.java" version="6.0"/>
|
||||
</faceted-project>
|
||||
@@ -0,0 +1,9 @@
|
||||
#Sat Sep 04 08:32:18 EDT 2010
|
||||
DELEGATES_PREFERENCE=delegateValidatorList
|
||||
USER_BUILD_PREFERENCE=enabledBuildValidatorListorg.eclipse.jst.j2ee.internal.classpathdep.ClasspathDependencyValidator;org.eclipse.jst.j2ee.internal.web.validation.UIWarValidator;
|
||||
USER_MANUAL_PREFERENCE=enabledManualValidatorListorg.eclipse.jst.j2ee.internal.classpathdep.ClasspathDependencyValidator;org.eclipse.jst.j2ee.internal.web.validation.UIWarValidator;
|
||||
USER_PREFERENCE=overrideGlobalPreferencestruedisableAllValidationtrueversion1.2.200.v201005271900
|
||||
eclipse.preferences.version=1
|
||||
override=true
|
||||
suspend=true
|
||||
vf.version=3
|
||||
@@ -0,0 +1,4 @@
|
||||
#Mon Mar 29 11:51:49 EDT 2010
|
||||
eclipse.preferences.version=1
|
||||
org.springframework.ide.eclipse.beans.core.ignoreMissingNamespaceHandler=false
|
||||
org.springframework.ide.eclipse.beans.core.loadNamespaceHandlerFromClasspath=true
|
||||
@@ -0,0 +1,68 @@
|
||||
#Sat Sep 04 08:31:52 EDT 2010
|
||||
eclipse.preferences.version=1
|
||||
org.springframework.ide.eclipse.core.builders.enable.aopreferencemodelbuilder=true
|
||||
org.springframework.ide.eclipse.core.builders.enable.beanmetadatabuilder=true
|
||||
org.springframework.ide.eclipse.core.builders.enable.osgibundleupdater=false
|
||||
org.springframework.ide.eclipse.core.enable.project.preferences=true
|
||||
org.springframework.ide.eclipse.core.validator.enable.com.springsource.server.ide.manifest.core.manifestvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.enable.com.springsource.sts.bestpractices.beansvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.enable.com.springsource.sts.server.quickfix.manifestvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.enable.org.springframework.ide.eclipse.beans.core.beansvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.enable.org.springframework.ide.eclipse.core.springvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.enable.org.springframework.ide.eclipse.webflow.core.validator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.com.springsource.server.ide.manifest.core.applicationSymbolicNameRule-com.springsource.server.ide.manifest.core.manifestvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.com.springsource.server.ide.manifest.core.applicationVersionRule-com.springsource.server.ide.manifest.core.manifestvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.com.springsource.server.ide.manifest.core.bundleActivationPolicyRule-com.springsource.server.ide.manifest.core.manifestvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.com.springsource.server.ide.manifest.core.bundleActivatorRule-com.springsource.server.ide.manifest.core.manifestvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.com.springsource.server.ide.manifest.core.bundleManifestVersionRule-com.springsource.server.ide.manifest.core.manifestvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.com.springsource.server.ide.manifest.core.bundleSymbolicNameRule-com.springsource.server.ide.manifest.core.manifestvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.com.springsource.server.ide.manifest.core.bundleVersionRule-com.springsource.server.ide.manifest.core.manifestvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.com.springsource.server.ide.manifest.core.exportPackageRule-com.springsource.server.ide.manifest.core.manifestvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.com.springsource.server.ide.manifest.core.importRule-com.springsource.server.ide.manifest.core.manifestvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.com.springsource.server.ide.manifest.core.parsingProblemsRule-com.springsource.server.ide.manifest.core.manifestvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.com.springsource.server.ide.manifest.core.requireBundleRule-com.springsource.server.ide.manifest.core.manifestvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.com.springsource.sts.bestpractices.com.springsource.sts.bestpractices.AvoidDriverManagerDataSource-com.springsource.sts.bestpractices.beansvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.com.springsource.sts.bestpractices.com.springsource.sts.bestpractices.ImportElementsAtTopRulee-com.springsource.sts.bestpractices.beansvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.com.springsource.sts.bestpractices.com.springsource.sts.bestpractices.ParentBeanSpecifiesAbstractClassRule-com.springsource.sts.bestpractices.beansvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.com.springsource.sts.bestpractices.com.springsource.sts.bestpractices.RefElementRule-com.springsource.sts.bestpractices.beansvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.com.springsource.sts.bestpractices.com.springsource.sts.bestpractices.TooManyBeansInFileRule-com.springsource.sts.bestpractices.beansvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.com.springsource.sts.bestpractices.com.springsource.sts.bestpractices.UnnecessaryValueElementRule-com.springsource.sts.bestpractices.beansvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.com.springsource.sts.bestpractices.com.springsource.sts.bestpractices.UseBeanInheritance-com.springsource.sts.bestpractices.beansvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.com.springsource.sts.bestpractices.legacyxmlusage.jndiobjectfactory-com.springsource.sts.bestpractices.beansvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.com.springsource.sts.server.quickfix.importBundleVersionRule-com.springsource.sts.server.quickfix.manifestvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.com.springsource.sts.server.quickfix.importLibraryVersionRule-com.springsource.sts.server.quickfix.manifestvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.com.springsource.sts.server.quickfix.importPackageVersionRule-com.springsource.sts.server.quickfix.manifestvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.com.springsource.sts.server.quickfix.requireBundleVersionRule-com.springsource.sts.server.quickfix.manifestvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.org.springframework.ide.eclipse.beans.core.autowire.autowire-org.springframework.ide.eclipse.beans.core.beansvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.org.springframework.ide.eclipse.beans.core.beanAlias-org.springframework.ide.eclipse.beans.core.beansvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.org.springframework.ide.eclipse.beans.core.beanClass-org.springframework.ide.eclipse.beans.core.beansvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.org.springframework.ide.eclipse.beans.core.beanConstructorArgument-org.springframework.ide.eclipse.beans.core.beansvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.org.springframework.ide.eclipse.beans.core.beanDefinition-org.springframework.ide.eclipse.beans.core.beansvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.org.springframework.ide.eclipse.beans.core.beanDefinitionHolder-org.springframework.ide.eclipse.beans.core.beansvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.org.springframework.ide.eclipse.beans.core.beanFactory-org.springframework.ide.eclipse.beans.core.beansvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.org.springframework.ide.eclipse.beans.core.beanInitDestroyMethod-org.springframework.ide.eclipse.beans.core.beansvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.org.springframework.ide.eclipse.beans.core.beanProperty-org.springframework.ide.eclipse.beans.core.beansvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.org.springframework.ide.eclipse.beans.core.beanReference-org.springframework.ide.eclipse.beans.core.beansvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.org.springframework.ide.eclipse.beans.core.methodOverride-org.springframework.ide.eclipse.beans.core.beansvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.org.springframework.ide.eclipse.beans.core.parsingProblems-org.springframework.ide.eclipse.beans.core.beansvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.org.springframework.ide.eclipse.beans.core.requiredProperty-org.springframework.ide.eclipse.beans.core.beansvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.org.springframework.ide.eclipse.beans.core.toolAnnotation-org.springframework.ide.eclipse.beans.core.beansvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.org.springframework.ide.eclipse.core.springClasspath-org.springframework.ide.eclipse.core.springvalidator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.org.springframework.ide.eclipse.webflow.core.validation.action-org.springframework.ide.eclipse.webflow.core.validator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.org.springframework.ide.eclipse.webflow.core.validation.actionstate-org.springframework.ide.eclipse.webflow.core.validator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.org.springframework.ide.eclipse.webflow.core.validation.attribute-org.springframework.ide.eclipse.webflow.core.validator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.org.springframework.ide.eclipse.webflow.core.validation.attributemapper-org.springframework.ide.eclipse.webflow.core.validator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.org.springframework.ide.eclipse.webflow.core.validation.beanaction-org.springframework.ide.eclipse.webflow.core.validator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.org.springframework.ide.eclipse.webflow.core.validation.evaluationaction-org.springframework.ide.eclipse.webflow.core.validator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.org.springframework.ide.eclipse.webflow.core.validation.evaluationresult-org.springframework.ide.eclipse.webflow.core.validator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.org.springframework.ide.eclipse.webflow.core.validation.exceptionhandler-org.springframework.ide.eclipse.webflow.core.validator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.org.springframework.ide.eclipse.webflow.core.validation.import-org.springframework.ide.eclipse.webflow.core.validator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.org.springframework.ide.eclipse.webflow.core.validation.inputattribute-org.springframework.ide.eclipse.webflow.core.validator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.org.springframework.ide.eclipse.webflow.core.validation.mapping-org.springframework.ide.eclipse.webflow.core.validator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.org.springframework.ide.eclipse.webflow.core.validation.outputattribute-org.springframework.ide.eclipse.webflow.core.validator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.org.springframework.ide.eclipse.webflow.core.validation.set-org.springframework.ide.eclipse.webflow.core.validator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.org.springframework.ide.eclipse.webflow.core.validation.state-org.springframework.ide.eclipse.webflow.core.validator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.org.springframework.ide.eclipse.webflow.core.validation.subflowstate-org.springframework.ide.eclipse.webflow.core.validator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.org.springframework.ide.eclipse.webflow.core.validation.transition-org.springframework.ide.eclipse.webflow.core.validator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.org.springframework.ide.eclipse.webflow.core.validation.variable-org.springframework.ide.eclipse.webflow.core.validator=false
|
||||
org.springframework.ide.eclipse.core.validator.rule.enable.org.springframework.ide.eclipse.webflow.core.validation.webflowstate-org.springframework.ide.eclipse.webflow.core.validator=false
|
||||
13
case-studies/loanshark/.springBeans
Normal file
@@ -0,0 +1,13 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<beansProjectDescription>
|
||||
<version>1</version>
|
||||
<pluginVersion><![CDATA[2.3.3.201007151000-M2]]></pluginVersion>
|
||||
<configSuffixes>
|
||||
<configSuffix><![CDATA[xml]]></configSuffix>
|
||||
</configSuffixes>
|
||||
<enableImports><![CDATA[false]]></enableImports>
|
||||
<configs>
|
||||
</configs>
|
||||
<configSets>
|
||||
</configSets>
|
||||
</beansProjectDescription>
|
||||
10
case-studies/loanshark/README.txt
Normal file
@@ -0,0 +1,10 @@
|
||||
See README.txt in loan-broker sample for information about this sample.
|
||||
|
||||
To change the multicast code in udps.groovy to rely on unicast instead, simply
|
||||
change the MulticastSocket type to DatagramSocket and remove the next 2 lines
|
||||
that deal with joining the multicast group. Then, in the configuration of the
|
||||
actual adapter, set: host="127.0.0.1" and multicast="false".
|
||||
|
||||
For the Roo/Spring Integration application, edit the integrationContext.xml
|
||||
file, on the udpIn adapter, set multicast to false and remove the
|
||||
multicast-address attribute.
|
||||
509
case-studies/loanshark/pom.xml
Normal file
@@ -0,0 +1,509 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<groupId>org.springframework.integration.samples</groupId>
|
||||
<version>2.0.0.BUILD-SNAPSHOT</version>
|
||||
<artifactId>loanshark</artifactId>
|
||||
<name>Spring Integration Loan Shark Sample</name>
|
||||
<packaging>war</packaging>
|
||||
<properties>
|
||||
<roo.version>1.1.0.M3</roo.version>
|
||||
<spring.version>3.0.4.RELEASE</spring.version>
|
||||
<aspectj.version>1.6.10.M1</aspectj.version>
|
||||
<slf4j.version>1.6.1</slf4j.version>
|
||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||
</properties>
|
||||
<repositories>
|
||||
<repository>
|
||||
<id>spring-maven-release</id>
|
||||
<name>Spring Maven Release Repository</name>
|
||||
<url>http://maven.springframework.org/release</url>
|
||||
</repository>
|
||||
<repository>
|
||||
<id>spring-maven-milestone</id>
|
||||
<name>Spring Maven Milestone Repository</name>
|
||||
<url>http://maven.springframework.org/milestone</url>
|
||||
</repository>
|
||||
<repository>
|
||||
<id>spring-roo-repository</id>
|
||||
<name>Spring Roo Repository</name>
|
||||
<url>http://spring-roo-repository.springsource.org/release</url>
|
||||
</repository>
|
||||
<repository>
|
||||
<id>JBoss Repo</id>
|
||||
<url>https://repository.jboss.org/nexus/content/repositories/releases</url>
|
||||
<name>JBoss Repo</name>
|
||||
</repository>
|
||||
</repositories>
|
||||
<pluginRepositories>
|
||||
<pluginRepository>
|
||||
<id>spring-maven-release</id>
|
||||
<name>Spring Maven Release Repository</name>
|
||||
<url>http://maven.springframework.org/release</url>
|
||||
</pluginRepository>
|
||||
<pluginRepository>
|
||||
<id>spring-maven-milestone</id>
|
||||
<name>Spring Maven Milestone Repository</name>
|
||||
<url>http://maven.springframework.org/milestone</url>
|
||||
</pluginRepository>
|
||||
<pluginRepository>
|
||||
<id>spring-roo-repository</id>
|
||||
<name>Spring Roo Repository</name>
|
||||
<url>http://spring-roo-repository.springsource.org/release</url>
|
||||
</pluginRepository>
|
||||
</pluginRepositories>
|
||||
<dependencies>
|
||||
<!-- General dependencies for standard applications -->
|
||||
<dependency>
|
||||
<groupId>junit</groupId>
|
||||
<artifactId>junit</artifactId>
|
||||
<version>4.8.1</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>log4j</groupId>
|
||||
<artifactId>log4j</artifactId>
|
||||
<version>1.2.16</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.slf4j</groupId>
|
||||
<artifactId>slf4j-api</artifactId>
|
||||
<version>${slf4j.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.slf4j</groupId>
|
||||
<artifactId>jcl-over-slf4j</artifactId>
|
||||
<version>${slf4j.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.slf4j</groupId>
|
||||
<artifactId>slf4j-log4j12</artifactId>
|
||||
<version>${slf4j.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.aspectj</groupId>
|
||||
<artifactId>aspectjrt</artifactId>
|
||||
<version>${aspectj.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>javax.servlet</groupId>
|
||||
<artifactId>servlet-api</artifactId>
|
||||
<version>2.5</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>net.sf.flexjson</groupId>
|
||||
<artifactId>flexjson</artifactId>
|
||||
<version>2.0</version>
|
||||
</dependency>
|
||||
<!-- ROO dependencies -->
|
||||
<dependency>
|
||||
<groupId>org.springframework.roo</groupId>
|
||||
<artifactId>org.springframework.roo.annotations</artifactId>
|
||||
<version>${roo.version}</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
<!-- Spring dependencies -->
|
||||
<dependency>
|
||||
<groupId>org.springframework</groupId>
|
||||
<artifactId>spring-core</artifactId>
|
||||
<version>${spring.version}</version>
|
||||
<exclusions>
|
||||
<exclusion>
|
||||
<groupId>commons-logging</groupId>
|
||||
<artifactId>commons-logging</artifactId>
|
||||
</exclusion>
|
||||
</exclusions>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.springframework</groupId>
|
||||
<artifactId>spring-test</artifactId>
|
||||
<version>${spring.version}</version>
|
||||
<scope>test</scope>
|
||||
<exclusions>
|
||||
<exclusion>
|
||||
<groupId>commons-logging</groupId>
|
||||
<artifactId>commons-logging</artifactId>
|
||||
</exclusion>
|
||||
</exclusions>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.springframework</groupId>
|
||||
<artifactId>spring-context</artifactId>
|
||||
<version>${spring.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.springframework</groupId>
|
||||
<artifactId>spring-aop</artifactId>
|
||||
<version>${spring.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.springframework</groupId>
|
||||
<artifactId>spring-aspects</artifactId>
|
||||
<version>${spring.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.springframework</groupId>
|
||||
<artifactId>spring-tx</artifactId>
|
||||
<version>${spring.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.hsqldb</groupId>
|
||||
<artifactId>hsqldb</artifactId>
|
||||
<version>2.0.0</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.hibernate</groupId>
|
||||
<artifactId>hibernate-core</artifactId>
|
||||
<version>3.5.5-Final</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.hibernate</groupId>
|
||||
<artifactId>hibernate-entitymanager</artifactId>
|
||||
<version>3.5.5-Final</version>
|
||||
<exclusions>
|
||||
<exclusion>
|
||||
<groupId>cglib</groupId>
|
||||
<artifactId>cglib</artifactId>
|
||||
</exclusion>
|
||||
<exclusion>
|
||||
<groupId>dom4j</groupId>
|
||||
<artifactId>dom4j</artifactId>
|
||||
</exclusion>
|
||||
</exclusions>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.hibernate.javax.persistence</groupId>
|
||||
<artifactId>hibernate-jpa-2.0-api</artifactId>
|
||||
<version>1.0.0.Final</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.hibernate</groupId>
|
||||
<artifactId>hibernate-validator</artifactId>
|
||||
<version>4.1.0.Final</version>
|
||||
<exclusions>
|
||||
<exclusion>
|
||||
<groupId>javax.xml.bind</groupId>
|
||||
<artifactId>jaxb-api</artifactId>
|
||||
</exclusion>
|
||||
<exclusion>
|
||||
<groupId>com.sun.xml.bind</groupId>
|
||||
<artifactId>jaxb-impl</artifactId>
|
||||
</exclusion>
|
||||
</exclusions>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>javax.validation</groupId>
|
||||
<artifactId>validation-api</artifactId>
|
||||
<version>1.0.0.GA</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>cglib</groupId>
|
||||
<artifactId>cglib-nodep</artifactId>
|
||||
<version>2.2</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>javax.transaction</groupId>
|
||||
<artifactId>jta</artifactId>
|
||||
<version>1.1</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.springframework</groupId>
|
||||
<artifactId>spring-jdbc</artifactId>
|
||||
<version>${spring.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.springframework</groupId>
|
||||
<artifactId>spring-orm</artifactId>
|
||||
<version>${spring.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>commons-pool</groupId>
|
||||
<artifactId>commons-pool</artifactId>
|
||||
<version>1.5.4</version>
|
||||
<exclusions>
|
||||
<exclusion>
|
||||
<groupId>commons-logging</groupId>
|
||||
<artifactId>commons-logging</artifactId>
|
||||
</exclusion>
|
||||
</exclusions>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>commons-dbcp</groupId>
|
||||
<artifactId>commons-dbcp</artifactId>
|
||||
<version>1.3</version>
|
||||
<exclusions>
|
||||
<exclusion>
|
||||
<groupId>commons-logging</groupId>
|
||||
<artifactId>commons-logging</artifactId>
|
||||
</exclusion>
|
||||
<exclusion>
|
||||
<groupId>commons-pool</groupId>
|
||||
<artifactId>commons-pool</artifactId>
|
||||
</exclusion>
|
||||
<exclusion>
|
||||
<groupId>xerces</groupId>
|
||||
<artifactId>xerces</artifactId>
|
||||
</exclusion>
|
||||
<exclusion>
|
||||
<groupId>xerces</groupId>
|
||||
<artifactId>xercesImpl</artifactId>
|
||||
</exclusion>
|
||||
<exclusion>
|
||||
<groupId>xml-apis</groupId>
|
||||
<artifactId>xml-apis</artifactId>
|
||||
</exclusion>
|
||||
</exclusions>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.tiles</groupId>
|
||||
<artifactId>tiles-core</artifactId>
|
||||
<version>2.2.1</version>
|
||||
<exclusions>
|
||||
<exclusion>
|
||||
<groupId>commons-logging</groupId>
|
||||
<artifactId>commons-logging</artifactId>
|
||||
</exclusion>
|
||||
</exclusions>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.tiles</groupId>
|
||||
<artifactId>tiles-jsp</artifactId>
|
||||
<version>2.2.1</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.springframework</groupId>
|
||||
<artifactId>spring-web</artifactId>
|
||||
<version>${spring.version}</version>
|
||||
<exclusions>
|
||||
<exclusion>
|
||||
<groupId>commons-logging</groupId>
|
||||
<artifactId>commons-logging</artifactId>
|
||||
</exclusion>
|
||||
</exclusions>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.springframework</groupId>
|
||||
<artifactId>spring-webmvc</artifactId>
|
||||
<version>${spring.version}</version>
|
||||
<exclusions>
|
||||
<exclusion>
|
||||
<groupId>commons-logging</groupId>
|
||||
<artifactId>commons-logging</artifactId>
|
||||
</exclusion>
|
||||
</exclusions>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.springframework.webflow</groupId>
|
||||
<artifactId>spring-js</artifactId>
|
||||
<version>2.1.1.RELEASE</version>
|
||||
<exclusions>
|
||||
<exclusion>
|
||||
<groupId>org.springframework</groupId>
|
||||
<artifactId>spring-beans</artifactId>
|
||||
</exclusion>
|
||||
<exclusion>
|
||||
<groupId>org.springframework</groupId>
|
||||
<artifactId>spring-context</artifactId>
|
||||
</exclusion>
|
||||
<exclusion>
|
||||
<groupId>org.springframework</groupId>
|
||||
<artifactId>spring-core</artifactId>
|
||||
</exclusion>
|
||||
<exclusion>
|
||||
<groupId>org.springframework</groupId>
|
||||
<artifactId>spring-context-support</artifactId>
|
||||
</exclusion>
|
||||
<exclusion>
|
||||
<groupId>commons-logging</groupId>
|
||||
<artifactId>commons-logging</artifactId>
|
||||
</exclusion>
|
||||
</exclusions>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>commons-digester</groupId>
|
||||
<artifactId>commons-digester</artifactId>
|
||||
<version>2.0</version>
|
||||
<exclusions>
|
||||
<exclusion>
|
||||
<groupId>commons-logging</groupId>
|
||||
<artifactId>commons-logging</artifactId>
|
||||
</exclusion>
|
||||
</exclusions>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>commons-fileupload</groupId>
|
||||
<artifactId>commons-fileupload</artifactId>
|
||||
<version>1.2.1</version>
|
||||
<exclusions>
|
||||
<exclusion>
|
||||
<groupId>commons-logging</groupId>
|
||||
<artifactId>commons-logging</artifactId>
|
||||
</exclusion>
|
||||
</exclusions>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>javax.servlet</groupId>
|
||||
<artifactId>jstl</artifactId>
|
||||
<version>1.2</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>javax.el</groupId>
|
||||
<artifactId>el-api</artifactId>
|
||||
<version>1.0</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>joda-time</groupId>
|
||||
<artifactId>joda-time</artifactId>
|
||||
<version>1.6</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.springframework.integration</groupId>
|
||||
<artifactId>spring-integration-ip</artifactId>
|
||||
<version>2.0.0.M7</version>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
<build>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-war-plugin</artifactId>
|
||||
<version>2.1-beta-1</version>
|
||||
<!--
|
||||
<configuration> <webXml>target/web.xml</webXml> </configuration>
|
||||
-->
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-compiler-plugin</artifactId>
|
||||
<version>2.1</version>
|
||||
<configuration>
|
||||
<source>1.6</source>
|
||||
<target>1.6</target>
|
||||
</configuration>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.codehaus.mojo</groupId>
|
||||
<artifactId>aspectj-maven-plugin</artifactId>
|
||||
<version>1.0</version>
|
||||
<dependencies>
|
||||
<!-- NB: You must use Maven 2.0.9 or above or these are ignored (see MNG-2972) -->
|
||||
<dependency>
|
||||
<groupId>org.aspectj</groupId>
|
||||
<artifactId>aspectjrt</artifactId>
|
||||
<version>${aspectj.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.aspectj</groupId>
|
||||
<artifactId>aspectjtools</artifactId>
|
||||
<version>${aspectj.version}</version>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
<executions>
|
||||
<execution>
|
||||
<goals>
|
||||
<goal>compile</goal>
|
||||
<goal>test-compile</goal>
|
||||
</goals>
|
||||
</execution>
|
||||
</executions>
|
||||
<configuration>
|
||||
<outxml>true</outxml>
|
||||
<aspectLibraries>
|
||||
<aspectLibrary>
|
||||
<groupId>org.springframework</groupId>
|
||||
<artifactId>spring-aspects</artifactId>
|
||||
</aspectLibrary>
|
||||
</aspectLibraries>
|
||||
<source>1.6</source>
|
||||
<target>1.6</target>
|
||||
</configuration>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-resources-plugin</artifactId>
|
||||
<version>2.4.2</version>
|
||||
<configuration>
|
||||
<encoding>UTF-8</encoding>
|
||||
</configuration>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-surefire-plugin</artifactId>
|
||||
<version>2.5</version>
|
||||
<configuration>
|
||||
<excludes>
|
||||
<exclude>**/*_Roo_*</exclude>
|
||||
</excludes>
|
||||
</configuration>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-assembly-plugin</artifactId>
|
||||
<version>2.2-beta-5</version>
|
||||
<configuration>
|
||||
<descriptorRefs>
|
||||
<descriptorRef>jar-with-dependencies</descriptorRef>
|
||||
</descriptorRefs>
|
||||
</configuration>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-deploy-plugin</artifactId>
|
||||
<version>2.5</version>
|
||||
</plugin>
|
||||
<!-- IDE -->
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-eclipse-plugin</artifactId>
|
||||
<version>2.7</version> <!-- Note 2.8 does not work with AspectJ aspect path -->
|
||||
<configuration>
|
||||
<downloadSources>true</downloadSources>
|
||||
<downloadJavadocs>false</downloadJavadocs>
|
||||
<wtpversion>2.0</wtpversion>
|
||||
<additionalBuildcommands>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.ajdt.core.ajbuilder</name>
|
||||
<arguments>
|
||||
<aspectPath>org.springframework.aspects</aspectPath>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
<buildCommand>
|
||||
<name>org.springframework.ide.eclipse.core.springbuilder</name>
|
||||
</buildCommand>
|
||||
</additionalBuildcommands>
|
||||
<additionalProjectnatures>
|
||||
<projectnature>org.eclipse.ajdt.ui.ajnature</projectnature>
|
||||
<projectnature>com.springsource.sts.roo.core.nature</projectnature>
|
||||
<projectnature>org.springframework.ide.eclipse.core.springnature</projectnature>
|
||||
</additionalProjectnatures>
|
||||
</configuration>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-idea-plugin</artifactId>
|
||||
<version>2.2</version>
|
||||
<configuration>
|
||||
<downloadSources>true</downloadSources>
|
||||
<dependenciesAsLibraries>true</dependenciesAsLibraries>
|
||||
</configuration>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.codehaus.mojo</groupId>
|
||||
<artifactId>tomcat-maven-plugin</artifactId>
|
||||
<version>1.0</version>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.mortbay.jetty</groupId>
|
||||
<artifactId>jetty-maven-plugin</artifactId>
|
||||
<version>7.1.2.v20100523</version>
|
||||
<configuration>
|
||||
<webAppConfig>
|
||||
<contextPath>/${project.name}</contextPath>
|
||||
</webAppConfig>
|
||||
</configuration>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
</project>
|
||||
12
case-studies/loanshark/script.roo
Normal file
@@ -0,0 +1,12 @@
|
||||
project --topLevelPackage org.springframework.samples.integration.loanbroker.loanshark3
|
||||
persistence setup --provider HIBERNATE --database HYPERSONIC_IN_MEMORY
|
||||
entity --class ~.domain.LoanShark
|
||||
field string --fieldName name
|
||||
field number --type java.lang.Long --fieldName counter
|
||||
field number --type java.lang.Double --fieldName averageRate
|
||||
finder add --finderName findLoanSharksByName
|
||||
controller scaffold --class ~.web.SharkController
|
||||
logging setup --level DEBUG
|
||||
dependency add --artifactId org.springframework.integration.ip --groupId org.springframework.integration --version 2.0.0.M5
|
||||
//change spring version in pom.xml to 3.0.0.RELEASE-A before perform eclipse
|
||||
//perform eclipse
|
||||
@@ -0,0 +1,50 @@
|
||||
/*
|
||||
* Copyright 2002-2010 the original author or authors.
|
||||
*
|
||||
* Licensed 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.springframework.integration.samples.loanbroker.loanshark.biz;
|
||||
|
||||
import org.springframework.dao.DataAccessException;
|
||||
import org.springframework.integration.samples.loanbroker.loanshark.domain.LoanShark;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
|
||||
/**
|
||||
* @author Gary Russell
|
||||
*
|
||||
*/
|
||||
@Service
|
||||
public class Accumulator {
|
||||
|
||||
@Transactional
|
||||
public void accumulate(SharkQuote quote) {
|
||||
LoanShark shark = null;
|
||||
try {
|
||||
shark = (LoanShark) LoanShark.findLoanSharksByName(
|
||||
quote.getSharkName()).getSingleResult();
|
||||
} catch (DataAccessException dae) {}
|
||||
if (shark == null) {
|
||||
shark = new LoanShark();
|
||||
shark.setName(quote.getSharkName());
|
||||
shark.setCounter(new Long(0));
|
||||
shark.setAverageRate(0.0d);
|
||||
shark.persist();
|
||||
}
|
||||
Double current = shark.getCounter() * shark.getAverageRate();
|
||||
shark.setCounter(shark.getCounter().longValue() + 1);
|
||||
shark.setAverageRate((current + quote.getSharkRate()) / shark.getCounter());
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,59 @@
|
||||
/*
|
||||
* Copyright 2002-2010 the original author or authors.
|
||||
*
|
||||
* Licensed 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.springframework.integration.samples.loanbroker.loanshark.biz;
|
||||
|
||||
/**
|
||||
* @author Gary Russell
|
||||
*
|
||||
*/
|
||||
public class SharkQuote {
|
||||
private String sharkName;
|
||||
private Double sharkRate;
|
||||
|
||||
/**
|
||||
* @param sharkName
|
||||
* @param sharkRate
|
||||
*/
|
||||
public SharkQuote(String sharkName, double sharkRate) {
|
||||
super();
|
||||
this.sharkName = sharkName;
|
||||
this.sharkRate = sharkRate;
|
||||
}
|
||||
/**
|
||||
* @return the sharkName
|
||||
*/
|
||||
public String getSharkName() {
|
||||
return sharkName;
|
||||
}
|
||||
/**
|
||||
* @param sharkName the sharkName to set
|
||||
*/
|
||||
public void setSharkName(String sharkName) {
|
||||
this.sharkName = sharkName;
|
||||
}
|
||||
/**
|
||||
* @return the sharkRate
|
||||
*/
|
||||
public Double getSharkRate() {
|
||||
return sharkRate;
|
||||
}
|
||||
/**
|
||||
* @param sharkRate the sharkRate to set
|
||||
*/
|
||||
public void setSharkRate(Double sharkRate) {
|
||||
this.sharkRate = sharkRate;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,28 @@
|
||||
/*
|
||||
* Copyright 2002-2010 the original author or authors.
|
||||
*
|
||||
* Licensed 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.springframework.integration.samples.loanbroker.loanshark.biz;
|
||||
|
||||
/**
|
||||
* @author Gary Russell
|
||||
*
|
||||
*/
|
||||
public class SharkTransformer {
|
||||
|
||||
public SharkQuote transform(byte[] buffer) {
|
||||
String[] data = new String(buffer).split(",");
|
||||
return new SharkQuote(data[0], Double.parseDouble(data[1]));
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,19 @@
|
||||
package org.springframework.integration.samples.loanbroker.loanshark.domain;
|
||||
|
||||
import javax.persistence.Entity;
|
||||
import org.springframework.roo.addon.javabean.RooJavaBean;
|
||||
import org.springframework.roo.addon.tostring.RooToString;
|
||||
import org.springframework.roo.addon.entity.RooEntity;
|
||||
|
||||
@Entity
|
||||
@RooJavaBean
|
||||
@RooToString
|
||||
@RooEntity(finders = { "findLoanSharksByName" })
|
||||
public class LoanShark {
|
||||
|
||||
private String name;
|
||||
|
||||
private Long counter;
|
||||
|
||||
private Double averageRate;
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
// WARNING: DO NOT EDIT THIS FILE. THIS FILE IS MANAGED BY SPRING ROO.
|
||||
// You may push code into the target .java compilation unit if you wish to edit any member(s).
|
||||
|
||||
package org.springframework.integration.samples.loanbroker.loanshark.domain;
|
||||
|
||||
import org.springframework.beans.factory.annotation.Configurable;
|
||||
|
||||
privileged aspect LoanShark_Roo_Configurable {
|
||||
|
||||
declare @type: LoanShark: @Configurable;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,106 @@
|
||||
// WARNING: DO NOT EDIT THIS FILE. THIS FILE IS MANAGED BY SPRING ROO.
|
||||
// You may push code into the target .java compilation unit if you wish to edit any member(s).
|
||||
|
||||
package org.springframework.integration.samples.loanbroker.loanshark.domain;
|
||||
|
||||
import java.lang.Integer;
|
||||
import java.lang.Long;
|
||||
import java.lang.SuppressWarnings;
|
||||
import java.util.List;
|
||||
import javax.persistence.Column;
|
||||
import javax.persistence.EntityManager;
|
||||
import javax.persistence.GeneratedValue;
|
||||
import javax.persistence.GenerationType;
|
||||
import javax.persistence.Id;
|
||||
import javax.persistence.PersistenceContext;
|
||||
import javax.persistence.Version;
|
||||
import org.springframework.integration.samples.loanbroker.loanshark.domain.LoanShark;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
privileged aspect LoanShark_Roo_Entity {
|
||||
|
||||
@PersistenceContext
|
||||
transient EntityManager LoanShark.entityManager;
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy = GenerationType.AUTO)
|
||||
@Column(name = "id")
|
||||
private Long LoanShark.id;
|
||||
|
||||
@Version
|
||||
@Column(name = "version")
|
||||
private Integer LoanShark.version;
|
||||
|
||||
public Long LoanShark.getId() {
|
||||
return this.id;
|
||||
}
|
||||
|
||||
public void LoanShark.setId(Long id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public Integer LoanShark.getVersion() {
|
||||
return this.version;
|
||||
}
|
||||
|
||||
public void LoanShark.setVersion(Integer version) {
|
||||
this.version = version;
|
||||
}
|
||||
|
||||
@Transactional
|
||||
public void LoanShark.persist() {
|
||||
if (this.entityManager == null) this.entityManager = entityManager();
|
||||
this.entityManager.persist(this);
|
||||
}
|
||||
|
||||
@Transactional
|
||||
public void LoanShark.remove() {
|
||||
if (this.entityManager == null) this.entityManager = entityManager();
|
||||
if (this.entityManager.contains(this)) {
|
||||
this.entityManager.remove(this);
|
||||
} else {
|
||||
LoanShark attached = this.entityManager.find(this.getClass(), this.id);
|
||||
this.entityManager.remove(attached);
|
||||
}
|
||||
}
|
||||
|
||||
@Transactional
|
||||
public void LoanShark.flush() {
|
||||
if (this.entityManager == null) this.entityManager = entityManager();
|
||||
this.entityManager.flush();
|
||||
}
|
||||
|
||||
@Transactional
|
||||
public LoanShark LoanShark.merge() {
|
||||
if (this.entityManager == null) this.entityManager = entityManager();
|
||||
LoanShark merged = this.entityManager.merge(this);
|
||||
this.entityManager.flush();
|
||||
return merged;
|
||||
}
|
||||
|
||||
public static final EntityManager LoanShark.entityManager() {
|
||||
EntityManager em = new LoanShark().entityManager;
|
||||
if (em == null) throw new IllegalStateException("Entity manager has not been injected (is the Spring Aspects JAR configured as an AJC/AJDT aspects library?)");
|
||||
return em;
|
||||
}
|
||||
|
||||
public static long LoanShark.countLoanSharks() {
|
||||
return ((Number) entityManager().createQuery("select count(o) from LoanShark o").getSingleResult()).longValue();
|
||||
}
|
||||
|
||||
@SuppressWarnings("unchecked")
|
||||
public static List<LoanShark> LoanShark.findAllLoanSharks() {
|
||||
return entityManager().createQuery("select o from LoanShark o").getResultList();
|
||||
}
|
||||
|
||||
public static LoanShark LoanShark.findLoanShark(Long id) {
|
||||
if (id == null) return null;
|
||||
return entityManager().find(LoanShark.class, id);
|
||||
}
|
||||
|
||||
@SuppressWarnings("unchecked")
|
||||
public static List<LoanShark> LoanShark.findLoanSharkEntries(int firstResult, int maxResults) {
|
||||
return entityManager().createQuery("select o from LoanShark o").setFirstResult(firstResult).setMaxResults(maxResults).getResultList();
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,20 @@
|
||||
// WARNING: DO NOT EDIT THIS FILE. THIS FILE IS MANAGED BY SPRING ROO.
|
||||
// You may push code into the target .java compilation unit if you wish to edit any member(s).
|
||||
|
||||
package org.springframework.integration.samples.loanbroker.loanshark.domain;
|
||||
|
||||
import java.lang.String;
|
||||
import javax.persistence.EntityManager;
|
||||
import javax.persistence.Query;
|
||||
|
||||
privileged aspect LoanShark_Roo_Finder {
|
||||
|
||||
public static Query LoanShark.findLoanSharksByName(String name) {
|
||||
if (name == null || name.length() == 0) throw new IllegalArgumentException("The name argument is required");
|
||||
EntityManager em = LoanShark.entityManager();
|
||||
Query q = em.createQuery("SELECT LoanShark FROM LoanShark AS loanshark WHERE loanshark.name = :name");
|
||||
q.setParameter("name", name);
|
||||
return q;
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,36 @@
|
||||
// WARNING: DO NOT EDIT THIS FILE. THIS FILE IS MANAGED BY SPRING ROO.
|
||||
// You may push code into the target .java compilation unit if you wish to edit any member(s).
|
||||
|
||||
package org.springframework.integration.samples.loanbroker.loanshark.domain;
|
||||
|
||||
import java.lang.Double;
|
||||
import java.lang.Long;
|
||||
import java.lang.String;
|
||||
|
||||
privileged aspect LoanShark_Roo_JavaBean {
|
||||
|
||||
public String LoanShark.getName() {
|
||||
return this.name;
|
||||
}
|
||||
|
||||
public void LoanShark.setName(String name) {
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
public Long LoanShark.getCounter() {
|
||||
return this.counter;
|
||||
}
|
||||
|
||||
public void LoanShark.setCounter(Long counter) {
|
||||
this.counter = counter;
|
||||
}
|
||||
|
||||
public Double LoanShark.getAverageRate() {
|
||||
return this.averageRate;
|
||||
}
|
||||
|
||||
public void LoanShark.setAverageRate(Double averageRate) {
|
||||
this.averageRate = averageRate;
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,32 @@
|
||||
// WARNING: DO NOT EDIT THIS FILE. THIS FILE IS MANAGED BY SPRING ROO.
|
||||
// You may push code into the target .java compilation unit if you wish to edit any member(s).
|
||||
|
||||
package org.springframework.integration.samples.loanbroker.loanshark.domain;
|
||||
|
||||
import flexjson.JSONDeserializer;
|
||||
import flexjson.JSONSerializer;
|
||||
import java.lang.String;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collection;
|
||||
import java.util.List;
|
||||
import org.springframework.integration.samples.loanbroker.loanshark.domain.LoanShark;
|
||||
|
||||
privileged aspect LoanShark_Roo_Json {
|
||||
|
||||
public String LoanShark.toJson() {
|
||||
return new JSONSerializer().exclude("*.class").serialize(this);
|
||||
}
|
||||
|
||||
public static LoanShark LoanShark.fromJsonToLoanShark(String json) {
|
||||
return new JSONDeserializer<LoanShark>().use(null, LoanShark.class).deserialize(json);
|
||||
}
|
||||
|
||||
public static String LoanShark.toJsonArray(Collection<LoanShark> collection) {
|
||||
return new JSONSerializer().exclude("*.class").serialize(collection);
|
||||
}
|
||||
|
||||
public static Collection<LoanShark> LoanShark.fromJsonArrayToLoanSharks(String json) {
|
||||
return new JSONDeserializer<List<LoanShark>>().use(null, ArrayList.class).use("values", LoanShark.class).deserialize(json);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,20 @@
|
||||
// WARNING: DO NOT EDIT THIS FILE. THIS FILE IS MANAGED BY SPRING ROO.
|
||||
// You may push code into the target .java compilation unit if you wish to edit any member(s).
|
||||
|
||||
package org.springframework.integration.samples.loanbroker.loanshark.domain;
|
||||
|
||||
import java.lang.String;
|
||||
|
||||
privileged aspect LoanShark_Roo_ToString {
|
||||
|
||||
public String LoanShark.toString() {
|
||||
StringBuilder sb = new StringBuilder();
|
||||
sb.append("Id: ").append(getId()).append(", ");
|
||||
sb.append("Version: ").append(getVersion()).append(", ");
|
||||
sb.append("Name: ").append(getName()).append(", ");
|
||||
sb.append("Counter: ").append(getCounter()).append(", ");
|
||||
sb.append("AverageRate: ").append(getAverageRate());
|
||||
return sb.toString();
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
package org.springframework.integration.samples.loanbroker.loanshark.web;
|
||||
|
||||
import org.springframework.roo.addon.web.mvc.controller.RooWebScaffold;
|
||||
import org.springframework.integration.samples.loanbroker.loanshark.domain.LoanShark;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.stereotype.Controller;
|
||||
|
||||
@RooWebScaffold(path = "loansharks", formBackingObject = LoanShark.class)
|
||||
@RequestMapping("/loansharks")
|
||||
@Controller
|
||||
public class SharkController {
|
||||
}
|
||||
@@ -0,0 +1,140 @@
|
||||
// WARNING: DO NOT EDIT THIS FILE. THIS FILE IS MANAGED BY SPRING ROO.
|
||||
// You may push code into the target .java compilation unit if you wish to edit any member(s).
|
||||
|
||||
package org.springframework.integration.samples.loanbroker.loanshark.web;
|
||||
|
||||
import java.lang.Long;
|
||||
import java.lang.String;
|
||||
import javax.validation.Valid;
|
||||
import org.springframework.core.convert.converter.Converter;
|
||||
import org.springframework.core.convert.support.GenericConversionService;
|
||||
import org.springframework.http.HttpStatus;
|
||||
import org.springframework.http.ResponseEntity;
|
||||
import org.springframework.integration.samples.loanbroker.loanshark.domain.LoanShark;
|
||||
import org.springframework.ui.Model;
|
||||
import org.springframework.validation.BindingResult;
|
||||
import org.springframework.web.bind.WebDataBinder;
|
||||
import org.springframework.web.bind.annotation.InitBinder;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMethod;
|
||||
import org.springframework.web.bind.annotation.RequestParam;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
|
||||
privileged aspect SharkController_Roo_Controller {
|
||||
|
||||
@RequestMapping(method = RequestMethod.POST)
|
||||
public String SharkController.create(@Valid LoanShark loanShark, BindingResult result, Model model) {
|
||||
if (result.hasErrors()) {
|
||||
model.addAttribute("loanShark", loanShark);
|
||||
return "loansharks/create";
|
||||
}
|
||||
loanShark.persist();
|
||||
return "redirect:/loansharks/" + loanShark.getId();
|
||||
}
|
||||
|
||||
@RequestMapping(params = "form", method = RequestMethod.GET)
|
||||
public String SharkController.createForm(Model model) {
|
||||
model.addAttribute("loanShark", new LoanShark());
|
||||
return "loansharks/create";
|
||||
}
|
||||
|
||||
@RequestMapping(value = "/{id}", method = RequestMethod.GET)
|
||||
public String SharkController.show(@PathVariable("id") Long id, Model model) {
|
||||
model.addAttribute("loanshark", LoanShark.findLoanShark(id));
|
||||
model.addAttribute("itemId", id);
|
||||
return "loansharks/show";
|
||||
}
|
||||
|
||||
@RequestMapping(method = RequestMethod.GET)
|
||||
public String SharkController.list(@RequestParam(value = "page", required = false) Integer page, @RequestParam(value = "size", required = false) Integer size, Model model) {
|
||||
if (page != null || size != null) {
|
||||
int sizeNo = size == null ? 10 : size.intValue();
|
||||
model.addAttribute("loansharks", LoanShark.findLoanSharkEntries(page == null ? 0 : (page.intValue() - 1) * sizeNo, sizeNo));
|
||||
float nrOfPages = (float) LoanShark.countLoanSharks() / sizeNo;
|
||||
model.addAttribute("maxPages", (int) ((nrOfPages > (int) nrOfPages || nrOfPages == 0.0) ? nrOfPages + 1 : nrOfPages));
|
||||
} else {
|
||||
model.addAttribute("loansharks", LoanShark.findAllLoanSharks());
|
||||
}
|
||||
return "loansharks/list";
|
||||
}
|
||||
|
||||
@RequestMapping(method = RequestMethod.PUT)
|
||||
public String SharkController.update(@Valid LoanShark loanShark, BindingResult result, Model model) {
|
||||
if (result.hasErrors()) {
|
||||
model.addAttribute("loanShark", loanShark);
|
||||
return "loansharks/update";
|
||||
}
|
||||
loanShark.merge();
|
||||
return "redirect:/loansharks/" + loanShark.getId();
|
||||
}
|
||||
|
||||
@RequestMapping(value = "/{id}", params = "form", method = RequestMethod.GET)
|
||||
public String SharkController.updateForm(@PathVariable("id") Long id, Model model) {
|
||||
model.addAttribute("loanShark", LoanShark.findLoanShark(id));
|
||||
return "loansharks/update";
|
||||
}
|
||||
|
||||
@RequestMapping(value = "/{id}", method = RequestMethod.DELETE)
|
||||
public String SharkController.delete(@PathVariable("id") Long id, @RequestParam(value = "page", required = false) Integer page, @RequestParam(value = "size", required = false) Integer size, Model model) {
|
||||
LoanShark.findLoanShark(id).remove();
|
||||
model.addAttribute("page", (page == null) ? "1" : page.toString());
|
||||
model.addAttribute("size", (size == null) ? "10" : size.toString());
|
||||
return "redirect:/loansharks?page=" + ((page == null) ? "1" : page.toString()) + "&size=" + ((size == null) ? "10" : size.toString());
|
||||
}
|
||||
|
||||
@RequestMapping(params = { "find=ByName", "form" }, method = RequestMethod.GET)
|
||||
public String SharkController.findLoanSharksByNameForm(Model model) {
|
||||
return "loansharks/findLoanSharksByName";
|
||||
}
|
||||
|
||||
@RequestMapping(params = "find=ByName", method = RequestMethod.GET)
|
||||
public String SharkController.findLoanSharksByName(@RequestParam("name") String name, Model model) {
|
||||
model.addAttribute("loansharks", LoanShark.findLoanSharksByName(name).getResultList());
|
||||
return "loansharks/list";
|
||||
}
|
||||
|
||||
Converter<LoanShark, String> SharkController.getLoanSharkConverter() {
|
||||
return new Converter<LoanShark, String>() {
|
||||
public String convert(LoanShark loanShark) {
|
||||
return new StringBuilder().append(loanShark.getName()).append(" ").append(loanShark.getCounter()).append(" ").append(loanShark.getAverageRate()).toString();
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
@InitBinder
|
||||
void SharkController.registerConverters(WebDataBinder binder) {
|
||||
if (binder.getConversionService() instanceof GenericConversionService) {
|
||||
GenericConversionService conversionService = (GenericConversionService) binder.getConversionService();
|
||||
conversionService.addConverter(getLoanSharkConverter());
|
||||
}
|
||||
}
|
||||
|
||||
@RequestMapping(value = "/{id}", method = RequestMethod.GET, headers = "Accept=application/json")
|
||||
@ResponseBody
|
||||
public String SharkController.showJson(@PathVariable("id") Long id) {
|
||||
return LoanShark.findLoanShark(id).toJson();
|
||||
}
|
||||
|
||||
@RequestMapping(method = RequestMethod.POST, headers = "Accept=application/json")
|
||||
public ResponseEntity<String> SharkController.createFromJson(@RequestBody String json) {
|
||||
LoanShark.fromJsonToLoanShark(json).persist();
|
||||
return new ResponseEntity<String>("LoanShark created", HttpStatus.CREATED);
|
||||
}
|
||||
|
||||
@RequestMapping(headers = "Accept=application/json")
|
||||
@ResponseBody
|
||||
public String SharkController.listJson() {
|
||||
return LoanShark.toJsonArray(LoanShark.findAllLoanSharks());
|
||||
}
|
||||
|
||||
@RequestMapping(value = "/jsonArray", method = RequestMethod.POST, headers = "Accept=application/json")
|
||||
public ResponseEntity<String> SharkController.createFromJsonArray(@RequestBody String json) {
|
||||
for (LoanShark loanshark: LoanShark.fromJsonArrayToLoanSharks(json)) {
|
||||
loanshark.persist();
|
||||
}
|
||||
return new ResponseEntity<String>("LoanShark created", HttpStatus.CREATED);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<persistence xmlns="http://java.sun.com/xml/ns/persistence" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="2.0" xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_2_0.xsd">
|
||||
<persistence-unit name="persistenceUnit" transaction-type="RESOURCE_LOCAL">
|
||||
<provider>org.hibernate.ejb.HibernatePersistence</provider>
|
||||
<properties>
|
||||
<property name="hibernate.dialect" value="org.hibernate.dialect.HSQLDialect"/>
|
||||
<!--value='create' to build a new database on each run; value='update' to modify an existing database; value='create-drop' means the same as 'create' but also drops tables when Hibernate closes; value='validate' makes no changes to the database-->
|
||||
<property name="hibernate.hbm2ddl.auto" value="create"/>
|
||||
<property name="hibernate.ejb.naming_strategy" value="org.hibernate.cfg.ImprovedNamingStrategy"/>
|
||||
</properties>
|
||||
</persistence-unit>
|
||||
</persistence>
|
||||
@@ -0,0 +1,64 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<beans xmlns="http://www.springframework.org/schema/beans" xmlns:aop="http://www.springframework.org/schema/aop" xmlns:context="http://www.springframework.org/schema/context" xmlns:jee="http://www.springframework.org/schema/jee" xmlns:tx="http://www.springframework.org/schema/tx" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-3.0.xsd http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-3.0.xsd http://www.springframework.org/schema/jee http://www.springframework.org/schema/jee/spring-jee-3.0.xsd http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx-3.0.xsd">
|
||||
<import resource="integrationContext.xml"/>
|
||||
<!--
|
||||
This will automatically locate any and all property files you have
|
||||
within your classpath, provided they fall under the META-INF/spring
|
||||
directory. The located property files are parsed and their values can
|
||||
then be used within application context files in the form of
|
||||
${propertyKey}.
|
||||
-->
|
||||
<context:property-placeholder location="classpath*:META-INF/spring/*.properties"/>
|
||||
<!--
|
||||
Turn on AspectJ @Configurable support. As a result, any time you
|
||||
instantiate an object, Spring will attempt to perform dependency
|
||||
injection on that object. This occurs for instantiation via the "new"
|
||||
keyword, as well as via reflection. This is possible because AspectJ
|
||||
is used to "weave" Roo-based applications at compile time. In effect
|
||||
this feature allows dependency injection of any object at all in your
|
||||
system, which is a very useful feature (without @Configurable you'd
|
||||
only be able to dependency inject objects acquired from Spring or
|
||||
subsequently presented to a specific Spring dependency injection
|
||||
method). Roo applications use this useful feature in a number of
|
||||
areas, such as @PersistenceContext injection into entities.
|
||||
-->
|
||||
<context:spring-configured/>
|
||||
<!--
|
||||
This declaration will cause Spring to locate every @Component,
|
||||
@Repository and @Service in your application. In practical terms this
|
||||
allows you to write a POJO and then simply annotate the new POJO as an
|
||||
@Service and Spring will automatically detect, instantiate and
|
||||
dependency inject your service at startup time. Importantly, you can
|
||||
then also have your new service injected into any other class that
|
||||
requires it simply by declaring a field for your service inside the
|
||||
relying class and Spring will inject it. Note that two exclude filters
|
||||
are declared. The first ensures that Spring doesn't spend time
|
||||
introspecting Roo-specific ITD aspects. The second ensures Roo doesn't
|
||||
instantiate your @Controller classes, as these should be instantiated
|
||||
by a web tier application context. Refer to web.xml for more details
|
||||
about the web tier application context setup services.
|
||||
|
||||
Furthermore, this turns on @Autowired, @PostConstruct etc support. These
|
||||
annotations allow you to use common Spring and Java Enterprise Edition
|
||||
annotations in your classes without needing to do any special configuration.
|
||||
The most commonly used annotation is @Autowired, which instructs Spring to
|
||||
dependency inject an object into your class.
|
||||
-->
|
||||
<context:component-scan base-package="org.springframework.integration.samples.loanbroker.loanshark">
|
||||
<context:exclude-filter expression=".*_Roo_.*" type="regex"/>
|
||||
<context:exclude-filter expression="org.springframework.stereotype.Controller" type="annotation"/>
|
||||
</context:component-scan>
|
||||
<bean class="org.apache.commons.dbcp.BasicDataSource" destroy-method="close" id="dataSource">
|
||||
<property name="driverClassName" value="${database.driverClassName}"/>
|
||||
<property name="url" value="${database.url}"/>
|
||||
<property name="username" value="${database.username}"/>
|
||||
<property name="password" value="${database.password}"/>
|
||||
</bean>
|
||||
<bean class="org.springframework.orm.jpa.JpaTransactionManager" id="transactionManager">
|
||||
<property name="entityManagerFactory" ref="entityManagerFactory"/>
|
||||
</bean>
|
||||
<tx:annotation-driven mode="aspectj" transaction-manager="transactionManager"/>
|
||||
<bean class="org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean" id="entityManagerFactory">
|
||||
<property name="dataSource" ref="dataSource"/>
|
||||
</bean>
|
||||
</beans>
|
||||
@@ -0,0 +1,6 @@
|
||||
#Updated at Tue Sep 07 17:11:44 EDT 2010
|
||||
#Tue Sep 07 17:11:44 EDT 2010
|
||||
database.password=
|
||||
database.url=jdbc\:hsqldb\:mem\:loanshark
|
||||
database.username=sa
|
||||
database.driverClassName=org.hsqldb.jdbcDriver
|
||||
@@ -0,0 +1,29 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<beans xmlns="http://www.springframework.org/schema/beans"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xmlns:int="http://www.springframework.org/schema/integration"
|
||||
xmlns:int-ip="http://www.springframework.org/schema/integration/ip"
|
||||
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd
|
||||
http://www.springframework.org/schema/integration http://www.springframework.org/schema/integration/spring-integration.xsd
|
||||
http://www.springframework.org/schema/integration/ip http://www.springframework.org/schema/integration/ip/spring-integration-ip.xsd">
|
||||
|
||||
<int-ip:udp-inbound-channel-adapter id="udpIn"
|
||||
channel="channel"
|
||||
multicast="true"
|
||||
multicast-address="225.6.7.8"
|
||||
port="11111"/>
|
||||
|
||||
<int:channel id="channel" />
|
||||
<int:transformer ref="transformer"
|
||||
input-channel="channel"
|
||||
output-channel="transformedChannel"/>
|
||||
<int:channel id="transformedChannel" />
|
||||
<int:service-activator
|
||||
id="activator"
|
||||
input-channel="transformedChannel"
|
||||
ref="accumulator" />
|
||||
|
||||
<bean id="accumulator" class="org.springframework.integration.samples.loanbroker.loanshark.biz.Accumulator" />
|
||||
<bean id="transformer" class="org.springframework.integration.samples.loanbroker.loanshark.biz.SharkTransformer" />
|
||||
|
||||
</beans>
|
||||
12
case-studies/loanshark/src/main/resources/log4j.properties
Normal file
@@ -0,0 +1,12 @@
|
||||
#Updated at Tue Sep 07 17:11:52 EDT 2010
|
||||
#Tue Sep 07 17:11:52 EDT 2010
|
||||
log4j.appender.stdout=org.apache.log4j.ConsoleAppender
|
||||
log4j.rootLogger=DEBUG, stdout
|
||||
log4j.appender.R.File=application.log
|
||||
log4j.appender.R.MaxFileSize=100KB
|
||||
log4j.appender.R.layout=org.apache.log4j.PatternLayout
|
||||
log4j.appender.R.MaxBackupIndex=1
|
||||
log4j.appender.R.layout.ConversionPattern=%p %t %c - %m%n
|
||||
log4j.appender.stdout.layout.ConversionPattern=%d [%t] %-5p %c - %m%n
|
||||
log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
|
||||
log4j.appender.R=org.apache.log4j.RollingFileAppender
|
||||
@@ -0,0 +1 @@
|
||||
styleSheet=resources/styles/alt.css
|
||||
@@ -0,0 +1 @@
|
||||
styleSheet=resources/styles/standard.css
|
||||
@@ -0,0 +1,14 @@
|
||||
#Updated at Tue Sep 07 17:11:50 EDT 2010
|
||||
#Tue Sep 07 17:11:50 EDT 2010
|
||||
label_org_springframework_integration_samples_loanbroker_loanshark_domain_loanshark_averagerate=Average Rate
|
||||
menu_item_loanshark_new_label=Loan Shark
|
||||
menu_item_loanshark_name_label=Name
|
||||
label_org_springframework_integration_samples_loanbroker_loanshark_domain_loanshark_version=Version
|
||||
application_name=Loanshark
|
||||
label_org_springframework_integration_samples_loanbroker_loanshark_domain_loanshark_name=Name
|
||||
label_org_springframework_integration_samples_loanbroker_loanshark_domain_loanshark_plural=Loan Sharks
|
||||
label_org_springframework_integration_samples_loanbroker_loanshark_domain_loanshark=Loan Shark
|
||||
menu_category_loanshark_label=Loan Shark
|
||||
label_org_springframework_integration_samples_loanbroker_loanshark_domain_loanshark_id=Id
|
||||
menu_item_loanshark_list_label=Loan Sharks
|
||||
label_org_springframework_integration_samples_loanbroker_loanshark_domain_loanshark_counter=Counter
|
||||
@@ -0,0 +1,98 @@
|
||||
#menu
|
||||
global_menu_new=Create new {0}
|
||||
global_menu_list=List all {0}
|
||||
global_menu_find=Find by {0}
|
||||
global_language_switch=Switch language to {0}
|
||||
global_language=Language
|
||||
global_sponsored=Sponsored by SpringSource
|
||||
global_theme=Theme
|
||||
global_theme_alt=alt
|
||||
global_theme_standard=standard
|
||||
global_generic={0}
|
||||
|
||||
#welcome page
|
||||
welcome_titlepane=Welcome to {0}
|
||||
welcome_h3=Welcome to {0}
|
||||
welcome_text=Spring Roo provides interactive, lightweight and user customizable tooling that enables rapid delivery of high performance enterprise Java applications.
|
||||
|
||||
#entity labels
|
||||
entity_list_all=List all {0}
|
||||
entity_show=Show {0}
|
||||
entity_create=Create new {0}
|
||||
entity_update=Update {0}
|
||||
entity_delete=Delete {0}
|
||||
entity_find=Find by {0}
|
||||
entity_not_found=No {0} found.
|
||||
entity_not_found_single=No {0} found with this id.
|
||||
entity_dependency_required=The following dependencies need to be created first:
|
||||
entity_reference_not_managed=This relationship is managed from the {0} side.
|
||||
|
||||
#button labels
|
||||
button_home=Home
|
||||
button_save=Save
|
||||
button_update=Update
|
||||
button_find=Find
|
||||
button_cancel=Cancel
|
||||
button_proceed=Proceed
|
||||
button_submit=Submit
|
||||
button_reset=Reset
|
||||
button_end=End
|
||||
button_showmessage=Show Message
|
||||
button_showstacktrace=Show Stack Trace
|
||||
button_showcookie=Show Cookie
|
||||
|
||||
#field labels
|
||||
field_simple_validation=Enter {0} {1}
|
||||
field_invalid_email=Please enter a valid email
|
||||
field_invalid_number=Number with \\'-\\' or \\'.\\' allowed
|
||||
field_invalid_integer=Integer numbers only
|
||||
field_invalid=Please enter valid {0}
|
||||
field_required=required
|
||||
|
||||
#list labels
|
||||
list_first=First Page
|
||||
list_next=Next Page
|
||||
list_previous=Previous Page
|
||||
list_last=Last Page
|
||||
list_page=Page {0} of {1}
|
||||
list_size=List results per page:
|
||||
|
||||
#selenium
|
||||
selenium_menu_test_suite=Test Suite
|
||||
|
||||
#exception
|
||||
exception_message=Exception Message
|
||||
exception_stacktrace=Exception Stack Trace
|
||||
exception_cookie=Cookies
|
||||
exception_details=Details
|
||||
|
||||
#dataAccessFailure_jspx
|
||||
error_dataaccessfailure_title=Data access failure
|
||||
error_dataaccessfailure_problemdescription=Sorry, a problem occurred while accessing the database.
|
||||
|
||||
#resourceNotFound_jspx
|
||||
error_resourcenotfound_title=Requested Resource Not Found
|
||||
error_resourcenotfound_problemdescription=Sorry, we did not find the resource you were looking for.
|
||||
|
||||
#uncaughtException_jspx
|
||||
error_uncaughtexception_title=Internal Error
|
||||
error_uncaughtexception_problemdescription=Sorry, we encountered an internal error.
|
||||
|
||||
#webflow
|
||||
webflow_menu_enter=Enter {0} WebFlow
|
||||
webflow_state1_title=Spring WebFlow - View State One
|
||||
webflow_state1_message=This is a simple example to get started with Spring Web Flow. The buttons below lead you to another view state (Proceed) or to an end state.
|
||||
webflow_state2_title=Spring WebFlow - View State Two
|
||||
webflow_state2_message=This is a simple example to get started with Spring Web Flow. The buttons below lead you to another view state (Proceed) or to an end state.
|
||||
webflow_endstate_title=Spring WebFlow - End State
|
||||
webflow_endstate_message=You have now reached the end of this flow.
|
||||
|
||||
#security
|
||||
security_login_title=Spring Security Login
|
||||
security_login_message=You have tried to access a protected area of this application. By default you can login as "admin", with a password of "admin".
|
||||
security_login_form_name=Name
|
||||
security_login_form_name_message=Enter your name
|
||||
security_login_form_password=Password
|
||||
security_login_form_password_message=Enter your password
|
||||
security_login_unsuccessful=Your login attempt was not successful, try again. Reason:
|
||||
security_logout=Logout
|
||||
@@ -0,0 +1,27 @@
|
||||
<html xmlns:jsp="http://java.sun.com/JSP/Page" xmlns:c="http://java.sun.com/jsp/jstl/core" xmlns:tiles="http://tiles.apache.org/tags-tiles" xmlns:spring="http://www.springframework.org/tags" xmlns:util="urn:jsptagdir:/WEB-INF/tags/util" >
|
||||
|
||||
<jsp:output doctype-root-element="HTML" doctype-system="about:legacy-compat" />
|
||||
|
||||
<jsp:directive.page contentType="text/html;charset=UTF-8" />
|
||||
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=8" />
|
||||
|
||||
<util:load-scripts />
|
||||
|
||||
<spring:message code="application_name" var="app_name"/>
|
||||
<title><spring:message code="welcome_h3" arguments="${app_name}" /></title>
|
||||
</head>
|
||||
|
||||
<body class="tundra spring">
|
||||
<div id="wrapper">
|
||||
<tiles:insertAttribute name="header" ignore="true" />
|
||||
<tiles:insertAttribute name="menu" ignore="true" />
|
||||
<div id="main">
|
||||
<tiles:insertAttribute name="body"/>
|
||||
<tiles:insertAttribute name="footer" ignore="true"/>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,19 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE tiles-definitions PUBLIC
|
||||
"-//Apache Software Foundation//DTD Tiles Configuration 2.1//EN"
|
||||
"http://tiles.apache.org/dtds/tiles-config_2_1.dtd">
|
||||
|
||||
<tiles-definitions>
|
||||
|
||||
<definition name="default" template="/WEB-INF/layouts/default.jspx">
|
||||
<put-attribute name="header" value="/WEB-INF/views/header.jspx" />
|
||||
<put-attribute name="menu" value="/WEB-INF/views/menu.jspx" />
|
||||
<put-attribute name="footer" value="/WEB-INF/views/footer.jspx" />
|
||||
</definition>
|
||||
|
||||
<definition name="public" template="/WEB-INF/layouts/default.jspx">
|
||||
<put-attribute name="header" value="/WEB-INF/views/header.jspx" />
|
||||
<put-attribute name="footer" value="/WEB-INF/views/footer.jspx" />
|
||||
</definition>
|
||||
|
||||
</tiles-definitions>
|
||||
@@ -0,0 +1,76 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<beans xmlns="http://www.springframework.org/schema/beans" xmlns:context="http://www.springframework.org/schema/context" xmlns:mvc="http://www.springframework.org/schema/mvc" xmlns:p="http://www.springframework.org/schema/p" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-3.0.xsd http://www.springframework.org/schema/mvc http://www.springframework.org/schema/mvc/spring-mvc-3.0.xsd">
|
||||
|
||||
<!-- The controllers are autodetected POJOs labeled with the @Controller annotation. -->
|
||||
<context:component-scan base-package="org.springframework.integration.samples.loanbroker.loanshark" use-default-filters="false">
|
||||
<context:include-filter expression="org.springframework.stereotype.Controller" type="annotation"/>
|
||||
</context:component-scan>
|
||||
|
||||
<!-- Turns on support for mapping requests to Spring MVC @Controller methods
|
||||
Also registers default Formatters and Validators for use across all @Controllers -->
|
||||
<mvc:annotation-driven/>
|
||||
|
||||
<!-- Handles HTTP GET requests for /resources/** by efficiently serving up static resources -->
|
||||
<mvc:resources location="classpath:/META-INF/dojo/" mapping="/resources/dojo/**"/>
|
||||
<mvc:resources location="classpath:/META-INF/dijit/" mapping="/resources/dijit/**"/>
|
||||
<mvc:resources location="classpath:/META-INF/spring/" mapping="/resources/spring/**"/>
|
||||
<mvc:resources location="/" mapping="/resources/**"/>
|
||||
|
||||
<!-- Allows for mapping the DispatcherServlet to "/" by forwarding static resource requests to the container's default Servlet -->
|
||||
<mvc:default-servlet-handler/>
|
||||
|
||||
<!-- register "global" interceptor beans to apply to all registered HandlerMappings -->
|
||||
<mvc:interceptors>
|
||||
<bean class="org.springframework.web.servlet.theme.ThemeChangeInterceptor"/>
|
||||
<bean class="org.springframework.web.servlet.i18n.LocaleChangeInterceptor" p:paramName="lang"/>
|
||||
</mvc:interceptors>
|
||||
|
||||
<!-- selects a static view for rendering without the need for an explicit controller -->
|
||||
<mvc:view-controller path="/" view-name="index"/>
|
||||
<mvc:view-controller path="/uncaughtException"/>
|
||||
<mvc:view-controller path="/resourceNotFound"/>
|
||||
<mvc:view-controller path="/dataAccessFailure"/>
|
||||
|
||||
<!-- Resolves localized messages*.properties and application.properties files in the application to allow for internationalization.
|
||||
The messages*.properties files translate Roo generated messages which are part of the admin interface, the application.properties
|
||||
resource bundle localizes all application specific messages such as entity names and menu items. -->
|
||||
<bean class="org.springframework.context.support.ReloadableResourceBundleMessageSource" id="messageSource" p:basenames="WEB-INF/i18n/messages,WEB-INF/i18n/application" p:fallbackToSystemLocale="false"/>
|
||||
|
||||
<!-- store preferred language configuration in a cookie -->
|
||||
<bean class="org.springframework.web.servlet.i18n.CookieLocaleResolver" id="localeResolver" p:cookieName="locale"/>
|
||||
|
||||
<!-- resolves localized <theme_name>.properties files in the classpath to allow for theme support -->
|
||||
<bean class="org.springframework.ui.context.support.ResourceBundleThemeSource" id="themeSource"/>
|
||||
|
||||
<!-- store preferred theme configuration in a cookie -->
|
||||
<bean class="org.springframework.web.servlet.theme.CookieThemeResolver" id="themeResolver" p:cookieName="theme" p:defaultThemeName="standard"/>
|
||||
|
||||
<!-- This bean resolves specific types of exceptions to corresponding logical - view names for error views.
|
||||
The default behaviour of DispatcherServlet - is to propagate all exceptions to the servlet container:
|
||||
this will happen - here with all other types of exceptions. -->
|
||||
<bean class="org.springframework.web.servlet.handler.SimpleMappingExceptionResolver" p:defaultErrorView="uncaughtException">
|
||||
<property name="exceptionMappings">
|
||||
<props>
|
||||
<prop key=".DataAccessException">dataAccessFailure</prop>
|
||||
<prop key=".NoSuchRequestHandlingMethodException">resourceNotFound</prop>
|
||||
<prop key=".TypeMismatchException">resourceNotFound</prop>
|
||||
<prop key=".MissingServletRequestParameterException">resourceNotFound</prop>
|
||||
</props>
|
||||
</property>
|
||||
</bean>
|
||||
|
||||
<!-- allows for integration of file upload functionality -->
|
||||
<bean class="org.springframework.web.multipart.commons.CommonsMultipartResolver" id="multipartResolver"/>
|
||||
<bean class="org.springframework.web.servlet.view.UrlBasedViewResolver" id="tilesViewResolver">
|
||||
<property name="viewClass" value="org.springframework.web.servlet.view.tiles2.TilesView"/>
|
||||
</bean>
|
||||
<bean class="org.springframework.web.servlet.view.tiles2.TilesConfigurer" id="tilesConfigurer">
|
||||
<property name="definitions">
|
||||
<list>
|
||||
<value>/WEB-INF/layouts/layouts.xml</value>
|
||||
<!-- Scan views directory for Tiles configurations -->
|
||||
<value>/WEB-INF/views/**/views.xml</value>
|
||||
</list>
|
||||
</property>
|
||||
</bean>
|
||||
</beans>
|
||||
@@ -0,0 +1,29 @@
|
||||
<jsp:root xmlns:c="http://java.sun.com/jsp/jstl/core" xmlns:fn="http://java.sun.com/jsp/jstl/functions" xmlns:util="urn:jsptagdir:/WEB-INF/tags/util" xmlns:form="http://www.springframework.org/tags/form" xmlns:jsp="http://java.sun.com/JSP/Page" xmlns:spring="http://www.springframework.org/tags" version="2.0">
|
||||
<jsp:output omit-xml-declaration="yes"/>
|
||||
<jsp:directive.attribute name="id" type="java.lang.String" required="true" description="The identifier for this tag (do not change!)"/>
|
||||
<jsp:directive.attribute name="modelAttribute" type="java.lang.String" required="true" description="The name of the model attribute for form binding"/>
|
||||
<jsp:directive.attribute name="path" type="java.lang.String" required="true" description="Specify the relative URL path (wit leading /)" />
|
||||
<jsp:directive.attribute name="label" type="java.lang.String" required="false" description="The label used for this object, will default to a message bundle if not supplied"/>
|
||||
<jsp:directive.attribute name="render" type="java.lang.Boolean" required="false" description="Indicate if the contents of this tag and all enclosed tags should be rendered (default 'true')" />
|
||||
<jsp:directive.attribute name="openPane" type="java.lang.Boolean" required="false" description="Control if the title pane is opened or closed by default (default: true)"/>
|
||||
<jsp:directive.attribute name="z" type="java.lang.String" required="false" description="Used for checking if element has been modified (to recalculate simply provide empty string value)"/>
|
||||
|
||||
<c:if test="${empty render or render}">
|
||||
<c:if test="${empty label}">
|
||||
<spring:message code="label_${fn:toLowerCase(fn:substringAfter(id,'_'))}" var="label"/>
|
||||
</c:if>
|
||||
<spring:message arguments="${label}" code="entity_create" var="title_msg"/>
|
||||
<util:panel id="${id}" title="${title_msg}" openPane="${openPane}">
|
||||
<spring:url value="${path}" var="form_url"/>
|
||||
<form:form action="${fn:escapeXml(form_url)}" method="POST" modelAttribute="${modelAttribute}">
|
||||
<form:errors cssClass="errors" delimiter="<p/>"/>
|
||||
<jsp:doBody />
|
||||
<div class="submit" id="${fn:escapeXml(id)}_submit">
|
||||
<spring:message code="button_save" var="save_button"/>
|
||||
<script type="text/javascript">Spring.addDecoration(new Spring.ValidateAllDecoration({elementId:'proceed', event:'onclick'}));</script>
|
||||
<input id="proceed" type="submit" value="${fn:escapeXml(save_button)}"/>
|
||||
</div>
|
||||
</form:form>
|
||||
</util:panel>
|
||||
</c:if>
|
||||
</jsp:root>
|
||||
@@ -0,0 +1,25 @@
|
||||
<jsp:root xmlns:c="http://java.sun.com/jsp/jstl/core" xmlns:fn="http://java.sun.com/jsp/jstl/functions" xmlns:util="urn:jsptagdir:/WEB-INF/tags/util" xmlns:field="urn:jsptagdir:/WEB-INF/tags/form/fields" xmlns:form="http://www.springframework.org/tags/form" xmlns:jsp="http://java.sun.com/JSP/Page" xmlns:spring="http://www.springframework.org/tags" version="2.0">
|
||||
<jsp:output omit-xml-declaration="yes"/>
|
||||
|
||||
<jsp:directive.attribute name="id" type="java.lang.String" required="true" description="The identifier for this tag (do not change!)"/>
|
||||
<jsp:directive.attribute name="dependencies" type="java.util.Collection" required="true" description="The collection of dependencies which need to be listed"/>
|
||||
<jsp:directive.attribute name="label" type="java.lang.String" required="false" description="The label used for this object, will default to a message bundle if not supplied"/>
|
||||
<jsp:directive.attribute name="render" type="java.lang.Boolean" required="false" description="Indicate if the contents of this tag and all enclosed tags should be rendered (default 'true')" />
|
||||
<jsp:directive.attribute name="openPane" type="java.lang.Boolean" required="false" description="Control if the title pane is opened or closed by default (default: true)"/>
|
||||
<jsp:directive.attribute name="z" type="java.lang.String" required="false" description="Used for checking if element has been modified (to recalculate simply provide empty string value)"/>
|
||||
|
||||
<c:if test="${empty render or render}">
|
||||
<c:if test="${empty label}">
|
||||
<spring:message code="label_${fn:toLowerCase(fn:substringAfter(id,'_'))}" var="label"/>
|
||||
</c:if>
|
||||
<spring:message arguments="${label}" code="entity_create" var="title_msg"/>
|
||||
<util:panel id="${fn:escapeXml(id)}" title="${fn:escapeXml(title_msg)}" openPane="${openPane}">
|
||||
<spring:message code="entity_dependency_required"/>
|
||||
<c:forEach items="${dependencies}" var="dependency" >
|
||||
<p>
|
||||
<field:reference field="${dependency[0]}" id="${fn:escapeXml(id)}_${dependency[0]}" path="/${dependency[1]}"/>
|
||||
</p>
|
||||
</c:forEach>
|
||||
</util:panel>
|
||||
</c:if>
|
||||
</jsp:root>
|
||||
@@ -0,0 +1,37 @@
|
||||
<jsp:root xmlns:c="http://java.sun.com/jsp/jstl/core" xmlns:fn="http://java.sun.com/jsp/jstl/functions" xmlns:spring="http://www.springframework.org/tags" xmlns:form="http://www.springframework.org/tags/form" xmlns:jsp="http://java.sun.com/JSP/Page" version="2.0">
|
||||
<jsp:output omit-xml-declaration="yes" />
|
||||
|
||||
<jsp:directive.attribute name="id" type="java.lang.String" required="true" description="The identifier for this tag (do not change!)" />
|
||||
<jsp:directive.attribute name="field" type="java.lang.String" required="true" description="The field exposed from the form backing object" />
|
||||
<jsp:directive.attribute name="label" type="java.lang.String" required="false" description="The label used for this field, will default to a message bundle if not supplied" />
|
||||
<jsp:directive.attribute name="disableFormBinding" type="java.lang.Boolean" required="false" description="Set to true to disable Spring form binding" />
|
||||
<jsp:directive.attribute name="render" type="java.lang.Boolean" required="false" description="Indicate if the contents of this tag and all enclosed tags should be rendered (default 'true')" />
|
||||
<jsp:directive.attribute name="z" type="java.lang.String" required="false" description="Used for checking if element has been modified (to recalculate simply provide empty string value)" />
|
||||
|
||||
<c:if test="${empty render or render}">
|
||||
<c:if test="${empty sec_label}">
|
||||
<spring:message code="label_${fn:toLowerCase(fn:substringAfter(id,'_'))}" var="label" />
|
||||
</c:if>
|
||||
<c:set var="sec_field">
|
||||
<spring:escapeBody javaScriptEscape="true">${field}</spring:escapeBody>
|
||||
</c:set>
|
||||
|
||||
<div id="_${sec_id}_id">
|
||||
<label for="_${sec_field}_id">
|
||||
<c:out value="${fn:escapeXml(label)}" />:
|
||||
</label>
|
||||
<c:choose>
|
||||
<c:when test="${disableFormBinding}">
|
||||
<input id="_${sec_field}_id" name="${sec_field}" type="checkbox" value="true" />
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<form:checkbox id="_${sec_field}_id" path="${sec_field}" />
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
<script type="text/javascript">
|
||||
Spring.addDecoration(new Spring.ElementDecoration({elementId : '_${sec_field}_id', widgetType : 'dijit.form.CheckBox'}));
|
||||
</script>
|
||||
</div>
|
||||
<br />
|
||||
</c:if>
|
||||
</jsp:root>
|
||||
@@ -0,0 +1,28 @@
|
||||
<jsp:root xmlns:c="http://java.sun.com/jsp/jstl/core" xmlns:fn="http://java.sun.com/jsp/jstl/functions" xmlns:util="urn:jsptagdir:/WEB-INF/tags/util" xmlns:spring="http://www.springframework.org/tags" xmlns:form="http://www.springframework.org/tags/form" xmlns:jsp="http://java.sun.com/JSP/Page" version="2.0">
|
||||
<jsp:output omit-xml-declaration="yes" />
|
||||
|
||||
<jsp:directive.attribute name="id" type="java.lang.String" required="true" description="The identifier for this tag (do not change!)" />
|
||||
<jsp:directive.attribute name="property" type="java.lang.String" required="true" description="The property (field name) of the dataset to be displayed in a column (required)." />
|
||||
<jsp:directive.attribute name="maxLength" type="java.lang.Integer" required="false" description="Max displayed text length (default '10'). Unlimited if negative" />
|
||||
<jsp:directive.attribute name="label" type="java.lang.String" required="false" description="The column label to be used in the table (optional)." />
|
||||
<jsp:directive.attribute name="render" type="java.lang.Boolean" required="false" description="Indicate if the contents of this tag and all enclosed tags should be rendered (default 'true')" />
|
||||
<jsp:directive.attribute name="z" type="java.lang.String" required="false" description="Used for checking if element has been modified (to recalculate simply provide empty string value)" />
|
||||
|
||||
<c:if test="${empty render or render}">
|
||||
<c:if test="${empty label}">
|
||||
<spring:message code="label_${fn:toLowerCase(fn:substringAfter(id,'_'))}" var="label" />
|
||||
</c:if>
|
||||
<c:choose>
|
||||
<c:when test="${empty columnProperties and empty columnLabels}">
|
||||
<c:set var="columnProperties" value="${property}" scope="request" />
|
||||
<c:set var="columnLabels" value="${label}" scope="request" />
|
||||
<c:set var="columnMaxLengths" value="${empty maxLength ? 10 : maxLength}" scope="request" />
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<c:set var="columnProperties" value="${columnProperties},${property}" scope="request" />
|
||||
<c:set var="columnLabels" value="${columnLabels},${label}" scope="request" />
|
||||
<c:set var="columnMaxLengths" value="${columnMaxLengths},${empty maxLength ? 10 : maxLength}" scope="request" />
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
</c:if>
|
||||
</jsp:root>
|
||||
@@ -0,0 +1,75 @@
|
||||
<jsp:root xmlns:c="http://java.sun.com/jsp/jstl/core" xmlns:fn="http://java.sun.com/jsp/jstl/functions" xmlns:spring="http://www.springframework.org/tags" xmlns:form="http://www.springframework.org/tags/form" xmlns:jsp="http://java.sun.com/JSP/Page" version="2.0">
|
||||
<jsp:output omit-xml-declaration="yes" />
|
||||
|
||||
<jsp:directive.attribute name="id" type="java.lang.String" required="true" description="The identifier for this tag (do not change!)" />
|
||||
<jsp:directive.attribute name="field" type="java.lang.String" required="true" description="The field exposed from the form backing object" />
|
||||
<jsp:directive.attribute name="dateTimePattern" type="java.lang.String" required="true" description="The format accepted in this field" />
|
||||
<jsp:directive.attribute name="label" type="java.lang.String" required="false" description="The label used for this field, will default to a message bundle if not supplied" />
|
||||
<jsp:directive.attribute name="required" type="java.lang.Boolean" required="false" description="Indicates if this field is required (default false)" />
|
||||
<jsp:directive.attribute name="disabled" type="java.lang.Boolean" required="false" description="Specify if this field should be enabled" />
|
||||
<jsp:directive.attribute name="validationRegex" type="java.lang.String" required="false" description="Specify regular expression to be used for the validation of the input contents" />
|
||||
<jsp:directive.attribute name="validationMessageCode" type="java.lang.String" required="false" description="Specify the message (message property code) to be displayed if the regular expression validation fails" />
|
||||
<jsp:directive.attribute name="validationMessage" type="java.lang.String" required="false" description="Specify the message to be displayed if the regular expression validation fails" />
|
||||
<jsp:directive.attribute name="future" type="java.lang.Boolean" required="false" description="Specify if the date / time should be in the future" />
|
||||
<jsp:directive.attribute name="past" type="java.lang.Boolean" required="false" description="Specify if the date / time should be in the past" />
|
||||
<jsp:directive.attribute name="disableFormBinding" type="java.lang.Boolean" required="false" description="Set to true to disable Spring form binding" />
|
||||
<jsp:directive.attribute name="render" type="java.lang.Boolean" required="false" description="Indicate if the contents of this tag and all enclosed tags should be rendered (default 'true')" />
|
||||
<jsp:directive.attribute name="z" type="java.lang.String" required="false" description="Used for checking if element has been modified (to recalculate simply provide empty string value)" />
|
||||
|
||||
<c:if test="${empty render or render}">
|
||||
|
||||
<c:if test="${empty disabled}">
|
||||
<c:set value="false" var="disabled" />
|
||||
</c:if>
|
||||
<c:if test="${empty label}">
|
||||
<spring:message code="label_${fn:toLowerCase(fn:substringAfter(id,'_'))}" var="label" />
|
||||
</c:if>
|
||||
<c:set var="sec_field">
|
||||
<spring:escapeBody javaScriptEscape="true" >${field}</spring:escapeBody>
|
||||
</c:set>
|
||||
|
||||
<c:if test="${empty required}">
|
||||
<c:set value="false" var="required" />
|
||||
</c:if>
|
||||
|
||||
<script type="text/javascript">dojo.require('dijit.form.DateTextBox')</script>
|
||||
<div id="_${sec_id}_id">
|
||||
<label for="_${sec_field}_id">
|
||||
<c:out value="${label}" />
|
||||
:
|
||||
</label>
|
||||
<c:choose>
|
||||
<c:when test="${disableFormBinding}">
|
||||
<input id="_${sec_field}_id" name="${sec_field}" />
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<form:input id="_${sec_field}_id" path="${sec_field}" disabled="${disabled}" />
|
||||
<br />
|
||||
<form:errors cssClass="errors" id="_${sec_field}_error_id" path="${sec_field}" />
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
<spring:message arguments="${fn:escapeXml(label)}" code="field_invalid" var="field_invalid" />
|
||||
<c:choose>
|
||||
<c:when test="${required}">
|
||||
<spring:message code="field_required" var="field_required" />
|
||||
<spring:message argumentSeparator="," arguments="${label},(${field_required})" code="field_simple_validation" var="field_validation" />
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<spring:message argumentSeparator="," arguments="${label}, " code="field_simple_validation" var="field_validation" />
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
<script type="text/javascript">
|
||||
<c:set var="sec_field_validation">
|
||||
<spring:escapeBody javaScriptEscape="true">${field_validation}</spring:escapeBody>
|
||||
</c:set>
|
||||
<c:set var="sec_field_invalid">
|
||||
<spring:escapeBody javaScriptEscape="true">${field_invalid}</spring:escapeBody>
|
||||
</c:set>
|
||||
<c:set var="sec_dateTimePattern">
|
||||
<spring:escapeBody javaScriptEscape="true">${dateTimePattern}</spring:escapeBody>
|
||||
</c:set>
|
||||
Spring.addDecoration(new Spring.ElementDecoration({elementId : '_${sec_field}_id', widgetType : 'dijit.form.DateTextBox', widgetAttrs : {promptMessage: '${sec_field_validation}', invalidMessage: '${sec_field_invalid}', required: ${required}, constraints: {datePattern : '${sec_dateTimePattern}', required : ${required}}, datePattern : '${sec_dateTimePattern}'}})); </script>
|
||||
</div>
|
||||
<br />
|
||||
</c:if>
|
||||
</jsp:root>
|
||||
@@ -0,0 +1,51 @@
|
||||
<jsp:root xmlns:c="http://java.sun.com/jsp/jstl/core" xmlns:fn="http://java.sun.com/jsp/jstl/functions" xmlns:fmt="http://java.sun.com/jsp/jstl/fmt" xmlns:spring="http://www.springframework.org/tags" xmlns:form="http://www.springframework.org/tags/form" xmlns:jsp="http://java.sun.com/JSP/Page" version="2.0">
|
||||
<jsp:output omit-xml-declaration="yes" />
|
||||
|
||||
<jsp:directive.attribute name="id" type="java.lang.String" required="true" description="The identifier for this tag (do not change!)" />
|
||||
<jsp:directive.attribute name="object" type="java.lang.Object" required="true" description="The form backing object" />
|
||||
<jsp:directive.attribute name="field" type="java.lang.String" required="true" description="The field name" />
|
||||
<jsp:directive.attribute name="label" type="java.lang.String" required="false" description="The label used for this field, will default to a message bundle if not supplied" />
|
||||
<jsp:directive.attribute name="date" type="java.lang.Boolean" required="false" description="Indicate that this field is of type java.util.Date" />
|
||||
<jsp:directive.attribute name="calendar" type="java.lang.Boolean" required="false" description="Indicate that this field is of type java.util.Calendar" />
|
||||
<jsp:directive.attribute name="dateTimePattern" type="java.lang.String" required="false" description="The date / time pattern to use if the field is a date or calendar type" />
|
||||
<jsp:directive.attribute name="render" type="java.lang.Boolean" required="false" description="Indicate if the contents of this tag and all enclosed tags should be rendered (default 'true')" />
|
||||
<jsp:directive.attribute name="z" type="java.lang.String" required="false" description="Used for checking if element has been modified (to recalculate simply provide empty string value)" />
|
||||
|
||||
<c:if test="${empty render or render}">
|
||||
<c:if test="${not empty object and empty label}">
|
||||
<spring:message code="label_${fn:toLowerCase(fn:substringAfter(id,'_'))}" var="label" />
|
||||
</c:if>
|
||||
|
||||
<c:if test="${empty dateTimePattern}">
|
||||
<c:set value="MM/dd/yyyy" var="dateTimePattern" />
|
||||
</c:if>
|
||||
|
||||
<c:set var="sec_object" value="${fn:escapeXml(object)}" />
|
||||
<c:set var="sec_field" value="${fn:escapeXml(field)}" />
|
||||
|
||||
<div id="_${fn:escapeXml(id)}_id">
|
||||
<label for="_${fn:escapeXml(field)}_id">
|
||||
<c:out value="${label}" />
|
||||
:
|
||||
</label>
|
||||
<div class="box" id="_${fn:escapeXml(id)}_${fn:escapeXml(field)}_id">
|
||||
<c:choose>
|
||||
<c:when test="${date}">
|
||||
<spring:escapeBody>
|
||||
<fmt:formatDate value="${object[field]}" pattern="${fn:escapeXml(dateTimePattern)}" />
|
||||
</spring:escapeBody>
|
||||
</c:when>
|
||||
<c:when test="${calendar}">
|
||||
<spring:escapeBody>
|
||||
<fmt:formatDate value="${object[field].time}" pattern="${fn:escapeXml(dateTimePattern)}" />
|
||||
</spring:escapeBody>
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<spring:eval expression="object[field]" />
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
</div>
|
||||
</div>
|
||||
<br />
|
||||
</c:if>
|
||||
</jsp:root>
|
||||
@@ -0,0 +1,46 @@
|
||||
<jsp:root xmlns:c="http://java.sun.com/jsp/jstl/core" xmlns:fn="http://java.sun.com/jsp/jstl/functions" xmlns:spring="http://www.springframework.org/tags" xmlns:form="http://www.springframework.org/tags/form" xmlns:jsp="http://java.sun.com/JSP/Page" version="2.0">
|
||||
<jsp:output omit-xml-declaration="yes" />
|
||||
|
||||
<jsp:directive.attribute name="id" type="java.lang.String" required="true" description="The identifier for this tag (do not change!)" />
|
||||
<jsp:directive.attribute name="field" type="java.lang.String" required="true" description="The field exposed from the form backing object" />
|
||||
<jsp:directive.attribute name="label" type="java.lang.String" required="false" description="The label used for this field, will default to a message bundle if not supplied" />
|
||||
<jsp:directive.attribute name="required" type="java.lang.Boolean" required="false" description="Indicates if this field is required (default false)" />
|
||||
<jsp:directive.attribute name="disabled" type="java.lang.Boolean" required="false" description="Specify if this field should be enabled" />
|
||||
<jsp:directive.attribute name="validationRegex" type="java.lang.String" required="false" description="Specify regular expression to be used for the validation of the input contents" />
|
||||
<jsp:directive.attribute name="validationMessageCode" type="java.lang.String" required="false" description="Specify the message (message property code) to be displayed if the regular expression validation fails" />
|
||||
<jsp:directive.attribute name="validationMessage" type="java.lang.String" required="false" description="Specify the message to be displayed if the regular expression validation fails" />
|
||||
<jsp:directive.attribute name="render" type="java.lang.Boolean" required="false" description="Indicate if the contents of this tag and all enclosed tags should be rendered (default 'true')" />
|
||||
<jsp:directive.attribute name="z" type="java.lang.String" required="false" description="Used for checking if element has been modified (to recalculate simply provide empty string value)" />
|
||||
|
||||
<c:if test="${empty render or render}">
|
||||
|
||||
<c:if test="${empty disabled}">
|
||||
<c:set value="false" var="disabled" />
|
||||
</c:if>
|
||||
|
||||
<c:if test="${empty label}">
|
||||
<spring:message code="label_${fn:toLowerCase(fn:substringAfter(id,'_'))}" var="label" />
|
||||
</c:if>
|
||||
|
||||
<c:if test="${empty required}">
|
||||
<c:set value="false" var="required" />
|
||||
</c:if>
|
||||
|
||||
<c:set var="sec_field">
|
||||
<spring:escapeBody javaScriptEscape="true" >${field}</spring:escapeBody>
|
||||
</c:set>
|
||||
|
||||
<script type="text/javascript">dojo.require("dijit.Editor");</script>
|
||||
<div id="_${fn:escapeXml(id)}_id">
|
||||
<label for="_${sec_field}_id">
|
||||
<c:out value="${fn:escapeXml(label)}" />
|
||||
:
|
||||
</label>
|
||||
<form:textarea id="_${sec_field}_id" path="${sec_field}" disabled="${disabled}" />
|
||||
<br />
|
||||
<form:errors cssClass="errors" id="_${sec_field}_error_id" path="${sec_field}" />
|
||||
<script type="text/javascript">Spring.addDecoration(new Spring.ElementDecoration({elementId : '_${sec_field}_id', widgetType : 'dijit.Editor', widgetAttrs : {disabled: ${disabled}}})); </script>
|
||||
</div>
|
||||
<br />
|
||||
</c:if>
|
||||
</jsp:root>
|
||||
@@ -0,0 +1,75 @@
|
||||
<jsp:root xmlns:c="http://java.sun.com/jsp/jstl/core" xmlns:fn="http://java.sun.com/jsp/jstl/functions" xmlns:spring="http://www.springframework.org/tags" xmlns:form="http://www.springframework.org/tags/form" xmlns:jsp="http://java.sun.com/JSP/Page" version="2.0">
|
||||
<jsp:output omit-xml-declaration="yes" />
|
||||
|
||||
<jsp:directive.attribute name="id" type="java.lang.String" required="true" description="The identifier for this tag (do not change!)" />
|
||||
<jsp:directive.attribute name="field" type="java.lang.String" required="true" description="The field exposed from the form backing object" />
|
||||
<jsp:directive.attribute name="label" type="java.lang.String" required="false" description="The label used for this field, will default to a message bundle if not supplied" />
|
||||
<jsp:directive.attribute name="required" type="java.lang.Boolean" required="false" description="Indicates if this field is required (default false)" />
|
||||
<jsp:directive.attribute name="disabled" type="java.lang.Boolean" required="false" description="Specify if this field should be enabled" />
|
||||
<jsp:directive.attribute name="validationRegex" type="java.lang.String" required="false" description="Specify regular expression to be used for the validation of the input contents" />
|
||||
<jsp:directive.attribute name="validationMessageCode" type="java.lang.String" required="false" description="Specify the message (message property code) to be displayed if the regular expression validation fails" />
|
||||
<jsp:directive.attribute name="validationMessage" type="java.lang.String" required="false" description="Specify the message to be displayed if the regular expression validation fails" />
|
||||
<jsp:directive.attribute name="min" type="java.lang.String" required="false" description="Specify the minimum length of the input contents" />
|
||||
<jsp:directive.attribute name="max" type="java.lang.String" required="false" description="Specify the maximum length of the input contents" />
|
||||
<jsp:directive.attribute name="decimalMin" type="java.lang.String" required="false" description="Specify the minimum size of the input contents" />
|
||||
<jsp:directive.attribute name="decimalMax" type="java.lang.String" required="false" description="Specify the maximum size of the input contents" />
|
||||
<jsp:directive.attribute name="disableFormBinding" type="java.lang.Boolean" required="false" description="Set to true to disable Spring form binding" />
|
||||
<jsp:directive.attribute name="render" type="java.lang.Boolean" required="false" description="Indicate if the contents of this tag and all enclosed tags should be rendered (default 'true')" />
|
||||
<jsp:directive.attribute name="z" type="java.lang.String" required="false" description="Used for checking if element has been modified (to recalculate simply provide empty string value)" />
|
||||
|
||||
<c:if test="${empty render or render}">
|
||||
|
||||
<c:if test="${empty disabled}">
|
||||
<c:set value="false" var="disabled" />
|
||||
</c:if>
|
||||
|
||||
<c:if test="${empty label}">
|
||||
<spring:message code="label_${fn:toLowerCase(fn:substringAfter(id,'_'))}" var="label" />
|
||||
</c:if>
|
||||
|
||||
<c:if test="${empty required}">
|
||||
<c:set value="false" var="required" />
|
||||
</c:if>
|
||||
|
||||
<c:set var="sec_field">
|
||||
<spring:escapeBody javaScriptEscape="true" >${field}</spring:escapeBody>
|
||||
</c:set>
|
||||
|
||||
<div id="_${fn:escapeXml(id)}_id">
|
||||
<label for="_${sec_field}_id">
|
||||
<c:out value="${fn:escapeXml(label)}" />
|
||||
:
|
||||
</label>
|
||||
<c:choose>
|
||||
<c:when test="${disableFormBinding}">
|
||||
<input id="_${sec_field}_id" name="${sec_field}" />
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<form:input id="_${sec_field}_id" path="${sec_field}" disabled="${disabled}" />
|
||||
<br />
|
||||
<form:errors cssClass="errors" id="_${sec_field}_error_id" path="${sec_field}" />
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
<spring:message arguments="${label}" code="field_invalid" var="field_invalid" />
|
||||
<c:choose>
|
||||
<c:when test="${required}">
|
||||
<spring:message code="field_required" var="field_required" />
|
||||
<spring:message argumentSeparator="," arguments="${label},(${field_required})" code="field_simple_validation" var="field_validation" />
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<spring:message argumentSeparator="," arguments="${label}, " code="field_simple_validation" var="field_validation" />
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
<script type="text/javascript">
|
||||
<c:set var="sec_field_validation">
|
||||
<spring:escapeBody javaScriptEscape="true">${field_validation}</spring:escapeBody>
|
||||
</c:set>
|
||||
<c:set var="sec_field_invalid">
|
||||
<spring:escapeBody javaScriptEscape="true">${field_invalid}</spring:escapeBody>
|
||||
</c:set>
|
||||
Spring.addDecoration(new Spring.ElementDecoration({elementId : '_${sec_field}_id', widgetType : 'dijit.form.ValidationTextBox', widgetAttrs : {promptMessage: '${sec_field_validation}', invalidMessage: '${sec_field_invalid}', required: ${required}}}));
|
||||
</script>
|
||||
</div>
|
||||
<br />
|
||||
</c:if>
|
||||
</jsp:root>
|
||||
@@ -0,0 +1,42 @@
|
||||
<jsp:root xmlns:c="http://java.sun.com/jsp/jstl/core" xmlns:fn="http://java.sun.com/jsp/jstl/functions" xmlns:spring="http://www.springframework.org/tags" xmlns:form="http://www.springframework.org/tags/form" xmlns:jsp="http://java.sun.com/JSP/Page" version="2.0">
|
||||
<jsp:output omit-xml-declaration="yes" />
|
||||
|
||||
<jsp:directive.attribute name="id" type="java.lang.String" required="true" description="The identifier for this tag (do not change!)" />
|
||||
<jsp:directive.attribute name="path" type="java.lang.String" required="true" description="The relative path to the respource" />
|
||||
<jsp:directive.attribute name="field" type="java.lang.String" required="true" description="The field exposed from the form backing object" />
|
||||
<jsp:directive.attribute name="required" type="java.lang.Boolean" required="false" description="Indicates if this field is required (default false)" />
|
||||
<jsp:directive.attribute name="label" type="java.lang.String" required="false" description="The label used for this field, will default to a message bundle if not supplied" />
|
||||
<jsp:directive.attribute name="render" type="java.lang.Boolean" required="false" description="Indicate if the contents of this tag and all enclosed tags should be rendered (default 'true')" />
|
||||
<jsp:directive.attribute name="z" type="java.lang.String" required="false" description="Used for checking if element has been modified (to recalculate simply provide empty string value)" />
|
||||
|
||||
<c:if test="${empty render or render}">
|
||||
|
||||
<c:if test="${empty label}">
|
||||
<spring:message code="label_${fn:toLowerCase(fn:substringAfter(id,'_'))}" var="label" />
|
||||
</c:if>
|
||||
|
||||
<div id="_${fn:escapeXml(id)}_id">
|
||||
<label for="_${fn:escapeXml(field)}_id">
|
||||
<c:out value="${fn:escapeXml(label)}" />
|
||||
:
|
||||
</label>
|
||||
<spring:url value="${path}" var="create_url">
|
||||
<spring:param name="form" />
|
||||
</spring:url>
|
||||
<a href="${fn:escapeXml(create_url)}">
|
||||
<spring:url value="/resources/images/add.png" var="create_img_url" />
|
||||
<spring:message arguments="${field}" code="global_menu_new" var="add_message" />
|
||||
<img alt="${fn:escapeXml(add_message)}" src="${fn:escapeXml(create_img_url)}" title="${fn:escapeXml(add_message)}" />
|
||||
</a>
|
||||
<c:out value=" " />
|
||||
<spring:message arguments="${label}" code="entity_not_found" />
|
||||
<c:if test="${not empty required and required eq 'true'}">
|
||||
(
|
||||
<spring:message code="field_required" />
|
||||
)
|
||||
</c:if>
|
||||
</div>
|
||||
<br />
|
||||
|
||||
</c:if>
|
||||
</jsp:root>
|
||||
@@ -0,0 +1,99 @@
|
||||
<jsp:root xmlns:c="http://java.sun.com/jsp/jstl/core" xmlns:field="urn:jsptagdir:/WEB-INF/tags/form/fields" xmlns:fn="http://java.sun.com/jsp/jstl/functions" xmlns:spring="http://www.springframework.org/tags" xmlns:form="http://www.springframework.org/tags/form" xmlns:jsp="http://java.sun.com/JSP/Page" version="2.0">
|
||||
<jsp:output omit-xml-declaration="yes" />
|
||||
|
||||
<jsp:directive.attribute name="id" type="java.lang.String" required="true" description="The identifier for this tag (do not change!)" />
|
||||
<jsp:directive.attribute name="field" type="java.lang.String" required="true" description="The field exposed from the form backing object" />
|
||||
<jsp:directive.attribute name="path" type="java.lang.String" required="true" description="The relative path to the referenced resource" />
|
||||
<jsp:directive.attribute name="items" type="java.util.Collection" required="true" description="The name of the collection displayed in the select box" />
|
||||
<jsp:directive.attribute name="label" type="java.lang.String" required="false" description="The label used for this field, will default to a message bundle if not supplied" />
|
||||
<jsp:directive.attribute name="itemValue" type="java.lang.String" required="false" description="The identifier used as value in the select box (defaults to 'id' for non enum types)" />
|
||||
<jsp:directive.attribute name="required" type="java.lang.Boolean" required="false" description="Indicates if this field is required (default false)" />
|
||||
<jsp:directive.attribute name="disabled" type="java.lang.Boolean" required="false" description="Specify if this field should be enabled" />
|
||||
<jsp:directive.attribute name="multiple" type="java.lang.Boolean" required="false" description="Specify if the select box should allow multiple selections" />
|
||||
<jsp:directive.attribute name="disableFormBinding" type="java.lang.Boolean" required="false" description="Set to true to disable Spring form binding" />
|
||||
<jsp:directive.attribute name="render" type="java.lang.Boolean" required="false" description="Indicate if the contents of this tag and all enclosed tags should be rendered (default 'true')" />
|
||||
<jsp:directive.attribute name="z" type="java.lang.String" required="false" description="Used for checking if element has been modified (to recalculate simply provide empty string value)" />
|
||||
|
||||
<c:if test="${empty render or render}">
|
||||
|
||||
<c:if test="${empty disabled}">
|
||||
<c:set value="false" var="disabled" />
|
||||
</c:if>
|
||||
|
||||
<c:if test="${empty label}">
|
||||
<spring:message code="label_${fn:toLowerCase(fn:substringAfter(id,'_'))}" var="label" />
|
||||
</c:if>
|
||||
|
||||
<c:if test="${empty required}">
|
||||
<c:set value="false" var="required" />
|
||||
</c:if>
|
||||
|
||||
<c:if test="${empty multiple}">
|
||||
<c:set value="false" var="multiple" />
|
||||
</c:if>
|
||||
|
||||
<c:set var="sec_field">
|
||||
<spring:escapeBody javaScriptEscape="true" >${field}</spring:escapeBody>
|
||||
</c:set>
|
||||
|
||||
<div id="_${fn:escapeXml(id)}_id">
|
||||
<c:choose>
|
||||
<c:when test="${not empty items}">
|
||||
<label for="_${sec_field}_id">
|
||||
<c:out value="${fn:escapeXml(label)}" />
|
||||
:
|
||||
</label>
|
||||
<c:choose>
|
||||
<c:when test="${empty itemValue}">
|
||||
<c:choose>
|
||||
<c:when test="${disableFormBinding}">
|
||||
<select id="_${sec_field}_id" name="${sec_field}" multiple="${multiple}">
|
||||
<c:forEach items="${items}" var="item">
|
||||
<option value="${item}">
|
||||
<spring:eval expression="item" />
|
||||
</option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<form:select id="_${sec_field}_id" items="${items}" path="${sec_field}" disabled="${disabled}" multiple="${multiple}" />
|
||||
<br />
|
||||
<form:errors cssClass="errors" id="_${sec_field}_error_id" path="${sec_field}" />
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<c:choose>
|
||||
<c:when test="${disableFormBinding}">
|
||||
<select id="_${sec_field}_id" name="${sec_field}" multiple="${multiple}">
|
||||
<c:forEach items="${items}" var="item">
|
||||
<option value="${item[fn:escapeXml(itemValue)]}">
|
||||
<spring:eval expression="item" />
|
||||
</option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<form:select id="_${sec_field}_id" items="${items}" path="${sec_field}" disabled="${disabled}" multiple="${multiple}" itemValue="${fn:escapeXml(itemValue)}" />
|
||||
<br />
|
||||
<form:errors cssClass="errors" id="_${sec_field}_error_id" path="${sec_field}" />
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
<c:choose>
|
||||
<c:when test="${multiple == false}">
|
||||
<script type="text/javascript">Spring.addDecoration(new Spring.ElementDecoration({elementId : '_${sec_field}_id', widgetType: 'dijit.form.FilteringSelect', widgetAttrs : {hasDownArrow : true}})); </script>
|
||||
</c:when>
|
||||
<!-- disabled due to http://jira.springframework.org/browse/ROO-909 <c:otherwise> <script type="text/javascript">Spring.addDecoration(new Spring.ElementDecoration({elementId : '_${field}_id', widgetType: 'dijit.form.MultiSelect', widgetAttrs : {}})); </script> </c:otherwise> -->
|
||||
</c:choose>
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<field:reference field="${label}" id="${id}" path="${path}" required="${required}" />
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
</div>
|
||||
<br />
|
||||
|
||||
</c:if>
|
||||
</jsp:root>
|
||||
@@ -0,0 +1,35 @@
|
||||
<jsp:root xmlns:c="http://java.sun.com/jsp/jstl/core" xmlns:fn="http://java.sun.com/jsp/jstl/functions" xmlns:spring="http://www.springframework.org/tags" xmlns:form="http://www.springframework.org/tags/form" xmlns:jsp="http://java.sun.com/JSP/Page" version="2.0">
|
||||
<jsp:output omit-xml-declaration="yes" />
|
||||
|
||||
<jsp:directive.attribute name="id" type="java.lang.String" required="true" description="The identifier for this tag (do not change!)" />
|
||||
<jsp:directive.attribute name="field" type="java.lang.String" required="true" description="The field exposed from the form backing object" />
|
||||
<jsp:directive.attribute name="text" type="java.lang.String" required="false" description="The text to be presented" />
|
||||
<jsp:directive.attribute name="messageCode" type="java.lang.String" required="false" description="The code for the message to be presented" />
|
||||
<jsp:directive.attribute name="messageCodeAttribute" type="java.lang.String" required="false" description="The attribute for the message code sto be presented" />
|
||||
<jsp:directive.attribute name="label" type="java.lang.String" required="false" description="The label used for this field, will default to a message bundle if not supplied" />
|
||||
<jsp:directive.attribute name="render" type="java.lang.Boolean" required="false" description="Indicate if the contents of this tag and all enclosed tags should be rendered (default 'true')" />
|
||||
<jsp:directive.attribute name="z" type="java.lang.String" required="false" description="Used for checking if element has been modified (to recalculate simply provide empty string value)" />
|
||||
|
||||
<c:if test="${empty render or render}">
|
||||
|
||||
<c:if test="${empty label}">
|
||||
<spring:message code="label_${fn:toLowerCase(fn:substringAfter(id,'_'))}" var="label" />
|
||||
</c:if>
|
||||
|
||||
<div id="_${fn:escapeXml(id)}_id">
|
||||
<label for="_${fn:escapeXml(field)}_id">
|
||||
<c:out value="${label}" />
|
||||
:
|
||||
</label>
|
||||
<c:choose>
|
||||
<c:when test="${not empty messageCode}">
|
||||
<spring:message code="${messageCode}" arguments="${messageCodeAttribute}" />
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<spring:eval expression="text" />
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
</div>
|
||||
<br />
|
||||
</c:if>
|
||||
</jsp:root>
|
||||
@@ -0,0 +1,133 @@
|
||||
<jsp:root xmlns:c="http://java.sun.com/jsp/jstl/core" xmlns:fn="http://java.sun.com/jsp/jstl/functions" xmlns:util="urn:jsptagdir:/WEB-INF/tags/util" xmlns:spring="http://www.springframework.org/tags" xmlns:form="http://www.springframework.org/tags/form" xmlns:jsp="http://java.sun.com/JSP/Page" version="2.0">
|
||||
<jsp:directive.tag import="java.util.ArrayList" />
|
||||
<jsp:output omit-xml-declaration="yes" />
|
||||
|
||||
<jsp:directive.attribute name="id" type="java.lang.String" required="true" description="The identifier for this tag (do not change!)" />
|
||||
<jsp:directive.attribute name="data" type="java.util.Collection" required="true" description="The collection to be displayed in the table" />
|
||||
<jsp:directive.attribute name="path" type="java.lang.String" required="true" description="Specify the URL path" />
|
||||
<jsp:directive.attribute name="typeIdFieldName" type="java.lang.String" required="false" description="The identifier field name for the type (defaults to 'id')" />
|
||||
<jsp:directive.attribute name="create" type="java.lang.Boolean" required="false" description="Include 'create' link into table (default true)" />
|
||||
<jsp:directive.attribute name="update" type="java.lang.Boolean" required="false" description="Include 'update' link into table (default true)" />
|
||||
<jsp:directive.attribute name="delete" type="java.lang.Boolean" required="false" description="Include 'delete' link into table (default true)" />
|
||||
<jsp:directive.attribute name="render" type="java.lang.Boolean" required="false" description="Indicate if the contents of this tag and all enclosed tags should be rendered (default 'true')" />
|
||||
<jsp:directive.attribute name="z" type="java.lang.String" required="false" description="Used for checking if element has been modified (to recalculate simply provide empty string value)" />
|
||||
|
||||
<c:if test="${empty render or render}">
|
||||
|
||||
<c:set var="columnProperties" scope="request" />
|
||||
<c:set var="columnLabels" scope="request" />
|
||||
<c:set var="columnMaxLengths" scope="request" />
|
||||
|
||||
<jsp:doBody />
|
||||
|
||||
<c:if test="${empty typeIdFieldName}">
|
||||
<c:set var="typeIdFieldName" value="id" />
|
||||
</c:if>
|
||||
|
||||
<c:if test="${empty update}">
|
||||
<c:set var="update" value="true" />
|
||||
</c:if>
|
||||
|
||||
<c:if test="${empty delete}">
|
||||
<c:set var="delete" value="true" />
|
||||
</c:if>
|
||||
|
||||
<c:set var="typeName" value="${fn:split(id,'_')[fn:length(fn:split(id,'_')) - 1]}" />
|
||||
<c:set var="lengths" value="${fn:split(columnMaxLengths, ',')}" scope="request" />
|
||||
|
||||
<table>
|
||||
<thead>
|
||||
<tr>
|
||||
<c:forTokens items="${columnLabels}" delims="," var="columnHeading">
|
||||
<th>
|
||||
<c:out value="${columnHeading}" />
|
||||
</th>
|
||||
</c:forTokens>
|
||||
<th></th>
|
||||
<c:if test="${update}">
|
||||
<th></th>
|
||||
</c:if>
|
||||
<c:if test="${delete}">
|
||||
<th></th>
|
||||
</c:if>
|
||||
</tr>
|
||||
</thead>
|
||||
<c:forEach items="${data}" var="item">
|
||||
<tr>
|
||||
<c:forTokens items="${columnProperties}" delims="," var="column" varStatus="num">
|
||||
<c:set var="columnMaxLength" value="${lengths[num.count-1]}" scope="request" />
|
||||
<td>
|
||||
<c:choose>
|
||||
<c:when test="${columnMaxLength lt 0}">
|
||||
<spring:eval expression="item[column]" />
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<spring:eval expression="item[column]" var="colTxt"/>
|
||||
<c:out value="${fn:substring(colTxt, 0, columnMaxLength)}" />
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
</td>
|
||||
</c:forTokens>
|
||||
<td>
|
||||
<spring:url value="${path}/${item[typeIdFieldName]}" var="show_form_url" />
|
||||
<spring:url value="/resources/images/show.png" var="show_image_url" />
|
||||
<spring:message arguments="${typeName}" code="entity_show" var="show_label" />
|
||||
<a href="${fn:escapeXml(show_form_url)}" alt="${fn:escapeXml(show_label)}" title="${fn:escapeXml(show_label)}">
|
||||
<img alt="${fn:escapeXml(show_label)}" class="image" src="${fn:escapeXml(show_image_url)}" title="${fn:escapeXml(show_label)}" />
|
||||
</a>
|
||||
</td>
|
||||
<c:if test="${update}">
|
||||
<td>
|
||||
<spring:url value="${path}/${item[typeIdFieldName]}" var="update_form_url">
|
||||
<spring:param name="form" />
|
||||
</spring:url>
|
||||
<spring:url value="/resources/images/update.png" var="update_image_url" />
|
||||
<spring:message arguments="${typeName}" code="entity_update" var="update_label" />
|
||||
<a href="${fn:escapeXml(update_form_url)}" alt="${fn:escapeXml(update_label)}" title="${fn:escapeXml(update_label)}">
|
||||
<img alt="${fn:escapeXml(update_label)}" class="image" src="${fn:escapeXml(update_image_url)}" title="${fn:escapeXml(update_label)}" />
|
||||
</a>
|
||||
</td>
|
||||
</c:if>
|
||||
<c:if test="${delete}">
|
||||
<td>
|
||||
<spring:url value="${path}/${item[typeIdFieldName]}" var="delete_form_url" />
|
||||
<spring:url value="/resources/images/delete.png" var="delete_image_url" />
|
||||
<form:form action="${fn:escapeXml(delete_form_url)}" method="DELETE">
|
||||
<spring:message arguments="${typeName}" code="entity_delete" var="delete_label" />
|
||||
<input alt="${fn:escapeXml(delete_label)}" class="image" src="${fn:escapeXml(delete_image_url)}" title="${fn:escapeXml(delete_label)}" type="image" value="${fn:escapeXml(delete_label)}" />
|
||||
<c:if test="${not empty param.page}">
|
||||
<input name="page" type="hidden" value="${fn:escapeXml(param.page)}" />
|
||||
</c:if>
|
||||
<c:if test="${not empty param.size}">
|
||||
<input name="size" type="hidden" value="${fn:escapeXml(param.size)}" />
|
||||
</c:if>
|
||||
</form:form>
|
||||
</td>
|
||||
</c:if>
|
||||
</tr>
|
||||
</c:forEach>
|
||||
<tr class="footer">
|
||||
<td colspan="10">
|
||||
<c:if test="${empty create or create}">
|
||||
<span class="new">
|
||||
<spring:url value="/${path}" var="create_url">
|
||||
<spring:param name="form" />
|
||||
</spring:url>
|
||||
<a href="${fn:escapeXml(create_url)}">
|
||||
<spring:url value="/resources/images/add.png" var="create_img_url" />
|
||||
<spring:message arguments="${typeName}" code="global_menu_new" var="add_message" />
|
||||
<img alt="${fn:escapeXml(add_message)}" src="${fn:escapeXml(create_img_url)}" title="${fn:escapeXml(add_message)}" />
|
||||
</a>
|
||||
</span>
|
||||
<c:out value=" " />
|
||||
</c:if>
|
||||
<c:if test="${not empty maxPages}">
|
||||
<util:pagination maxPages="${maxPages}" page="${param.page}" size="${param.size}" />
|
||||
</c:if>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
</c:if>
|
||||
|
||||
</jsp:root>
|
||||
@@ -0,0 +1,47 @@
|
||||
<jsp:root xmlns:c="http://java.sun.com/jsp/jstl/core" xmlns:fn="http://java.sun.com/jsp/jstl/functions" xmlns:spring="http://www.springframework.org/tags" xmlns:form="http://www.springframework.org/tags/form" xmlns:jsp="http://java.sun.com/JSP/Page" version="2.0">
|
||||
<jsp:output omit-xml-declaration="yes" />
|
||||
|
||||
<jsp:directive.attribute name="id" type="java.lang.String" required="true" description="The identifier for this tag (do not change!)" />
|
||||
<jsp:directive.attribute name="field" type="java.lang.String" required="true" description="The field exposed from the form backing object" />
|
||||
<jsp:directive.attribute name="label" type="java.lang.String" required="false" description="The label used for this field, will default to a message bundle if not supplied" />
|
||||
<jsp:directive.attribute name="required" type="java.lang.Boolean" required="false" description="Indicates if this field is required (default false)" />
|
||||
<jsp:directive.attribute name="disabled" type="java.lang.Boolean" required="false" description="Specify if this field should be enabled" />
|
||||
<jsp:directive.attribute name="validationRegex" type="java.lang.String" required="false" description="Specify regular expression to be used for the validation of the input contents" />
|
||||
<jsp:directive.attribute name="validationMessageCode" type="java.lang.String" required="false" description="Specify the message (message property code) to be displayed if the regular expression validation fails" />
|
||||
<jsp:directive.attribute name="validationMessage" type="java.lang.String" required="false" description="Specify the message to be displayed if the regular expression validation fails" />
|
||||
<jsp:directive.attribute name="render" type="java.lang.Boolean" required="false" description="Indicate if the contents of this tag and all enclosed tags should be rendered (default 'true')" />
|
||||
<jsp:directive.attribute name="z" type="java.lang.String" required="false" description="Used for checking if element has been modified (to recalculate simply provide empty string value)" />
|
||||
|
||||
<c:if test="${empty render or render}">
|
||||
|
||||
<c:if test="${empty disabled}">
|
||||
<c:set value="false" var="disabled" />
|
||||
</c:if>
|
||||
|
||||
<c:if test="${empty label}">
|
||||
<spring:message code="label_${fn:toLowerCase(fn:substringAfter(id,'_'))}" var="label" />
|
||||
</c:if>
|
||||
|
||||
<c:if test="${empty required}">
|
||||
<c:set value="false" var="required" />
|
||||
</c:if>
|
||||
|
||||
<c:set var="sec_field">
|
||||
<spring:escapeBody javaScriptEscape="true" >${field}</spring:escapeBody>
|
||||
</c:set>
|
||||
|
||||
<script type="text/javascript">dojo.require("dijit.form.SimpleTextarea");</script>
|
||||
<div id="_${fn:escapeXml(id)}_id">
|
||||
<label for="_${sec_field}_id">
|
||||
<c:out value="${fn:escapeXml(label)}" />
|
||||
:
|
||||
</label>
|
||||
<form:textarea id="_${sec_field}_id" path="${sec_field}" disabled="${disabled}" />
|
||||
<br />
|
||||
<form:errors cssClass="errors" id="_${sec_field}_error_id" path="${sec_field}" />
|
||||
<script type="text/javascript">Spring.addDecoration(new Spring.ElementDecoration({elementId : '_${sec_field}_id', widgetType : 'dijit.form.SimpleTextarea', widgetAttrs : {disabled : ${disabled}}})); </script>
|
||||
</div>
|
||||
<br />
|
||||
|
||||
</c:if>
|
||||
</jsp:root>
|
||||
@@ -0,0 +1,29 @@
|
||||
<jsp:root xmlns:c="http://java.sun.com/jsp/jstl/core" xmlns:fn="http://java.sun.com/jsp/jstl/functions" xmlns:util="urn:jsptagdir:/WEB-INF/tags/util" xmlns:form="http://www.springframework.org/tags/form" xmlns:jsp="http://java.sun.com/JSP/Page" xmlns:spring="http://www.springframework.org/tags" version="2.0">
|
||||
<jsp:output omit-xml-declaration="yes"/>
|
||||
|
||||
<jsp:directive.attribute name="id" type="java.lang.String" required="true" description="The identifier for this tag (do not change!)"/>
|
||||
<jsp:directive.attribute name="finderName" type="java.lang.String" required="true" description="The finder name"/>
|
||||
<jsp:directive.attribute name="path" type="java.lang.String" required="true" description="Specify the relative URL path (wit leading /)" />
|
||||
<jsp:directive.attribute name="render" type="java.lang.Boolean" required="false" description="Indicate if the contents of this tag and all enclosed tags should be rendered (default 'true')" />
|
||||
<jsp:directive.attribute name="openPane" type="java.lang.Boolean" required="false" description="Control if the title pane is opened or closed by default (default: true)"/>
|
||||
<jsp:directive.attribute name="z" type="java.lang.String" required="false" description="Used for checking if element has been modified (to recalculate simply provide empty string value)"/>
|
||||
|
||||
<c:if test="${empty render or render}">
|
||||
<c:if test="${empty label}">
|
||||
<spring:message code="label_${fn:toLowerCase(fn:substringAfter(id,'_'))}" var="label"/>
|
||||
</c:if>
|
||||
<spring:message arguments="${fn:escapeXml(label)}" code="entity_find" var="title_msg"/>
|
||||
<util:panel id="${id}" title="${title_msg}" openPane="${openPane}">
|
||||
<spring:url value="${path}" var="form_url" />
|
||||
<form:form action="${fn:escapeXml(form_url)}" method="GET">
|
||||
<input type="hidden" name="find" value="${fn:escapeXml(finderName)}" />
|
||||
<jsp:doBody />
|
||||
<div class="submit" id="${fn:escapeXml(id)}_${fn:escapeXml(finderName)}_submit">
|
||||
<spring:message code="button_find" var="find_button"/>
|
||||
<script type="text/javascript">Spring.addDecoration(new Spring.ValidateAllDecoration({elementId:'proceed', event:'onclick'}));</script>
|
||||
<input id="proceed" type="submit" value="${fn:escapeXml(find_button)}"/>
|
||||
</div>
|
||||
</form:form>
|
||||
</util:panel>
|
||||
</c:if>
|
||||
</jsp:root>
|
||||
@@ -0,0 +1,31 @@
|
||||
<jsp:root xmlns:c="http://java.sun.com/jsp/jstl/core" xmlns:fn="http://java.sun.com/jsp/jstl/functions" xmlns:util="urn:jsptagdir:/WEB-INF/tags/util" xmlns:form="http://www.springframework.org/tags/form" xmlns:jsp="http://java.sun.com/JSP/Page" xmlns:spring="http://www.springframework.org/tags" version="2.0">
|
||||
<jsp:output omit-xml-declaration="yes" />
|
||||
|
||||
<jsp:directive.attribute name="id" type="java.lang.String" required="true" description="The identifier for this tag (do not change!)" />
|
||||
<jsp:directive.attribute name="items" type="java.util.Collection" required="true" description="The form backing object name" />
|
||||
<jsp:directive.attribute name="label" type="java.lang.String" required="false" description="The label used for this object, will default to a message bundle if not supplied" />
|
||||
<jsp:directive.attribute name="labelPlural" type="java.lang.String" required="false" description="The label used for this object, will default to a message bundle if not supplied" />
|
||||
<jsp:directive.attribute name="render" type="java.lang.Boolean" required="false" description="Indicate if the contents of this tag and all enclosed tags should be rendered (default 'true')" />
|
||||
<jsp:directive.attribute name="openPane" type="java.lang.Boolean" required="false" description="Control if the title pane is opened or closed by default (default: true)" />
|
||||
<jsp:directive.attribute name="z" type="java.lang.String" required="false" description="Used for checking if element has been modified (to recalculate simply provide empty string value)" />
|
||||
|
||||
<c:if test="${empty render or render}">
|
||||
<c:if test="${empty label}">
|
||||
<spring:message code="label_${fn:toLowerCase(fn:substringAfter(id,'_'))}" var="label" />
|
||||
</c:if>
|
||||
<c:if test="${empty labelPlural}">
|
||||
<spring:message code="label_${fn:toLowerCase(fn:substringAfter(id,'_'))}_plural" var="labelPlural" />
|
||||
</c:if>
|
||||
<spring:message arguments="${labelPlural}" code="entity_list_all" var="title_msg" />
|
||||
<util:panel id="${id}" title="${title_msg}" openPane="${openPane}">
|
||||
<c:choose>
|
||||
<c:when test="${not empty items}">
|
||||
<jsp:doBody />
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<spring:message arguments="${label}" code="entity_not_found" />
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
</util:panel>
|
||||
</c:if>
|
||||
</jsp:root>
|
||||
@@ -0,0 +1,96 @@
|
||||
<jsp:root xmlns:c="http://java.sun.com/jsp/jstl/core" xmlns:fn="http://java.sun.com/jsp/jstl/functions" xmlns:util="urn:jsptagdir:/WEB-INF/tags/util" xmlns:form="http://www.springframework.org/tags/form" xmlns:jsp="http://java.sun.com/JSP/Page" xmlns:spring="http://www.springframework.org/tags" version="2.0">
|
||||
<jsp:output omit-xml-declaration="yes" />
|
||||
|
||||
<jsp:directive.attribute name="id" type="java.lang.String" required="true" description="The identifier for this tag (do not change!)" />
|
||||
<jsp:directive.attribute name="object" type="java.lang.Object" required="true" description="The form backing object" />
|
||||
<jsp:directive.attribute name="path" type="java.lang.String" required="true" description="Specify the URL path" />
|
||||
<jsp:directive.attribute name="list" type="java.lang.Boolean" required="false" description="Include 'list' link into table (default true)" />
|
||||
<jsp:directive.attribute name="create" type="java.lang.Boolean" required="false" description="Include 'create' link into table (default true)" />
|
||||
<jsp:directive.attribute name="update" type="java.lang.Boolean" required="false" description="Include 'update' link into table (default true)" />
|
||||
<jsp:directive.attribute name="delete" type="java.lang.Boolean" required="false" description="Include 'delete' link into table (default true)" />
|
||||
<jsp:directive.attribute name="label" type="java.lang.String" required="false" description="The label used for this object, will default to a message bundle if not supplied" />
|
||||
<jsp:directive.attribute name="render" type="java.lang.Boolean" required="false" description="Indicate if the contents of this tag and all enclosed tags should be rendered (default 'true')" />
|
||||
<jsp:directive.attribute name="openPane" type="java.lang.Boolean" required="false" description="Control if the title pane is opened or closed by default (default: true)" />
|
||||
<jsp:directive.attribute name="z" type="java.lang.String" required="false" description="Used for checking if element has been modified (to recalculate simply provide empty string value)" />
|
||||
|
||||
<c:if test="${empty render or render}">
|
||||
<c:if test="${empty label}">
|
||||
<spring:message code="label_${fn:toLowerCase(fn:substringAfter(id,'_'))}" var="label" />
|
||||
</c:if>
|
||||
|
||||
<c:if test="${empty list}">
|
||||
<c:set var="list" value="true" />
|
||||
</c:if>
|
||||
|
||||
<c:if test="${empty create}">
|
||||
<c:set var="create" value="true" />
|
||||
</c:if>
|
||||
|
||||
<c:if test="${empty update}">
|
||||
<c:set var="update" value="true" />
|
||||
</c:if>
|
||||
|
||||
<c:if test="${empty delete}">
|
||||
<c:set var="delete" value="true" />
|
||||
</c:if>
|
||||
|
||||
<c:set var="typeName" value="${fn:split(id,'_')[fn:length(fn:split(id,'_')) - 1]}" />
|
||||
|
||||
<spring:message arguments="${label}" code="entity_show" var="title_msg" />
|
||||
<util:panel id="${id}" title="${title_msg}" openPane="${openPane}">
|
||||
<c:choose>
|
||||
<c:when test="${not empty object}">
|
||||
<jsp:doBody />
|
||||
<div class="quicklinks">
|
||||
<span>
|
||||
<c:if test="${delete}">
|
||||
<spring:url value="${path}/${itemId}" var="delete_form_url" />
|
||||
<spring:url value="/resources/images/delete.png" var="delete_image_url" />
|
||||
<form:form action="${fn:escapeXml(delete_form_url)}" method="DELETE">
|
||||
<spring:message arguments="${typeName}" code="entity_delete" var="delete_label" />
|
||||
<input alt="${fn:escapeXml(delete_label)}" class="image" src="${fn:escapeXml(delete_image_url)}" title="${fn:escapeXml(delete_label)}" type="image" value="${fn:escapeXml(delete_label)}" />
|
||||
</form:form>
|
||||
</c:if>
|
||||
</span>
|
||||
<span>
|
||||
<c:if test="${update}">
|
||||
<spring:url value="${path}/${itemId}" var="update_form_url">
|
||||
<spring:param name="form" />
|
||||
</spring:url>
|
||||
<spring:url value="/resources/images/update.png" var="update_image_url" />
|
||||
<spring:message arguments="${typeName}" code="entity_update" var="update_label" />
|
||||
<a href="${fn:escapeXml(update_form_url)}" alt="${fn:escapeXml(update_label)}" title="${fn:escapeXml(update_label)}">
|
||||
<img alt="${fn:escapeXml(update_label)}" class="image" src="${fn:escapeXml(update_image_url)}" title="${fn:escapeXml(update_label)}" />
|
||||
</a>
|
||||
</c:if>
|
||||
</span>
|
||||
<span>
|
||||
<c:if test="${create}">
|
||||
<spring:url value="${path}" var="create_form_url">
|
||||
<spring:param name="form" />
|
||||
</spring:url>
|
||||
<spring:url value="/resources/images/create.png" var="create_image_url" />
|
||||
<spring:message arguments="${typeName}" code="entity_create" var="create_label" />
|
||||
<a href="${fn:escapeXml(create_form_url)}" alt="${fn:escapeXml(create_label)}" title="${fn:escapeXml(create_label)}">
|
||||
<img alt="${fn:escapeXml(create_label)}" class="image" src="${fn:escapeXml(create_image_url)}" title="${fn:escapeXml(create_label)}" />
|
||||
</a>
|
||||
</c:if>
|
||||
</span>
|
||||
<span>
|
||||
<c:if test="${list}">
|
||||
<spring:url value="${path}" var="list_form_url" />
|
||||
<spring:url value="/resources/images/list.png" var="list_image_url" />
|
||||
<a href="${fn:escapeXml(list_form_url)}" alt="${fn:escapeXml(list_label)}" title="${fn:escapeXml(list_label)}">
|
||||
<img alt="${fn:escapeXml(list_label)}" class="image" src="${fn:escapeXml(list_image_url)}" title="${fn:escapeXml(list_label)}" />
|
||||
</a>
|
||||
</c:if>
|
||||
</span>
|
||||
</div>
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<spring:message arguments="${label}" code="entity_not_found_single" />
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
</util:panel>
|
||||
</c:if>
|
||||
</jsp:root>
|
||||
@@ -0,0 +1,42 @@
|
||||
<jsp:root xmlns:c="http://java.sun.com/jsp/jstl/core" xmlns:fn="http://java.sun.com/jsp/jstl/functions" xmlns:util="urn:jsptagdir:/WEB-INF/tags/util" xmlns:form="http://www.springframework.org/tags/form" xmlns:jsp="http://java.sun.com/JSP/Page" xmlns:spring="http://www.springframework.org/tags" version="2.0">
|
||||
<jsp:output omit-xml-declaration="yes" />
|
||||
|
||||
<jsp:directive.attribute name="id" type="java.lang.String" required="true" description="The identifier for this tag (do not change!)" />
|
||||
<jsp:directive.attribute name="modelAttribute" type="java.lang.String" required="true" description="The name of the model attribute for form binding" />
|
||||
<jsp:directive.attribute name="path" type="java.lang.String" required="true" description="Specify the relative URL path (with leading /)" />
|
||||
<jsp:directive.attribute name="label" type="java.lang.String" required="false" description="The label used for this object, will default to a message bundle if not supplied" />
|
||||
<jsp:directive.attribute name="idField" type="java.lang.String" required="false" description="Specify the field name of the id field (default 'id')" />
|
||||
<jsp:directive.attribute name="versionField" type="java.lang.String" required="false" description="Specify the field name of the version field (default 'version'). If specified 'none' the version field will not be inlcuded (versionField='none')." />
|
||||
<jsp:directive.attribute name="render" type="java.lang.Boolean" required="false" description="Indicate if the contents of this tag and all enclosed tags should be rendered (default 'true')" />
|
||||
<jsp:directive.attribute name="openPane" type="java.lang.Boolean" required="false" description="Control if the title pane is opened or closed by default (default: true)" />
|
||||
<jsp:directive.attribute name="z" type="java.lang.String" required="false" description="Used for checking if element has been modified (to recalculate simply provide empty string value)" />
|
||||
|
||||
<c:if test="${empty render or render}">
|
||||
<c:if test="${empty label}">
|
||||
<spring:message code="label_${fn:toLowerCase(fn:substringAfter(id,'_'))}" var="label" />
|
||||
</c:if>
|
||||
<c:if test="${empty idField}">
|
||||
<c:set value="id" var="idField" />
|
||||
</c:if>
|
||||
<c:if test="${empty versionField}">
|
||||
<c:set value="version" var="versionField" />
|
||||
</c:if>
|
||||
<spring:message arguments="${label}" code="entity_update" var="title_msg" />
|
||||
<util:panel id="${id}" title="${title_msg}" openPane="${openPane}">
|
||||
<spring:url value="${path}" var="form_url" />
|
||||
<form:form action="${fn:escapeXml(form_url)}" method="PUT" modelAttribute="${modelAttribute}">
|
||||
<form:errors cssClass="errors" delimiter="<p/>" />
|
||||
<jsp:doBody />
|
||||
<div class="submit" id="${fn:escapeXml(id)}_submit">
|
||||
<spring:message code="button_save" var="save_button" />
|
||||
<script type="text/javascript">Spring.addDecoration(new Spring.ValidateAllDecoration({elementId:'proceed', event:'onclick'}));</script>
|
||||
<input id="proceed" type="submit" value="${fn:escapeXml(save_button)}" />
|
||||
</div>
|
||||
<form:hidden id="_${fn:escapeXml(idField)}_id" path="${fn:escapeXml(idField)}" />
|
||||
<c:if test="${versionField ne 'none'}">
|
||||
<form:hidden id="_${fn:escapeXml(versionField)}_id" path="${fn:escapeXml(versionField)}" />
|
||||
</c:if>
|
||||
</form:form>
|
||||
</util:panel>
|
||||
</c:if>
|
||||
</jsp:root>
|
||||
@@ -0,0 +1,25 @@
|
||||
<jsp:root xmlns:c="http://java.sun.com/jsp/jstl/core" xmlns:fn="http://java.sun.com/jsp/jstl/functions" xmlns:jsp="http://java.sun.com/JSP/Page" xmlns:spring="http://www.springframework.org/tags" version="2.0">
|
||||
<jsp:output omit-xml-declaration="yes"/>
|
||||
|
||||
<jsp:directive.attribute name="id" type="java.lang.String" required="true" description="The identifier for this tag (do not change!)"/>
|
||||
<jsp:directive.attribute name="label" type="java.lang.String" required="false" description="The label for this category (if not set the resource bundle is used)"/>
|
||||
<jsp:directive.attribute name="render" type="java.lang.Boolean" required="false" description="Indicate if the contents of this tag and all enclosed tags should be rendered (default 'true')" />
|
||||
<jsp:directive.attribute name="z" type="java.lang.String" required="false" description="Used for checking if element has been modified (to recalculate simply provide empty string value)"/>
|
||||
|
||||
<c:if test="${empty render or render}">
|
||||
|
||||
<c:if test="${empty label}">
|
||||
<spring:message code="menu_category_${fn:toLowerCase(fn:substringAfter(id,'_'))}_label" var="label"/>
|
||||
</c:if>
|
||||
|
||||
<li id="${fn:escapeXml(id)}">
|
||||
<h2>
|
||||
<c:out value="${label}" />
|
||||
</h2>
|
||||
<ul>
|
||||
<jsp:doBody />
|
||||
</ul>
|
||||
</li>
|
||||
|
||||
</c:if>
|
||||
</jsp:root>
|
||||
@@ -0,0 +1,29 @@
|
||||
<jsp:root xmlns:c="http://java.sun.com/jsp/jstl/core" xmlns:fn="http://java.sun.com/jsp/jstl/functions" xmlns:jsp="http://java.sun.com/JSP/Page" xmlns:spring="http://www.springframework.org/tags" version="2.0">
|
||||
<jsp:output omit-xml-declaration="yes" />
|
||||
|
||||
<jsp:directive.attribute name="id" type="java.lang.String" required="true" description="The identifier for this tag (do not change!)" />
|
||||
<jsp:directive.attribute name="url" type="java.lang.String" required="true" description="The link URL" />
|
||||
<jsp:directive.attribute name="label" type="java.lang.String" required="false" description="The label used for this menu item" />
|
||||
<jsp:directive.attribute name="messageCode" type="java.lang.String" required="false" description="The global message code to be used (works in conjunction with label)" />
|
||||
<jsp:directive.attribute name="render" type="java.lang.Boolean" required="false" description="Indicate if the contents of this tag and all enclosed tags should be rendered (default 'true')" />
|
||||
<jsp:directive.attribute name="z" type="java.lang.String" required="false" description="Used for checking if element has been modified (to recalculate simply provide empty string value)" />
|
||||
|
||||
<c:if test="${empty render or render}">
|
||||
|
||||
<c:if test="${empty label}">
|
||||
<spring:message code="menu_item_${fn:toLowerCase(fn:substringAfter(id,'_'))}_label" var="label" />
|
||||
</c:if>
|
||||
|
||||
<c:if test="${not empty messageCode}">
|
||||
<spring:message code="${messageCode}" var="label" arguments="${label}" />
|
||||
</c:if>
|
||||
|
||||
<li id="${fn:escapeXml(id)}">
|
||||
<spring:url value="${url}" var="menu_item_url"/>
|
||||
<a href="${menu_item_url}" title="${fn:escapeXml(label)}">
|
||||
<c:out value="${label}" />
|
||||
</a>
|
||||
</li>
|
||||
|
||||
</c:if>
|
||||
</jsp:root>
|
||||
@@ -0,0 +1,13 @@
|
||||
<jsp:root xmlns:c="http://java.sun.com/jsp/jstl/core" xmlns:fn="http://java.sun.com/jsp/jstl/functions" xmlns:jsp="http://java.sun.com/JSP/Page" version="2.0">
|
||||
<jsp:output omit-xml-declaration="yes"/>
|
||||
|
||||
<jsp:directive.attribute name="id" type="java.lang.String" required="true" description="The identifier for this tag (do not change!)"/>
|
||||
<jsp:directive.attribute name="render" type="java.lang.Boolean" required="false" description="Indicate if the contents of this tag and all enclosed tags should be rendered (default 'true')" />
|
||||
<jsp:directive.attribute name="z" type="java.lang.String" required="false" description="Used for checking if element has been modified (to recalculate simply provide empty string value)"/>
|
||||
|
||||
<c:if test="${empty render or render}">
|
||||
<ul id="${fn:escapeXml(id)}">
|
||||
<jsp:doBody />
|
||||
</ul>
|
||||
</c:if>
|
||||
</jsp:root>
|
||||
@@ -0,0 +1,31 @@
|
||||
<jsp:root xmlns:c="http://java.sun.com/jsp/jstl/core" xmlns:fn="http://java.sun.com/jsp/jstl/functions" xmlns:spring="http://www.springframework.org/tags" xmlns:jsp="http://java.sun.com/JSP/Page" version="2.0">
|
||||
<jsp:output omit-xml-declaration="yes" />
|
||||
|
||||
<jsp:directive.attribute name="locale" type="java.lang.String" required="true" description="The locale for the language to be added." />
|
||||
<jsp:directive.attribute name="label" type="java.lang.String" required="true" description="The country label for the language to be added." />
|
||||
<jsp:directive.attribute name="render" type="java.lang.Boolean" required="false" description="Indicate if the contents of this tag and all enclosed tags should be rendered (default 'true')" />
|
||||
|
||||
<c:if test="${empty render or render}">
|
||||
<spring:url var="img" value="/resources/images/${locale}.png" />
|
||||
<spring:url var="url" value="">
|
||||
<c:if test="${null ne param.form}">
|
||||
<spring:param name="form" />
|
||||
</c:if>
|
||||
<c:if test="${not empty param.find}">
|
||||
<spring:param name="find" value="${param.find}" />
|
||||
</c:if>
|
||||
<spring:param name="lang" value="${locale}" />
|
||||
<c:if test="${not empty param.page}">
|
||||
<spring:param name="page" value="${param.page}" />
|
||||
</c:if>
|
||||
<c:if test="${not empty param.size}">
|
||||
<spring:param name="size" value="${param.size}" />
|
||||
</c:if>
|
||||
</spring:url>
|
||||
<spring:message code="global_language_switch" arguments="${label}" var="lang_label" />
|
||||
<a href="${fn:escapeXml(url)}" title="${fn:escapeXml(lang_label)}">
|
||||
<img class="flag" src="${fn:escapeXml(img)}" alt="${fn:escapeXml(lang_label)}" />
|
||||
</a>
|
||||
<c:out value=" " />
|
||||
</c:if>
|
||||
</jsp:root>
|
||||
@@ -0,0 +1,28 @@
|
||||
<jsp:root xmlns:c="http://java.sun.com/jsp/jstl/core" xmlns:jsp="http://java.sun.com/JSP/Page" xmlns:spring="http://www.springframework.org/tags" version="2.0">
|
||||
|
||||
<jsp:output omit-xml-declaration="yes" />
|
||||
|
||||
<spring:theme code="styleSheet" var="roo_css" />
|
||||
<spring:url value="/${roo_css}" var="roo_css_url" />
|
||||
<spring:url value="/resources/dojo/dojo.js" var="dojo_url" />
|
||||
<spring:url value="/resources/dijit/themes/tundra/tundra.css" var="tundra_url" />
|
||||
<spring:url value="/resources/spring/Spring.js" var="spring_url" />
|
||||
<spring:url value="/resources/spring/Spring-Dojo.js" var="spring_dojo_url" />
|
||||
<spring:url value="/resources/images/favicon.ico" var="favicon" />
|
||||
<link rel="stylesheet" type="text/css" media="screen" href="${roo_css_url}"><!-- required for FF3 and Opera --></link>
|
||||
<link rel="stylesheet" type="text/css" href="${tundra_url}"><!-- required for FF3 and Opera --></link>
|
||||
<link rel="SHORTCUT ICON" href="${favicon}" />
|
||||
|
||||
<!-- Get the user local from the page context (it was set by Spring MVC's locale resolver) -->
|
||||
<c:set var="userLocale">
|
||||
<c:out value="${pageContext.response.locale}" default="en" />
|
||||
</c:set>
|
||||
|
||||
<script type="text/javascript">var djConfig="${userLocale}"; </script>
|
||||
|
||||
<script src="${dojo_url}" type="text/javascript"><!-- required for FF3 and Opera --></script>
|
||||
<script src="${spring_url}" type="text/javascript"><!-- /required for FF3 and Opera --></script>
|
||||
<script src="${spring_dojo_url}" type="text/javascript"><!-- required for FF3 and Opera --></script>
|
||||
<script language="JavaScript" type="text/javascript">dojo.require("dojo.parser");</script>
|
||||
|
||||
</jsp:root>
|
||||
@@ -0,0 +1,87 @@
|
||||
<jsp:root xmlns:c="http://java.sun.com/jsp/jstl/core" xmlns:spring="http://www.springframework.org/tags" xmlns:jsp="http://java.sun.com/JSP/Page" version="2.0">
|
||||
<jsp:output omit-xml-declaration="yes" />
|
||||
|
||||
<jsp:directive.attribute name="maxPages" type="java.lang.Integer" required="true" description="The maximum number of pages available (ie tableRecordCount / size)" />
|
||||
<jsp:directive.attribute name="page" type="java.lang.Integer" required="false" description="The current page (not required, defaults to 1)" />
|
||||
<jsp:directive.attribute name="size" type="java.lang.Integer" required="false" description="The number of records per page (not required, defaults to 10)" />
|
||||
<jsp:directive.attribute name="render" type="java.lang.Boolean" required="false" description="Indicate if the contents of this tag and all enclosed tags should be rendered (default 'true')" />
|
||||
|
||||
<c:if test="${empty render or render}">
|
||||
|
||||
<c:if test="${empty page || page lt 1}">
|
||||
<c:set var="page" value="1" />
|
||||
</c:if>
|
||||
|
||||
<c:if test="${empty size || size lt 1}">
|
||||
<c:set var="size" value="10" />
|
||||
</c:if>
|
||||
|
||||
<spring:message code="list_size" var="list_size" />
|
||||
<c:out value="${list_size} " />
|
||||
|
||||
<c:forEach var="i" begin="5" end="25" step="5">
|
||||
<c:choose>
|
||||
<c:when test="${size == i}">
|
||||
<c:out value="${i}" />
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<spring:url value="" var="sizeUrl">
|
||||
<spring:param name="page" value="1" />
|
||||
<spring:param name="size" value="${i}" />
|
||||
</spring:url>
|
||||
<a href="${sizeUrl}">${i}</a>
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
<c:out value=" " />
|
||||
</c:forEach>
|
||||
<c:out value="| " />
|
||||
|
||||
<c:if test="${page ne 1}">
|
||||
<spring:url value="" var="first">
|
||||
<spring:param name="page" value="1" />
|
||||
<spring:param name="size" value="${size}" />
|
||||
</spring:url>
|
||||
<spring:url value="/resources/images/resultset_first.png" var="first_image_url" />
|
||||
<spring:message code="list_first" var="first_label" />
|
||||
<a class="image" href="${first}" title="${first_label}">
|
||||
<img alt="${first_label}" src="${first_image_url}" />
|
||||
</a>
|
||||
</c:if>
|
||||
<c:if test="${page gt 1}">
|
||||
<spring:url value="" var="previous">
|
||||
<spring:param name="page" value="${page - 1}" />
|
||||
<spring:param name="size" value="${size}" />
|
||||
</spring:url>
|
||||
<spring:url value="/resources/images/resultset_previous.png" var="previous_image_url" />
|
||||
<spring:message code="list_previous" var="previous_label" />
|
||||
<a class="image" href="${previous}" title="${previous_label}">
|
||||
<img alt="${previous_label}" src="${previous_image_url}" />
|
||||
</a>
|
||||
</c:if>
|
||||
<c:out value=" " />
|
||||
<spring:message code="list_page" arguments="${page},${maxPages}" argumentSeparator="," />
|
||||
<c:out value=" " />
|
||||
<c:if test="${page lt maxPages}">
|
||||
<spring:url value="" var="next">
|
||||
<spring:param name="page" value="${page + 1}" />
|
||||
<spring:param name="size" value="${size}" />
|
||||
</spring:url>
|
||||
<spring:url value="/resources/images/resultset_next.png" var="next_image_url" />
|
||||
<spring:message code="list_next" var="next_label" />
|
||||
<a class="image" href="${next}" title="${next_label}">
|
||||
<img alt="${next_label}" src="${next_image_url}" />
|
||||
</a>
|
||||
</c:if>
|
||||
<c:if test="${page ne maxPages}">
|
||||
<spring:url value="" var="last">
|
||||
<spring:param name="page" value="${maxPages}" />
|
||||
<spring:param name="size" value="${size}" />
|
||||
</spring:url>
|
||||
<spring:url value="/resources/images/resultset_last.png" var="last_image_url" />
|
||||
<spring:message code="list_last" var="last_label" />
|
||||
<a class="image" href="${last}" title="${last_label}">
|
||||
<img alt="${last_label}" src="${last_image_url}" />
|
||||
</a>
|
||||
</c:if>
|
||||
</c:if>
|
||||
</jsp:root>
|
||||
@@ -0,0 +1,32 @@
|
||||
<jsp:root xmlns:jsp="http://java.sun.com/JSP/Page" xmlns:fn="http://java.sun.com/jsp/jstl/functions" xmlns:spring="http://www.springframework.org/tags" xmlns:c="http://java.sun.com/jsp/jstl/core" version="2.0">
|
||||
<jsp:output omit-xml-declaration="yes" />
|
||||
<jsp:directive.attribute name="id" type="java.lang.String" required="true" description="The identifier for this tag (do not change!)" />
|
||||
<jsp:directive.attribute name="title" type="java.lang.String" required="true" description="The page title (required)" />
|
||||
<jsp:directive.attribute name="render" type="java.lang.Boolean" required="false" description="Indicate if the contents of this tag and all enclosed tags should be rendered (default 'true')" />
|
||||
<jsp:directive.attribute name="z" type="java.lang.String" required="false" description="Used for checking if element has been modified (to recalculate simply provide empty string value)" />
|
||||
<jsp:directive.attribute name="openPane" type="java.lang.String" required="false" description="Control if the title pane is opened or closed by default (default: true)" />
|
||||
|
||||
<c:if test="${empty render or render}">
|
||||
<c:if test="${empty openPane}">
|
||||
<c:set value="true" var="openPane" />
|
||||
</c:if>
|
||||
|
||||
<c:set var="sec_id">
|
||||
<spring:escapeBody javaScriptEscape="true" >${id}</spring:escapeBody>
|
||||
</c:set>
|
||||
|
||||
<c:set var="sec_openPane">
|
||||
<spring:escapeBody javaScriptEscape="true" >${openPane}</spring:escapeBody>
|
||||
</c:set>
|
||||
|
||||
<c:set var="sec_title">
|
||||
<spring:escapeBody javaScriptEscape="true" >${title}</spring:escapeBody>
|
||||
</c:set>
|
||||
|
||||
<script type="text/javascript">dojo.require('dijit.TitlePane');</script>
|
||||
<div id="_title_${sec_id}_id">
|
||||
<script type="text/javascript">Spring.addDecoration(new Spring.ElementDecoration({elementId : '_title_${sec_id}_id', widgetType : 'dijit.TitlePane', widgetAttrs : {title: '${sec_title}', open: ${sec_openPane}}})); </script>
|
||||
<jsp:doBody />
|
||||
</div>
|
||||
</c:if>
|
||||
</jsp:root>
|
||||
@@ -0,0 +1,4 @@
|
||||
<jsp:root xmlns:c="http://java.sun.com/jsp/jstl/core" xmlns:fn="http://java.sun.com/jsp/jstl/functions" xmlns:util="urn:jsptagdir:/WEB-INF/tags/util" xmlns:spring="http://www.springframework.org/tags" xmlns:form="http://www.springframework.org/tags/form" xmlns:jsp="http://java.sun.com/JSP/Page" version="2.0">
|
||||
<jsp:output omit-xml-declaration="yes" />
|
||||
<jsp:directive.attribute name="description" type="java.lang.String" required="false" description="Can be used to describe the purpose of this element" />
|
||||
</jsp:root>
|
||||
@@ -0,0 +1,36 @@
|
||||
<jsp:root xmlns:c="http://java.sun.com/jsp/jstl/core" xmlns:spring="http://www.springframework.org/tags" xmlns:jsp="http://java.sun.com/JSP/Page" version="2.0">
|
||||
<jsp:output omit-xml-declaration="yes" />
|
||||
|
||||
<jsp:directive.attribute name="render" type="java.lang.Boolean" required="false" description="Indicate if the contents of this tag and all enclosed tags should be rendered (default 'true')" />
|
||||
|
||||
<c:if test="${empty render or render}">
|
||||
<span>
|
||||
<c:out value=" | " />
|
||||
<spring:message code="global_theme" />
|
||||
<c:out value=": " />
|
||||
<spring:url var="url_theme1" value="">
|
||||
<spring:param name="theme" value="standard" />
|
||||
<c:if test="${not empty param.page}">
|
||||
<spring:param name="page" value="${param.page}" />
|
||||
</c:if>
|
||||
<c:if test="${not empty param.size}">
|
||||
<spring:param name="size" value="${param.size}" />
|
||||
</c:if>
|
||||
</spring:url>
|
||||
<spring:message code="global_theme_standard" var="theme_standard" />
|
||||
<a href="${url_theme1}" title="${theme_standard}">${theme_standard}</a>
|
||||
<c:out value=" | " />
|
||||
<spring:url var="url_theme2" value="">
|
||||
<spring:param name="theme" value="alt" />
|
||||
<c:if test="${not empty param.page}">
|
||||
<spring:param name="page" value="${param.page}" />
|
||||
</c:if>
|
||||
<c:if test="${not empty param.size}">
|
||||
<spring:param name="size" value="${param.size}" />
|
||||
</c:if>
|
||||
</spring:url>
|
||||
<spring:message code="global_theme_alt" var="theme_alt" />
|
||||
<a href="${url_theme2}" title="${theme_alt}">${theme_alt}</a>
|
||||
</span>
|
||||
</c:if>
|
||||
</jsp:root>
|
||||
@@ -0,0 +1,29 @@
|
||||
<div xmlns:c="http://java.sun.com/jsp/jstl/core" xmlns:util="urn:jsptagdir:/WEB-INF/tags/util" xmlns:fn="http://java.sun.com/jsp/jstl/functions" xmlns:spring="http://www.springframework.org/tags" xmlns:jsp="http://java.sun.com/JSP/Page" version="2.0">
|
||||
<jsp:output omit-xml-declaration="yes" />
|
||||
<spring:message var="title" code="error_dataaccessfailure_title" />
|
||||
<util:panel id="title" title="${title}">
|
||||
<h2>${fn:escapeXml(title)}</h2>
|
||||
<p>
|
||||
<spring:message code="error_dataaccessfailure_problemdescription" />
|
||||
</p>
|
||||
<c:if test="${not empty exception}">
|
||||
<p>
|
||||
<h4>
|
||||
<spring:message code="exception_details" />
|
||||
</h4>
|
||||
<spring:message var="message" code="exception_message" />
|
||||
<util:panel id="_message" title="${message}" openPane="false">
|
||||
<c:out value="${exception.localizedMessage}" />
|
||||
</util:panel>
|
||||
<spring:message var="stacktrace" code="exception_stacktrace" />
|
||||
<util:panel id="_exception" title="${stacktrace}" openPane="false">
|
||||
<c:forEach items="${exception.stackTrace}" var="trace">
|
||||
<c:out value="${trace}" />
|
||||
<br />
|
||||
</c:forEach>
|
||||
</util:panel>
|
||||
</p>
|
||||
</c:if>
|
||||
</util:panel>
|
||||
</div>
|
||||
|
||||
@@ -0,0 +1,36 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<div xmlns:c="http://java.sun.com/jsp/jstl/core" xmlns:fn="http://java.sun.com/jsp/jstl/functions" xmlns:jsp="http://java.sun.com/JSP/Page" xmlns:spring="http://www.springframework.org/tags" xmlns:util="urn:jsptagdir:/WEB-INF/tags/util" id="footer" version="2.0">
|
||||
<jsp:output omit-xml-declaration="yes"/>
|
||||
|
||||
<spring:url value="/" var="home"/>
|
||||
<span>
|
||||
<a href="${home}">
|
||||
<spring:message code="button_home"/>
|
||||
</a>
|
||||
</span>
|
||||
<c:if test="${pageContext['request'].userPrincipal != null}">
|
||||
<c:out value=" | "/>
|
||||
<span>
|
||||
<spring:url value="/resources/j_spring_security_logout" var="logout"/>
|
||||
<a href="${logout}">
|
||||
<spring:message code="security_logout"/>
|
||||
</a>
|
||||
</span>
|
||||
</c:if>
|
||||
|
||||
<span id="language">
|
||||
<c:out value=" | "/>
|
||||
<spring:message code="global_language"/>
|
||||
<c:out value=": "/>
|
||||
<util:language label="English" locale="en"/>
|
||||
</span>
|
||||
<util:theme/>
|
||||
|
||||
<spring:url value="/resources/images/springsource-logo.png" var="logo"/>
|
||||
<spring:message code="global_sponsored" var="sponsored"/>
|
||||
<span>
|
||||
<a href="http://springsource.com" title="${fn:escapeXml(sponsored)}">
|
||||
<img align="right" alt="${fn:escapeXml(sponsored)}" src="${logo}"/>
|
||||
</a>
|
||||
</span>
|
||||
</div>
|
||||
@@ -0,0 +1,10 @@
|
||||
<div id="header" xmlns:jsp="http://java.sun.com/JSP/Page" xmlns:fn="http://java.sun.com/jsp/jstl/functions" xmlns:c="http://java.sun.com/jsp/jstl/core" xmlns:spring="http://www.springframework.org/tags" version="2.0">
|
||||
<jsp:output omit-xml-declaration="yes" />
|
||||
|
||||
<spring:url var="banner" value="/resources/images/banner-graphic.png" />
|
||||
<spring:url var="home" value="/" />
|
||||
<spring:message code="button_home" var="home_label" />
|
||||
<a href="${home}" name="${fn:escapeXml(home_label)}" title="${fn:escapeXml(home_label)}">
|
||||
<img src="${banner}" />
|
||||
</a>
|
||||
</div>
|
||||
@@ -0,0 +1,10 @@
|
||||
<div xmlns:spring="http://www.springframework.org/tags" xmlns:util="urn:jsptagdir:/WEB-INF/tags/util" xmlns:jsp="http://java.sun.com/JSP/Page" version="2.0">
|
||||
<jsp:output omit-xml-declaration="yes" />
|
||||
<spring:message var="title" />
|
||||
<util:panel id="title" title="${title}">
|
||||
<spring:message code="application_name" var="app_name" />
|
||||
<h3>
|
||||
<spring:message code="welcome_titlepane" arguments="${app_name}" />
|
||||
</h3>
|
||||
</util:panel>
|
||||
</div>
|
||||
@@ -0,0 +1,13 @@
|
||||
<div xmlns:spring="http://www.springframework.org/tags" xmlns:util="urn:jsptagdir:/WEB-INF/tags/util" xmlns:jsp="http://java.sun.com/JSP/Page" version="2.0">
|
||||
<jsp:output omit-xml-declaration="yes" />
|
||||
<spring:message var="app_name" code="application_name" />
|
||||
<spring:message var="title" code="welcome_titlepane" arguments="${app_name}" />
|
||||
<util:panel id="title" title="${title}">
|
||||
<h3>
|
||||
<spring:message code="welcome_h3" arguments="${app_name}" />
|
||||
</h3>
|
||||
<p>
|
||||
<spring:message code="welcome_text" />
|
||||
</p>
|
||||
</util:panel>
|
||||
</div>
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<div xmlns:c="http://java.sun.com/jsp/jstl/core" xmlns:field="urn:jsptagdir:/WEB-INF/tags/form/fields" xmlns:form="urn:jsptagdir:/WEB-INF/tags/form" xmlns:jsp="http://java.sun.com/JSP/Page" xmlns:spring="http://www.springframework.org/tags" version="2.0">
|
||||
<jsp:output omit-xml-declaration="yes"/>
|
||||
<form:create id="fc_org_springframework_integration_samples_loanbroker_loanshark_domain_LoanShark" modelAttribute="loanShark" path="/loansharks" render="${empty dependencies}" z="c9pEi55VKZe+i8n9MzE/aMlC8jM=">
|
||||
<field:input field="name" id="c_org_springframework_integration_samples_loanbroker_loanshark_domain_LoanShark_name" z="bIEr/x7djyVFCXx8FZFe7Y6hZAw="/>
|
||||
<field:input field="counter" id="c_org_springframework_integration_samples_loanbroker_loanshark_domain_LoanShark_counter" validationMessageCode="field_invalid_integer" z="aGxodKJeAQkoD0u6NHf9KIYbXwM="/>
|
||||
<field:input field="averageRate" id="c_org_springframework_integration_samples_loanbroker_loanshark_domain_LoanShark_averageRate" validationMessageCode="field_invalid_number" z="y3sxODtPtAzxO4JNFPfZDcqtHhw="/>
|
||||
</form:create>
|
||||
<form:dependency dependencies="${dependencies}" id="d_org_springframework_integration_samples_loanbroker_loanshark_domain_LoanShark" render="${not empty dependencies}" z="GXoU6ZgW0KRwXUT6KeosjHODfa4="/>
|
||||
</div>
|
||||
@@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<div xmlns:field="urn:jsptagdir:/WEB-INF/tags/form/fields" xmlns:form="urn:jsptagdir:/WEB-INF/tags/form" xmlns:jsp="http://java.sun.com/JSP/Page" version="2.0">
|
||||
<jsp:output omit-xml-declaration="yes"/>
|
||||
<form:find finderName="ByName" id="ff_org_springframework_integration_samples_loanbroker_loanshark_domain_LoanShark" path="/loansharks" z="tSpyuQktrF7PRVI0I3fc8HnXFF0=">
|
||||
<field:input disableFormBinding="true" field="name" id="f_org_springframework_integration_samples_loanbroker_loanshark_domain_LoanShark_name" z="KVa/0Euz3jC9x02ukhm035J0xsY="/>
|
||||
</form:find>
|
||||
</div>
|
||||
@@ -0,0 +1,11 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<div xmlns:jsp="http://java.sun.com/JSP/Page" xmlns:page="urn:jsptagdir:/WEB-INF/tags/form" xmlns:table="urn:jsptagdir:/WEB-INF/tags/form/fields" version="2.0">
|
||||
<jsp:output omit-xml-declaration="yes"/>
|
||||
<page:list id="pl_org_springframework_integration_samples_loanbroker_loanshark_domain_LoanShark" items="${loansharks}" z="WGtRh8RDFNMOqm7ZR3sYpdytL8g=">
|
||||
<table:table data="${loansharks}" id="l_org_springframework_integration_samples_loanbroker_loanshark_domain_LoanShark" path="/loansharks" z="VSxTSbzuQSK29x6/yuWTZX93PT4=">
|
||||
<table:column id="c_org_springframework_integration_samples_loanbroker_loanshark_domain_LoanShark_name" property="name" z="jwBosQRlFEVQgr/SVFGsNnqbmlE="/>
|
||||
<table:column id="c_org_springframework_integration_samples_loanbroker_loanshark_domain_LoanShark_counter" property="counter" z="mvwK+T3kofhmBM1mMzos71NdB84="/>
|
||||
<table:column id="c_org_springframework_integration_samples_loanbroker_loanshark_domain_LoanShark_averageRate" property="averageRate" z="xbRLQN/1BJZqfz5t6Z5fRd7VUbE="/>
|
||||
</table:table>
|
||||
</page:list>
|
||||
</div>
|
||||
@@ -0,0 +1,9 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<div xmlns:field="urn:jsptagdir:/WEB-INF/tags/form/fields" xmlns:jsp="http://java.sun.com/JSP/Page" xmlns:page="urn:jsptagdir:/WEB-INF/tags/form" version="2.0">
|
||||
<jsp:output omit-xml-declaration="yes"/>
|
||||
<page:show id="ps_org_springframework_integration_samples_loanbroker_loanshark_domain_LoanShark" object="${loanshark}" path="/loansharks" z="K7r+Ec9zolOYwF2oKzKg+vUbbV4=">
|
||||
<field:display field="name" id="s_org_springframework_integration_samples_loanbroker_loanshark_domain_LoanShark_name" object="${loanshark}" z="LPR1Z66cGoFLFjgVat6MWvP98+I="/>
|
||||
<field:display field="counter" id="s_org_springframework_integration_samples_loanbroker_loanshark_domain_LoanShark_counter" object="${loanshark}" z="e+WKAm5/WYOABIGRiXjFUgOqgug="/>
|
||||
<field:display field="averageRate" id="s_org_springframework_integration_samples_loanbroker_loanshark_domain_LoanShark_averageRate" object="${loanshark}" z="z0fomsHnjIkEuROcZfwamf42j1w="/>
|
||||
</page:show>
|
||||
</div>
|
||||
@@ -0,0 +1,9 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<div xmlns:field="urn:jsptagdir:/WEB-INF/tags/form/fields" xmlns:form="urn:jsptagdir:/WEB-INF/tags/form" xmlns:jsp="http://java.sun.com/JSP/Page" version="2.0">
|
||||
<jsp:output omit-xml-declaration="yes"/>
|
||||
<form:update id="fu_org_springframework_integration_samples_loanbroker_loanshark_domain_LoanShark" modelAttribute="loanShark" path="/loansharks" z="mNB5KsJAJotLrVjasE3cKWnITEk=">
|
||||
<field:input field="name" id="c_org_springframework_integration_samples_loanbroker_loanshark_domain_LoanShark_name" z="bIEr/x7djyVFCXx8FZFe7Y6hZAw="/>
|
||||
<field:input field="counter" id="c_org_springframework_integration_samples_loanbroker_loanshark_domain_LoanShark_counter" validationMessageCode="field_invalid_integer" z="aGxodKJeAQkoD0u6NHf9KIYbXwM="/>
|
||||
<field:input field="averageRate" id="c_org_springframework_integration_samples_loanbroker_loanshark_domain_LoanShark_averageRate" validationMessageCode="field_invalid_number" z="y3sxODtPtAzxO4JNFPfZDcqtHhw="/>
|
||||
</form:update>
|
||||
</div>
|
||||
@@ -0,0 +1,19 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!DOCTYPE tiles-definitions PUBLIC "-//Apache Software Foundation//DTD Tiles Configuration 2.1//EN" "http://tiles.apache.org/dtds/tiles-config_2_1.dtd">
|
||||
<tiles-definitions>
|
||||
<definition extends="default" name="loansharks/list">
|
||||
<put-attribute name="body" value="/WEB-INF/views/loansharks/list.jspx"/>
|
||||
</definition>
|
||||
<definition extends="default" name="loansharks/show">
|
||||
<put-attribute name="body" value="/WEB-INF/views/loansharks/show.jspx"/>
|
||||
</definition>
|
||||
<definition extends="default" name="loansharks/create">
|
||||
<put-attribute name="body" value="/WEB-INF/views/loansharks/create.jspx"/>
|
||||
</definition>
|
||||
<definition extends="default" name="loansharks/update">
|
||||
<put-attribute name="body" value="/WEB-INF/views/loansharks/update.jspx"/>
|
||||
</definition>
|
||||
<definition extends="default" name="loansharks/findLoanSharksByName">
|
||||
<put-attribute name="body" value="/WEB-INF/views/loansharks/findLoanSharksByName.jspx"/>
|
||||
</definition>
|
||||
</tiles-definitions>
|
||||
@@ -0,0 +1,12 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<div xmlns:jsp="http://java.sun.com/JSP/Page" xmlns:menu="urn:jsptagdir:/WEB-INF/tags/menu" id="menu" version="2.0">
|
||||
<jsp:output omit-xml-declaration="yes"/>
|
||||
|
||||
<menu:menu id="_menu" z="nZaf43BjUg1iM0v70HJVEsXDopc=">
|
||||
<menu:category id="c_loanshark" z="8WhvO4BkJx0liJrPcVuP2MdHid0=">
|
||||
<menu:item id="i_loanshark_new" messageCode="global_menu_new" url="/loansharks?form" z="cljPwN6n9eTQzC6NQ3Xi2zVo/xA="/>
|
||||
<menu:item id="i_loanshark_list" messageCode="global_menu_list" url="/loansharks?page=${empty param.page ? 1 : param.page}&size=${empty param.size ? 10 : param.size}" z="VD7u9XTs1kINHz9TpYe/mckdgOo="/>
|
||||
<menu:item id="fi_loanshark_name" messageCode="global_menu_find" url="/loansharks?find=ByName&form" z="yOgcsk0sqfq0Xcy6NTnL6c8kJ74="/>
|
||||
</menu:category>
|
||||
</menu:menu>
|
||||
</div>
|
||||
@@ -0,0 +1,28 @@
|
||||
<div xmlns:c="http://java.sun.com/jsp/jstl/core" xmlns:fn="http://java.sun.com/jsp/jstl/functions" xmlns:spring="http://www.springframework.org/tags" xmlns:util="urn:jsptagdir:/WEB-INF/tags/util" xmlns:jsp="http://java.sun.com/JSP/Page" version="2.0">
|
||||
<jsp:output omit-xml-declaration="yes" />
|
||||
<spring:message var="title" code="error_resourcenotfound_title" />
|
||||
<util:panel id="title" title="${title}">
|
||||
<h2>${fn:escapeXml(title)}</h2>
|
||||
<p>
|
||||
<spring:message code="error_resourcenotfound_problemdescription" />
|
||||
</p>
|
||||
<c:if test="${not empty exception}">
|
||||
<p>
|
||||
<h4>
|
||||
<spring:message code="exception_details" />
|
||||
</h4>
|
||||
<spring:message var="message" code="exception_message" />
|
||||
<util:panel id="_message" title="${message}" openPane="false">
|
||||
<c:out value="${exception.localizedMessage}" />
|
||||
</util:panel>
|
||||
<spring:message var="stacktrace" code="exception_stacktrace" />
|
||||
<util:panel id="_exception" title="${stacktrace}" openPane="false">
|
||||
<c:forEach items="${exception.stackTrace}" var="trace">
|
||||
<c:out value="${trace}" />
|
||||
<br />
|
||||
</c:forEach>
|
||||
</util:panel>
|
||||
</p>
|
||||
</c:if>
|
||||
</util:panel>
|
||||
</div>
|
||||
@@ -0,0 +1,28 @@
|
||||
<div xmlns:c="http://java.sun.com/jsp/jstl/core" xmlns:fn="http://java.sun.com/jsp/jstl/functions" xmlns:util="urn:jsptagdir:/WEB-INF/tags/util" xmlns:spring="http://www.springframework.org/tags" xmlns:jsp="http://java.sun.com/JSP/Page" version="2.0">
|
||||
<jsp:output omit-xml-declaration="yes" />
|
||||
<spring:message var="title" code="error_uncaughtexception_title" />
|
||||
<util:panel id="title" title="${title}">
|
||||
<h2>${fn:escapeXml(title)}</h2>
|
||||
<p>
|
||||
<spring:message code="error_uncaughtexception_problemdescription" />
|
||||
</p>
|
||||
<c:if test="${not empty exception}">
|
||||
<p>
|
||||
<h4>
|
||||
<spring:message code="exception_details" />
|
||||
</h4>
|
||||
<spring:message var="message" code="exception_message" />
|
||||
<util:panel id="_message" title="${message}" openPane="false">
|
||||
<c:out value="${exception.localizedMessage}" />
|
||||
</util:panel>
|
||||
<spring:message var="stacktrace" code="exception_stacktrace" />
|
||||
<util:panel id="_exception" title="${stacktrace}" openPane="false">
|
||||
<c:forEach items="${exception.stackTrace}" var="trace">
|
||||
<c:out value="${trace}" />
|
||||
<br />
|
||||
</c:forEach>
|
||||
</util:panel>
|
||||
</p>
|
||||
</c:if>
|
||||
</util:panel>
|
||||
</div>
|
||||
@@ -0,0 +1,24 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE tiles-definitions PUBLIC
|
||||
"-//Apache Software Foundation//DTD Tiles Configuration 2.1//EN"
|
||||
"http://tiles.apache.org/dtds/tiles-config_2_1.dtd">
|
||||
|
||||
<tiles-definitions>
|
||||
|
||||
<definition name="index" extends="default">
|
||||
<put-attribute name="body" value="/WEB-INF/views/index.jspx" />
|
||||
</definition>
|
||||
|
||||
<definition name="dataAccessFailure" extends="public">
|
||||
<put-attribute name="body" value="/WEB-INF/views/dataAccessFailure.jspx" />
|
||||
</definition>
|
||||
|
||||
<definition name="resourceNotFound" extends="public">
|
||||
<put-attribute name="body" value="/WEB-INF/views/resourceNotFound.jspx" />
|
||||
</definition>
|
||||
|
||||
<definition name="uncaughtException" extends="public">
|
||||
<put-attribute name="body" value="/WEB-INF/views/uncaughtException.jspx" />
|
||||
</definition>
|
||||
|
||||
</tiles-definitions>
|
||||
98
case-studies/loanshark/src/main/webapp/WEB-INF/web.xml
Normal file
@@ -0,0 +1,98 @@
|
||||
<?xml version="1.0" encoding="ISO-8859-1" standalone="no"?>
|
||||
<web-app xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="2.4" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">
|
||||
|
||||
|
||||
<display-name>loanshark</display-name>
|
||||
|
||||
<description>Roo generated loanshark application</description>
|
||||
|
||||
|
||||
<!-- Enable escaping of form submission contents -->
|
||||
<context-param>
|
||||
<param-name>defaultHtmlEscape</param-name>
|
||||
<param-value>true</param-value>
|
||||
</context-param>
|
||||
|
||||
<context-param>
|
||||
<param-name>contextConfigLocation</param-name>
|
||||
<param-value>classpath*:META-INF/spring/applicationContext*.xml</param-value>
|
||||
</context-param>
|
||||
|
||||
<filter>
|
||||
<filter-name>Spring OpenEntityManagerInViewFilter</filter-name>
|
||||
<filter-class>org.springframework.orm.jpa.support.OpenEntityManagerInViewFilter</filter-class>
|
||||
</filter>
|
||||
|
||||
|
||||
|
||||
<filter>
|
||||
<filter-name>CharacterEncodingFilter</filter-name>
|
||||
<filter-class>org.springframework.web.filter.CharacterEncodingFilter</filter-class>
|
||||
<init-param>
|
||||
<param-name>encoding</param-name>
|
||||
<param-value>UTF-8</param-value>
|
||||
</init-param>
|
||||
<init-param>
|
||||
<param-name>forceEncoding</param-name>
|
||||
<param-value>true</param-value>
|
||||
</init-param>
|
||||
</filter>
|
||||
|
||||
<filter>
|
||||
<filter-name>HttpMethodFilter</filter-name>
|
||||
<filter-class>org.springframework.web.filter.HiddenHttpMethodFilter</filter-class>
|
||||
</filter>
|
||||
<filter-mapping>
|
||||
<filter-name>Spring OpenEntityManagerInViewFilter</filter-name>
|
||||
<url-pattern>/*</url-pattern>
|
||||
</filter-mapping>
|
||||
|
||||
<filter-mapping>
|
||||
<filter-name>CharacterEncodingFilter</filter-name>
|
||||
<url-pattern>/*</url-pattern>
|
||||
</filter-mapping>
|
||||
|
||||
<filter-mapping>
|
||||
<filter-name>HttpMethodFilter</filter-name>
|
||||
<url-pattern>/*</url-pattern>
|
||||
</filter-mapping>
|
||||
|
||||
<!-- Creates the Spring Container shared by all Servlets and Filters -->
|
||||
<listener>
|
||||
<listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
|
||||
</listener>
|
||||
|
||||
<!-- Handles Spring requests -->
|
||||
<servlet>
|
||||
<servlet-name>loanshark</servlet-name>
|
||||
<servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class>
|
||||
<init-param>
|
||||
<param-name>contextConfigLocation</param-name>
|
||||
<param-value>/WEB-INF/spring/webmvc-config.xml</param-value>
|
||||
</init-param>
|
||||
<load-on-startup>1</load-on-startup>
|
||||
</servlet>
|
||||
|
||||
<servlet-mapping>
|
||||
<servlet-name>loanshark</servlet-name>
|
||||
<url-pattern>/</url-pattern>
|
||||
</servlet-mapping>
|
||||
|
||||
<session-config>
|
||||
<session-timeout>10</session-timeout>
|
||||
</session-config>
|
||||
|
||||
<welcome-file-list>
|
||||
<welcome-file>/</welcome-file>
|
||||
</welcome-file-list>
|
||||
|
||||
<error-page>
|
||||
<exception-type>java.lang.Exception</exception-type>
|
||||
<location>/uncaughtException</location>
|
||||
</error-page>
|
||||
|
||||
<error-page>
|
||||
<error-code>404</error-code>
|
||||
<location>/resourceNotFound</location>
|
||||
</error-page>
|
||||
</web-app>
|
||||
BIN
case-studies/loanshark/src/main/webapp/images/add.png
Normal file
|
After Width: | Height: | Size: 739 B |
BIN
case-studies/loanshark/src/main/webapp/images/banner-graphic.png
Normal file
|
After Width: | Height: | Size: 13 KiB |
BIN
case-studies/loanshark/src/main/webapp/images/create.png
Normal file
|
After Width: | Height: | Size: 739 B |
BIN
case-studies/loanshark/src/main/webapp/images/delete.png
Normal file
|
After Width: | Height: | Size: 655 B |
BIN
case-studies/loanshark/src/main/webapp/images/en.png
Normal file
|
After Width: | Height: | Size: 599 B |
BIN
case-studies/loanshark/src/main/webapp/images/favicon.ico
Normal file
|
After Width: | Height: | Size: 1.4 KiB |
BIN
case-studies/loanshark/src/main/webapp/images/list.png
Normal file
|
After Width: | Height: | Size: 473 B |
|
After Width: | Height: | Size: 522 B |
BIN
case-studies/loanshark/src/main/webapp/images/resultset_last.png
Normal file
|
After Width: | Height: | Size: 524 B |
BIN
case-studies/loanshark/src/main/webapp/images/resultset_next.png
Normal file
|
After Width: | Height: | Size: 395 B |
|
After Width: | Height: | Size: 389 B |
BIN
case-studies/loanshark/src/main/webapp/images/show.png
Normal file
|
After Width: | Height: | Size: 879 B |
|
After Width: | Height: | Size: 4.9 KiB |
BIN
case-studies/loanshark/src/main/webapp/images/update.png
Normal file
|
After Width: | Height: | Size: 807 B |
362
case-studies/loanshark/src/main/webapp/styles/alt.css
Normal file
@@ -0,0 +1,362 @@
|
||||
/* main elements */
|
||||
|
||||
body,div,td {
|
||||
font-family: Arial, Helvetica, sans-serif;
|
||||
font-size: 12px;
|
||||
color: #666;
|
||||
}
|
||||
|
||||
body {
|
||||
background-color: #fff;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
#header {
|
||||
margin-bottom: 1em;
|
||||
}
|
||||
|
||||
#wrapper {
|
||||
width:800px;
|
||||
min-width: 800px;
|
||||
max-width: 800px;
|
||||
margin-right: auto;
|
||||
margin-left: auto;
|
||||
|
||||
/* fix max-width incompatibility in IE6 */
|
||||
width:expression(document.body.clientWidth > 800? "800px": "auto" );
|
||||
|
||||
overflow:hidden;
|
||||
display:block;
|
||||
}
|
||||
|
||||
/* header and footer elements */
|
||||
|
||||
#main {
|
||||
overflow:hidden;
|
||||
display:box;
|
||||
}
|
||||
|
||||
#menu {
|
||||
background: #eee;
|
||||
position:relative;
|
||||
float:right;
|
||||
left:0px;
|
||||
width:220px;
|
||||
margin-left:15px;
|
||||
}
|
||||
|
||||
#menu ul{
|
||||
list-style: none;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
#menu ul li{
|
||||
padding: 0px;
|
||||
}
|
||||
|
||||
|
||||
#menu a, #menu h2 {
|
||||
display: block;
|
||||
margin: 0;
|
||||
padding: 2px 6px;
|
||||
color:#FFFFFF;
|
||||
}
|
||||
|
||||
#menu h2 {
|
||||
color: #fff;
|
||||
background: #648C1D;
|
||||
text-transform: uppercase;
|
||||
font-weight:bold;
|
||||
font-size: 12px;
|
||||
}
|
||||
|
||||
#menu a {
|
||||
color: #666666;
|
||||
background: #efefef;
|
||||
text-decoration: none;
|
||||
padding: 2px 12px;
|
||||
}
|
||||
|
||||
#menu a:hover {
|
||||
color: #648C1D;
|
||||
background: #fff;
|
||||
}
|
||||
|
||||
#footer {
|
||||
background:#fff;
|
||||
border:none;
|
||||
margin-top:15px;
|
||||
border-top:1px solid #999999;
|
||||
}
|
||||
|
||||
#footer .new {
|
||||
float:left;
|
||||
}
|
||||
|
||||
#footer a:link {color: #7db223;}
|
||||
|
||||
.quicklinks {
|
||||
clear:both;
|
||||
padding-bottom: 15px
|
||||
}
|
||||
.quicklinks span {
|
||||
float: right;
|
||||
}
|
||||
|
||||
label {
|
||||
width:100px;
|
||||
float:left;
|
||||
margin-left: 5px;
|
||||
margin-top: 0px;
|
||||
}
|
||||
|
||||
input {
|
||||
height:20px;
|
||||
}
|
||||
|
||||
input, textarea, select {
|
||||
border:1px solid #B3B3B3;
|
||||
}
|
||||
|
||||
input.image {
|
||||
border: none;
|
||||
height: auto;
|
||||
}
|
||||
|
||||
submit {
|
||||
height:25px;
|
||||
}
|
||||
|
||||
div {
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
div .box {
|
||||
display:block;
|
||||
margin-left:105px;
|
||||
}
|
||||
|
||||
/* menu elements*/
|
||||
|
||||
a.menu, a.menu:link, a.menu:visited {display:block; width:150px; height:25px;}
|
||||
|
||||
/* text styles */
|
||||
|
||||
h1,h2,h3 {
|
||||
font-family: Helvetica, sans-serif;
|
||||
color: #7db223;
|
||||
}
|
||||
|
||||
h1 {
|
||||
font-size: 20px;
|
||||
line-height: 26px;
|
||||
}
|
||||
|
||||
h2 {
|
||||
font-size: 18px;
|
||||
line-height: 20px;
|
||||
}
|
||||
|
||||
h3 {
|
||||
font-size: 15px;
|
||||
line-height: 21px;
|
||||
color:#555;
|
||||
}
|
||||
|
||||
h4 {
|
||||
font-size: 14px;
|
||||
line-height: 20px;
|
||||
}
|
||||
|
||||
.errors {
|
||||
color: red;
|
||||
font-weight: bold;
|
||||
display: block;
|
||||
margin-left: 105px;
|
||||
}
|
||||
|
||||
a {
|
||||
text-decoration: underline;
|
||||
font-size: 12px;
|
||||
}
|
||||
|
||||
a img {
|
||||
border: 0 none;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
tr:nth-child(odd) {
|
||||
background-color: #FFFFFF;
|
||||
}
|
||||
|
||||
tr:nth-child(even) {
|
||||
background-color: #EFEFEF;
|
||||
}
|
||||
|
||||
a:link {
|
||||
color: #7db223;
|
||||
}
|
||||
|
||||
a:hover {
|
||||
color: #456314;
|
||||
}
|
||||
|
||||
a:active {
|
||||
color: #7db223;
|
||||
}
|
||||
|
||||
a:visited {
|
||||
color: #7db223;
|
||||
}
|
||||
|
||||
li {
|
||||
padding-top: 5px;
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
ul li {
|
||||
margin:0 0 0.25em 0;
|
||||
padding:0;
|
||||
}
|
||||
/* table elements */
|
||||
|
||||
table {
|
||||
background: #EEEEEE;
|
||||
margin: 2px 0 0 0;
|
||||
border: 1px solid #BBBBBB;
|
||||
border-collapse: collapse;
|
||||
width: 100%
|
||||
}
|
||||
|
||||
table table {
|
||||
margin: -5px 0;
|
||||
border: 0px solid #e0e7d3;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
table td,table th {
|
||||
padding: 2px;
|
||||
border: 1px solid #CCCCCC;
|
||||
}
|
||||
|
||||
table td form {
|
||||
text-align:center;
|
||||
vertical-align: middle;
|
||||
margin: 0px;
|
||||
}
|
||||
|
||||
table th {
|
||||
font-size: 0.9em;
|
||||
text-align: left;
|
||||
font-weight: bold;
|
||||
color: #FFF;
|
||||
background: #999;
|
||||
}
|
||||
|
||||
table thead {
|
||||
font-weight: bold;
|
||||
font-style: italic;
|
||||
background-color: #BBBBBB;
|
||||
}
|
||||
|
||||
table a:link {color: #303030;}
|
||||
|
||||
caption {
|
||||
caption-side: top;
|
||||
width: auto;
|
||||
text-align: left;
|
||||
font-size: 12px;
|
||||
color: #848f73;
|
||||
padding-bottom: 4px;
|
||||
}
|
||||
|
||||
fieldset {
|
||||
background: #e0e7d3;
|
||||
padding: 8px;
|
||||
padding-bottom: 22px;
|
||||
border: none;
|
||||
width: 560px;
|
||||
}
|
||||
|
||||
fieldset label {
|
||||
width: 70px;
|
||||
float: left;
|
||||
margin-top: 1.7em;
|
||||
margin-left: 20px;
|
||||
}
|
||||
|
||||
fieldset textfield {
|
||||
margin: 3px;
|
||||
height: 20px;
|
||||
background: #e0e7d3;
|
||||
}
|
||||
|
||||
fieldset textarea {
|
||||
margin: 3px;
|
||||
height: 165px;
|
||||
background: #e0e7d3;
|
||||
}
|
||||
|
||||
fieldset input {
|
||||
margin: 3px;
|
||||
height: 20px;
|
||||
background: #e0e7d3;
|
||||
}
|
||||
|
||||
fieldset table {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
fieldset th {
|
||||
padding-left: 25px;
|
||||
}
|
||||
|
||||
.table-buttons {
|
||||
background-color:#fff;
|
||||
border:none;
|
||||
}
|
||||
|
||||
.table-buttons td {
|
||||
border:none;
|
||||
}
|
||||
|
||||
.submit input {
|
||||
border: 1px solid #BBBBBB;
|
||||
color:#777777;
|
||||
padding:2px 7px;
|
||||
font-size:11px;
|
||||
text-transform:uppercase;
|
||||
font-weight:bold;
|
||||
height:24px;
|
||||
}
|
||||
|
||||
.updated {
|
||||
background:#ecf1e5;
|
||||
font-size:11px;
|
||||
margin-left:2px;
|
||||
border:4px solid #ecf1e5;
|
||||
}
|
||||
|
||||
.updated td {
|
||||
padding:2px 8px;
|
||||
font-size:11px;
|
||||
color:#888888;
|
||||
}
|
||||
|
||||
.dijitTextArea{
|
||||
min-height:5.5em !important;
|
||||
max-height:22em !important;
|
||||
overflow-y: auto !important;
|
||||
max-width: 175px;
|
||||
}
|
||||
|
||||
.RichTextEditable{
|
||||
min-height:18em !important;
|
||||
max-height:18em !important;
|
||||
}
|
||||
|
||||
.flag {
|
||||
height: 11px;
|
||||
width: 16px;
|
||||
}
|
||||
366
case-studies/loanshark/src/main/webapp/styles/standard.css
Normal file
@@ -0,0 +1,366 @@
|
||||
/* main elements */
|
||||
|
||||
body,div,td {
|
||||
font-family: Arial, Helvetica, sans-serif;
|
||||
font-size: 12px;
|
||||
color: #666;
|
||||
}
|
||||
|
||||
body {
|
||||
background-color: #fff;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
#header {
|
||||
margin-bottom: 1em;
|
||||
}
|
||||
|
||||
#wrapper {
|
||||
width:800px;
|
||||
min-width: 800px;
|
||||
max-width: 800px;
|
||||
margin-right: auto;
|
||||
margin-left: auto;
|
||||
|
||||
/* fix max-width incompatibility in IE6 */
|
||||
width:expression(document.body.clientWidth > 800? "800px": "auto" );
|
||||
|
||||
overflow:hidden;
|
||||
display:block;
|
||||
}
|
||||
|
||||
/* header and footer elements */
|
||||
|
||||
#main {
|
||||
overflow:hidden;
|
||||
display:box;
|
||||
}
|
||||
|
||||
#menu {
|
||||
background: #eee;
|
||||
position:relative;
|
||||
float:left;
|
||||
left:0px;
|
||||
width:220px;
|
||||
margin-right:15px;
|
||||
}
|
||||
|
||||
#menu ul{
|
||||
list-style: none;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
#menu ul li{
|
||||
padding: 0px;
|
||||
}
|
||||
|
||||
|
||||
#menu a, #menu h2 {
|
||||
display: block;
|
||||
margin: 0;
|
||||
padding: 2px 6px;
|
||||
color:#FFFFFF;
|
||||
}
|
||||
|
||||
#menu h2 {
|
||||
color: #fff;
|
||||
background: #648C1D;
|
||||
text-transform: uppercase;
|
||||
font-weight:bold;
|
||||
font-size: 12px;
|
||||
}
|
||||
|
||||
#menu a {
|
||||
color: #666666;
|
||||
background: #efefef;
|
||||
text-decoration: none;
|
||||
padding: 2px 12px;
|
||||
}
|
||||
|
||||
#menu a:hover {
|
||||
color: #648C1D;
|
||||
background: #fff;
|
||||
}
|
||||
|
||||
#footer {
|
||||
background:#fff;
|
||||
border:none;
|
||||
margin-top:15px;
|
||||
border-top:1px solid #999999;
|
||||
}
|
||||
|
||||
#footer .new {
|
||||
float:left;
|
||||
}
|
||||
|
||||
#footer a:link {color: #7db223;}
|
||||
|
||||
.quicklinks {
|
||||
clear:both;
|
||||
padding-bottom: 15px
|
||||
}
|
||||
.quicklinks span {
|
||||
float: right;
|
||||
}
|
||||
|
||||
table.navigation {
|
||||
border: 0px;
|
||||
}
|
||||
|
||||
label {
|
||||
width:100px;
|
||||
float:left;
|
||||
margin-left: 5px;
|
||||
margin-top: 0px;
|
||||
}
|
||||
|
||||
input {
|
||||
height:20px;
|
||||
}
|
||||
|
||||
input, textarea, select {
|
||||
border:1px solid #B3B3B3;
|
||||
}
|
||||
|
||||
input.image {
|
||||
border: none;
|
||||
height: auto;
|
||||
}
|
||||
|
||||
submit {
|
||||
height:25px;
|
||||
}
|
||||
|
||||
div {
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
div .box {
|
||||
display:block;
|
||||
margin-left:105px;
|
||||
}
|
||||
|
||||
/* menu elements*/
|
||||
|
||||
a.menu, a.menu:link, a.menu:visited {display:block; width:150px; height:25px;}
|
||||
|
||||
/* text styles */
|
||||
|
||||
h1,h2,h3 {
|
||||
font-family: Helvetica, sans-serif;
|
||||
color: #7db223;
|
||||
}
|
||||
|
||||
h1 {
|
||||
font-size: 20px;
|
||||
line-height: 26px;
|
||||
}
|
||||
|
||||
h2 {
|
||||
font-size: 18px;
|
||||
line-height: 20px;
|
||||
}
|
||||
|
||||
h3 {
|
||||
font-size: 15px;
|
||||
line-height: 21px;
|
||||
color:#555;
|
||||
}
|
||||
|
||||
h4 {
|
||||
font-size: 14px;
|
||||
line-height: 20px;
|
||||
}
|
||||
|
||||
.errors {
|
||||
color: red;
|
||||
font-weight: bold;
|
||||
display: block;
|
||||
margin-left: 105px;
|
||||
}
|
||||
|
||||
a {
|
||||
text-decoration: underline;
|
||||
font-size: 12px;
|
||||
}
|
||||
|
||||
a img {
|
||||
border: 0 none;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
tr:nth-child(odd) {
|
||||
background-color: #FFFFFF;
|
||||
}
|
||||
|
||||
tr:nth-child(even) {
|
||||
background-color: #EFEFEF;
|
||||
}
|
||||
|
||||
a:link {
|
||||
color: #7db223;
|
||||
}
|
||||
|
||||
a:hover {
|
||||
color: #456314;
|
||||
}
|
||||
|
||||
a:active {
|
||||
color: #7db223;
|
||||
}
|
||||
|
||||
a:visited {
|
||||
color: #7db223;
|
||||
}
|
||||
|
||||
li {
|
||||
padding-top: 5px;
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
ul li {
|
||||
margin:0 0 0.25em 0;
|
||||
padding:0;
|
||||
}
|
||||
/* table elements */
|
||||
|
||||
table {
|
||||
background: #EEEEEE;
|
||||
margin: 2px 0 0 0;
|
||||
border: 1px solid #BBBBBB;
|
||||
border-collapse: collapse;
|
||||
width: 100%
|
||||
}
|
||||
|
||||
table table {
|
||||
margin: -5px 0;
|
||||
border: 0px solid #e0e7d3;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
table td,table th {
|
||||
padding: 2px;
|
||||
border: 1px solid #CCCCCC;
|
||||
}
|
||||
|
||||
table td form {
|
||||
text-align:center;
|
||||
vertical-align: middle;
|
||||
margin: 0px;
|
||||
}
|
||||
|
||||
table th {
|
||||
font-size: 0.9em;
|
||||
text-align: left;
|
||||
font-weight: bold;
|
||||
color: #FFF;
|
||||
background: #999;
|
||||
}
|
||||
|
||||
table thead {
|
||||
font-weight: bold;
|
||||
font-style: italic;
|
||||
background-color: #BBBBBB;
|
||||
}
|
||||
|
||||
table a:link {color: #303030;}
|
||||
|
||||
caption {
|
||||
caption-side: top;
|
||||
width: auto;
|
||||
text-align: left;
|
||||
font-size: 12px;
|
||||
color: #848f73;
|
||||
padding-bottom: 4px;
|
||||
}
|
||||
|
||||
fieldset {
|
||||
background: #e0e7d3;
|
||||
padding: 8px;
|
||||
padding-bottom: 22px;
|
||||
border: none;
|
||||
width: 560px;
|
||||
}
|
||||
|
||||
fieldset label {
|
||||
width: 70px;
|
||||
float: left;
|
||||
margin-top: 1.7em;
|
||||
margin-left: 20px;
|
||||
}
|
||||
|
||||
fieldset textfield {
|
||||
margin: 3px;
|
||||
height: 20px;
|
||||
background: #e0e7d3;
|
||||
}
|
||||
|
||||
fieldset textarea {
|
||||
margin: 3px;
|
||||
height: 165px;
|
||||
background: #e0e7d3;
|
||||
}
|
||||
|
||||
fieldset input {
|
||||
margin: 3px;
|
||||
height: 20px;
|
||||
background: #e0e7d3;
|
||||
}
|
||||
|
||||
fieldset table {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
fieldset th {
|
||||
padding-left: 25px;
|
||||
}
|
||||
|
||||
.table-buttons {
|
||||
background-color:#fff;
|
||||
border:none;
|
||||
}
|
||||
|
||||
.table-buttons td {
|
||||
border:none;
|
||||
}
|
||||
|
||||
.submit input {
|
||||
border: 1px solid #BBBBBB;
|
||||
color:#777777;
|
||||
padding:2px 7px;
|
||||
font-size:11px;
|
||||
text-transform:uppercase;
|
||||
font-weight:bold;
|
||||
height:24px;
|
||||
}
|
||||
|
||||
.updated {
|
||||
background:#ecf1e5;
|
||||
font-size:11px;
|
||||
margin-left:2px;
|
||||
border:4px solid #ecf1e5;
|
||||
}
|
||||
|
||||
.updated td {
|
||||
padding:2px 8px;
|
||||
font-size:11px;
|
||||
color:#888888;
|
||||
}
|
||||
|
||||
.dijitTextArea{
|
||||
min-height:5.5em !important;
|
||||
max-height:22em !important;
|
||||
overflow-y: auto !important;
|
||||
max-width: 175px;
|
||||
}
|
||||
|
||||
.RichTextEditable{
|
||||
min-height:18em !important;
|
||||
max-height:18em !important;
|
||||
}
|
||||
|
||||
.flag {
|
||||
height: 11px;
|
||||
width: 16px;
|
||||
}
|
||||
@@ -0,0 +1,53 @@
|
||||
/*
|
||||
* Copyright 2002-2010 the original author or authors.
|
||||
*
|
||||
* Licensed 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.springframework.integration.samples.loanbroker.loanshark.biz;
|
||||
|
||||
|
||||
import static junit.framework.Assert.assertEquals;
|
||||
|
||||
import org.junit.Test;
|
||||
import org.junit.runner.RunWith;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.integration.samples.loanbroker.loanshark.biz.Accumulator;
|
||||
import org.springframework.integration.samples.loanbroker.loanshark.biz.SharkQuote;
|
||||
import org.springframework.integration.samples.loanbroker.loanshark.domain.LoanShark;
|
||||
import org.springframework.test.context.ContextConfiguration;
|
||||
import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* @author Gary Russell
|
||||
*
|
||||
*/
|
||||
@ContextConfiguration(locations="classpath:META-INF/spring/applicationContext.xml")
|
||||
@RunWith(SpringJUnit4ClassRunner.class)
|
||||
public class TestAccumulator {
|
||||
|
||||
@Autowired
|
||||
Accumulator accumulator;
|
||||
|
||||
@Test
|
||||
@Transactional
|
||||
public void test() {
|
||||
accumulator.accumulate(new SharkQuote("fred", 6.0d));
|
||||
accumulator.accumulate(new SharkQuote("fred", 6.2d));
|
||||
LoanShark shark = (LoanShark) LoanShark.findLoanSharksByName("fred").getSingleResult();
|
||||
assertEquals(new Long(2), shark.getCounter());
|
||||
assertEquals(new Double(6.1), shark.getAverageRate());
|
||||
}
|
||||
}
|
||||
12
case-studies/loanshark/src/test/resources/log4j.properties
Normal file
@@ -0,0 +1,12 @@
|
||||
#Updated at Tue Mar 23 17:20:25 PDT 2010
|
||||
#Tue Mar 23 17:20:25 PDT 2010
|
||||
log4j.appender.stdout=org.apache.log4j.ConsoleAppender
|
||||
log4j.rootLogger=DEBUG, stdout, R
|
||||
log4j.appender.R.File=application.log
|
||||
log4j.appender.R.MaxFileSize=100KB
|
||||
log4j.appender.R.layout=org.apache.log4j.PatternLayout
|
||||
log4j.appender.R.MaxBackupIndex=1
|
||||
log4j.appender.R.layout.ConversionPattern=%p %t %c - %m%n
|
||||
log4j.appender.stdout.layout.ConversionPattern=%d [%t] %-5p %c - %m%n
|
||||
log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
|
||||
log4j.appender.R=org.apache.log4j.RollingFileAppender
|
||||
BIN
case-studies/loanshark/target/.DS_Store
vendored
Normal file
12
case-studies/loanshark/target/classes/META-INF/aop-ajc.xml
Normal file
@@ -0,0 +1,12 @@
|
||||
<aspectj>
|
||||
<aspects>
|
||||
<aspect name="org.springframework.integration.samples.loanbroker.loanshark.domain.LoanShark_Roo_Entity"/>
|
||||
<aspect name="org.springframework.integration.samples.loanbroker.loanshark.domain.LoanShark_Roo_Finder"/>
|
||||
<aspect name="org.springframework.integration.samples.loanbroker.loanshark.domain.LoanShark_Roo_ToString"/>
|
||||
<aspect name="org.springframework.integration.samples.loanbroker.loanshark.web.SharkController_Roo_Controller"/>
|
||||
<aspect name="org.springframework.integration.samples.loanbroker.loanshark.domain.LoanShark_Roo_Json"/>
|
||||
<aspect name="org.springframework.integration.samples.loanbroker.loanshark.domain.LoanShark_Roo_Configurable"/>
|
||||
<aspect name="org.springframework.integration.samples.loanbroker.loanshark.domain.LoanShark_Roo_JavaBean"/>
|
||||
</aspects>
|
||||
</aspectj>
|
||||
|
||||