velocity-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cbris...@apache.org
Subject svn commit: r1298906 [1/14] - in /velocity/sandbox/velosurf: ./ docs/ examples/ examples/ant-vpp/ examples/ant-vpp/lib/ examples/auth-l10n/ examples/auth-l10n/WEB-INF/ examples/auth-l10n/WEB-INF/lib/ examples/auth-l10n/WEB-INF/src/ examples/auth-l10n/e...
Date Fri, 09 Mar 2012 16:23:32 GMT
Author: cbrisson
Date: Fri Mar  9 16:23:25 2012
New Revision: 1298906

URL: http://svn.apache.org/viewvc?rev=1298906&view=rev
Log:
add velosurf in the sandbox

Added:
    velocity/sandbox/velosurf/
    velocity/sandbox/velosurf/CHANGELOG
    velocity/sandbox/velosurf/LICENSE
    velocity/sandbox/velosurf/NOTICE
    velocity/sandbox/velosurf/README
    velocity/sandbox/velosurf/TODO
    velocity/sandbox/velosurf/build.properties
    velocity/sandbox/velosurf/build.xml
    velocity/sandbox/velosurf/docs/
    velocity/sandbox/velosurf/docs/architecture.html
    velocity/sandbox/velosurf/docs/class-diagram.png   (with props)
    velocity/sandbox/velosurf/docs/class-diagram.sxd   (with props)
    velocity/sandbox/velosurf/docs/configuration.html
    velocity/sandbox/velosurf/docs/download.html
    velocity/sandbox/velosurf/docs/dtd.html
    velocity/sandbox/velosurf/docs/faq.html
    velocity/sandbox/velosurf/docs/index.html
    velocity/sandbox/velosurf/docs/installation.html
    velocity/sandbox/velosurf/docs/logo.png   (with props)
    velocity/sandbox/velosurf/docs/overview.html
    velocity/sandbox/velosurf/docs/powered-by-logo.gif   (with props)
    velocity/sandbox/velosurf/docs/title.png   (with props)
    velocity/sandbox/velosurf/docs/user-guide.html
    velocity/sandbox/velosurf/docs/velosurf.css
    velocity/sandbox/velosurf/docs/velosurf.dtd
    velocity/sandbox/velosurf/docs/vtl-reference.html
    velocity/sandbox/velosurf/examples/
    velocity/sandbox/velosurf/examples/ant-vpp/
    velocity/sandbox/velosurf/examples/ant-vpp/README
    velocity/sandbox/velosurf/examples/ant-vpp/build.xml
    velocity/sandbox/velosurf/examples/ant-vpp/demo.sh   (with props)
    velocity/sandbox/velosurf/examples/ant-vpp/foo.java.vtl
    velocity/sandbox/velosurf/examples/ant-vpp/lib/
    velocity/sandbox/velosurf/examples/ant-vpp/lib/vpp-2.2.1.jar   (with props)
    velocity/sandbox/velosurf/examples/ant-vpp/model.xml
    velocity/sandbox/velosurf/examples/auth-l10n/
    velocity/sandbox/velosurf/examples/auth-l10n/README
    velocity/sandbox/velosurf/examples/auth-l10n/WEB-INF/
    velocity/sandbox/velosurf/examples/auth-l10n/WEB-INF/lib/
    velocity/sandbox/velosurf/examples/auth-l10n/WEB-INF/model.xml
    velocity/sandbox/velosurf/examples/auth-l10n/WEB-INF/src/
    velocity/sandbox/velosurf/examples/auth-l10n/WEB-INF/src/DBAuthenticator.java
    velocity/sandbox/velosurf/examples/auth-l10n/WEB-INF/src/DBLocalizer.java
    velocity/sandbox/velosurf/examples/auth-l10n/WEB-INF/toolbox.xml
    velocity/sandbox/velosurf/examples/auth-l10n/WEB-INF/velocity.properties
    velocity/sandbox/velosurf/examples/auth-l10n/WEB-INF/web.xml
    velocity/sandbox/velosurf/examples/auth-l10n/en/
    velocity/sandbox/velosurf/examples/auth-l10n/en/auth/
    velocity/sandbox/velosurf/examples/auth-l10n/en/auth/index.html.vtl
    velocity/sandbox/velosurf/examples/auth-l10n/en/index.html.vtl
    velocity/sandbox/velosurf/examples/auth-l10n/en/login.html.vtl
    velocity/sandbox/velosurf/examples/auth-l10n/en/md5.js
    velocity/sandbox/velosurf/examples/auth-l10n/fr/
    velocity/sandbox/velosurf/examples/auth-l10n/fr/auth/
    velocity/sandbox/velosurf/examples/auth-l10n/fr/auth/index.html.vtl
    velocity/sandbox/velosurf/examples/auth-l10n/fr/index.html.vtl
    velocity/sandbox/velosurf/examples/auth-l10n/fr/login.html.vtl
    velocity/sandbox/velosurf/examples/auth-l10n/fr/md5.js
    velocity/sandbox/velosurf/examples/auth-l10n/index.html
    velocity/sandbox/velosurf/examples/blank-webapp/
    velocity/sandbox/velosurf/examples/blank-webapp/WEB-INF/
    velocity/sandbox/velosurf/examples/blank-webapp/WEB-INF/lib/
    velocity/sandbox/velosurf/examples/blank-webapp/WEB-INF/macros.vtl
    velocity/sandbox/velosurf/examples/blank-webapp/WEB-INF/model.xml
    velocity/sandbox/velosurf/examples/blank-webapp/WEB-INF/tools.xml
    velocity/sandbox/velosurf/examples/blank-webapp/WEB-INF/velocity.properties
    velocity/sandbox/velosurf/examples/blank-webapp/WEB-INF/web.xml
    velocity/sandbox/velosurf/examples/blank-webapp/doctype.inc
    velocity/sandbox/velosurf/examples/blank-webapp/footer.inc
    velocity/sandbox/velosurf/examples/blank-webapp/header.inc
    velocity/sandbox/velosurf/examples/blank-webapp/index.vhtml
    velocity/sandbox/velosurf/examples/blank-webapp/main.css
    velocity/sandbox/velosurf/examples/blank-webapp/top.inc
    velocity/sandbox/velosurf/examples/bookstore/
    velocity/sandbox/velosurf/examples/bookstore/README
    velocity/sandbox/velosurf/examples/bookstore/WEB-INF/
    velocity/sandbox/velosurf/examples/bookstore/WEB-INF/toolbox.xml
    velocity/sandbox/velosurf/examples/bookstore/WEB-INF/velocity.properties
    velocity/sandbox/velosurf/examples/bookstore/WEB-INF/velosurf.xml
    velocity/sandbox/velosurf/examples/bookstore/WEB-INF/web.xml
    velocity/sandbox/velosurf/examples/bookstore/author_commit.vtl
    velocity/sandbox/velosurf/examples/bookstore/author_delete.vtl
    velocity/sandbox/velosurf/examples/bookstore/author_form.vtl
    velocity/sandbox/velosurf/examples/bookstore/book_commit.vtl
    velocity/sandbox/velosurf/examples/bookstore/book_delete.vtl
    velocity/sandbox/velosurf/examples/bookstore/book_form.vtl
    velocity/sandbox/velosurf/examples/bookstore/bookstore.sql
    velocity/sandbox/velosurf/examples/bookstore/index.vtl
    velocity/sandbox/velosurf/examples/bookstore/publisher_commit.vtl
    velocity/sandbox/velosurf/examples/bookstore/publisher_delete.vtl
    velocity/sandbox/velosurf/examples/bookstore/publisher_form.vtl
    velocity/sandbox/velosurf/examples/validation/
    velocity/sandbox/velosurf/examples/validation/README
    velocity/sandbox/velosurf/src/
    velocity/sandbox/velosurf/src/java/
    velocity/sandbox/velosurf/src/java/org/
    velocity/sandbox/velosurf/src/java/org/apache/
    velocity/sandbox/velosurf/src/java/org/apache/velocity/
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/Velosurf.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/cache/
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/cache/Cache.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/cache/package.html
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/context/
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/context/AttributeReference.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/context/DBReference.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/context/EntityReference.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/context/ExternalObjectWrapper.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/context/HasParametrizedGetter.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/context/Instance.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/context/RowIterator.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/context/package.html
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/model/
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/model/Action.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/model/Attribute.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/model/Entity.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/model/ExportedKey.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/model/ImportedKey.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/model/Transaction.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/model/package.html
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/package.html
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/sql/
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/sql/ConfigLoader.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/sql/ConnectionPool.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/sql/ConnectionWrapper.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/sql/ConnectionWrapper.java.jdk5
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/sql/ConnectionWrapper.java.jdk6
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/sql/Database.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/sql/DriverInfo.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/sql/Pool.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/sql/PooledPreparedStatement.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/sql/PooledSimpleStatement.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/sql/PooledStatement.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/sql/PreparedStatementPool.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/sql/ReadOnlyMap.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/sql/ReverseEngineer.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/sql/RowHandler.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/sql/SqlUtil.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/sql/StatementPool.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/sql/package.html
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/util/
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/util/Cryptograph.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/util/DBResourceLoader.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/util/DESCryptograph.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/util/DNSResolver.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/util/Enumerator.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/util/FastHttpDateFormat.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/util/HashMultiMap.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/util/LineWriterOutputStream.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/util/Logger.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/util/MailNotifier.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/util/MultiMap.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/util/NullServlet.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/util/ReaderInputStream.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/util/SavedRequest.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/util/SavedRequestWrapper.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/util/ServletLogWriter.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/util/StringLists.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/util/Strings.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/util/TemplateNameFilter.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/util/ToolFinder.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/util/UserContext.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/util/VelosurfLogChute.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/util/VelosurfUberspector.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/util/WriterOutputStream.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/util/XIncludeResolver.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/util/package.html
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/validation/
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/validation/DateRange.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/validation/EmailCheck.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/validation/FieldConstraint.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/validation/Length.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/validation/NotEmpty.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/validation/NotNull.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/validation/OneOf.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/validation/Range.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/validation/Reference.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/validation/Regex.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/validation/RowConstraint.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/validation/ValidationFilter.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/validation/package.html
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/web/
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/web/HttpQueryTool.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/web/VelosurfTool.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/web/auth/
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/web/auth/AuthenticationFilter.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/web/auth/BaseAuthenticator.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/web/auth/SimpleDBAuthenticator.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/web/auth/package.html
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/web/l10n/
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/web/l10n/HTTPLocalizerTool.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/web/l10n/LocalizationFilter.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/web/l10n/Localizer.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/web/l10n/SimpleDBLocalizer.java
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/web/l10n/package.html
    velocity/sandbox/velosurf/src/java/org/apache/velocity/velosurf/web/package.html
    velocity/sandbox/velosurf/src/javascript/
    velocity/sandbox/velosurf/src/javascript/md5-LICENSE
    velocity/sandbox/velosurf/src/javascript/md5.js
    velocity/sandbox/velosurf/src/javascript/sha1.js
    velocity/sandbox/velosurf/test/
    velocity/sandbox/velosurf/test/conf/
    velocity/sandbox/velosurf/test/conf/included.xml
    velocity/sandbox/velosurf/test/conf/included2.xml
    velocity/sandbox/velosurf/test/conf/model.xml
    velocity/sandbox/velosurf/test/hsqlclient.sh   (with props)
    velocity/sandbox/velosurf/test/hsqldb.sh   (with props)
    velocity/sandbox/velosurf/test/jetty/
    velocity/sandbox/velosurf/test/jetty/etc/
    velocity/sandbox/velosurf/test/jetty/etc/jetty.xml
    velocity/sandbox/velosurf/test/jetty/etc/webdefault.xml
    velocity/sandbox/velosurf/test/jetty/jetty.sh   (with props)
    velocity/sandbox/velosurf/test/jetty/src/
    velocity/sandbox/velosurf/test/jetty/src/WebappLogger.class   (with props)
    velocity/sandbox/velosurf/test/jetty/src/WebappLogger.java
    velocity/sandbox/velosurf/test/sql/
    velocity/sandbox/velosurf/test/sql/initial.sql
    velocity/sandbox/velosurf/test/src/
    velocity/sandbox/velosurf/test/src/blackbox/
    velocity/sandbox/velosurf/test/src/blackbox/BlackboxTests.java
    velocity/sandbox/velosurf/test/src/whitebox/
    velocity/sandbox/velosurf/test/src/whitebox/sql/
    velocity/sandbox/velosurf/test/src/whitebox/sql/WhiteboxTests.java
    velocity/sandbox/velosurf/test/webapp/
    velocity/sandbox/velosurf/test/webapp/WEB-INF/
    velocity/sandbox/velosurf/test/webapp/WEB-INF/db.xml
    velocity/sandbox/velosurf/test/webapp/WEB-INF/included.xml
    velocity/sandbox/velosurf/test/webapp/WEB-INF/included2.xml
    velocity/sandbox/velosurf/test/webapp/WEB-INF/toolbox.xml
    velocity/sandbox/velosurf/test/webapp/WEB-INF/velocity.properties
    velocity/sandbox/velosurf/test/webapp/WEB-INF/web.xml
    velocity/sandbox/velosurf/test/webapp/auth/
    velocity/sandbox/velosurf/test/webapp/auth/index.vhtml
    velocity/sandbox/velosurf/test/webapp/auth/protected.html
    velocity/sandbox/velosurf/test/webapp/basic.vhtml
    velocity/sandbox/velosurf/test/webapp/externalparam.vhtml
    velocity/sandbox/velosurf/test/webapp/fetch.vhtml
    velocity/sandbox/velosurf/test/webapp/goodvalues.html
    velocity/sandbox/velosurf/test/webapp/index.vhtml
    velocity/sandbox/velosurf/test/webapp/input.vhtml
    velocity/sandbox/velosurf/test/webapp/insert.vhtml
    velocity/sandbox/velosurf/test/webapp/localized/
    velocity/sandbox/velosurf/test/webapp/localized/en/
    velocity/sandbox/velosurf/test/webapp/localized/en/auth/
    velocity/sandbox/velosurf/test/webapp/localized/en/auth/index.vhtml
    velocity/sandbox/velosurf/test/webapp/localized/en/forbidden.html
    velocity/sandbox/velosurf/test/webapp/localized/en/index.vhtml
    velocity/sandbox/velosurf/test/webapp/localized/en/login.vhtml
    velocity/sandbox/velosurf/test/webapp/localized/en/login.vjs
    velocity/sandbox/velosurf/test/webapp/localized/fr/
    velocity/sandbox/velosurf/test/webapp/localized/fr/auth/
    velocity/sandbox/velosurf/test/webapp/localized/fr/auth/index.vhtml
    velocity/sandbox/velosurf/test/webapp/localized/fr/forbidden.html
    velocity/sandbox/velosurf/test/webapp/localized/fr/index.vhtml
    velocity/sandbox/velosurf/test/webapp/localized/fr/login.vhtml
    velocity/sandbox/velosurf/test/webapp/localized/fr/login.vjs
    velocity/sandbox/velosurf/test/webapp/login.vhtml
    velocity/sandbox/velosurf/test/webapp/md5.js
    velocity/sandbox/velosurf/test/webapp/obfuscate.vhtml
    velocity/sandbox/velosurf/test/webapp/test.html
    velocity/sandbox/velosurf/test/webapp/xinclude.vhtml

Added: velocity/sandbox/velosurf/CHANGELOG
URL: http://svn.apache.org/viewvc/velocity/sandbox/velosurf/CHANGELOG?rev=1298906&view=auto
==============================================================================
--- velocity/sandbox/velosurf/CHANGELOG (added)
+++ velocity/sandbox/velosurf/CHANGELOG Fri Mar  9 16:23:25 2012
@@ -0,0 +1,381 @@
+***** Changes ****
+
+v2.3 (February 2012)
+----
+ - new: sha1 encryption library for authentication
+ - fix: xinclude for non-webapp Velosurf tool
+ - fix: bug in reverse enginer partial mode
+ - new: added a check interval parameter for connections
+ - new: always use Long for numeric key values
+ - fix: NPE on null parameters
+ - fix: potential concurrency problem during imported and exported keys initialization
+ - new: AttributeRef.getInstanceMap() method
+ - fix: Entity column ordering was wrong
+ - fix: startup action was broken
+ - fix: review statements busy state handling (statements could sometimes remain in busy state)
+ - new: a <database> check-connections attribute to avoid connections checking (still true by default)
+ - new: Instances do keep a dirty flag per updatable column for faster updates
+ - fix: transactions with more than two queries where wrongly parsed
+ - fix: AuthFilter redirection after login could fail
+ - fix: RowIterator column names caching was broken
+ - new: Instance.upsert() method
+ - new: DBReference and EntityReference toString() method now returns useful debugging infos
+ - fix: column ordering in Instance is now natural rather than alphabetical
+ - fix: null values do appear in Instance map
+ - new: a driver-specific value filter (used for instance to call Calendar.getDate() for mysql)
+ - new: parametrized getters (give a Map of external parameters as argument to attribute/action parameters)
+ - new: flag to use login.do referer if no saved request when succesfully authentified
+ - new: let the user customize AuthenticationFilter session keys
+ - fix: refresh cached instance of logged user at each request
+ - new: added Entity.getAttributes() and Entity.getActions()
+ - fix: don't log anything during Logger initialization
+ - new: allows db user & password to be specified within the JDBC URL
+ - new: added model.Entity.getColumnType(column)
+
+v2.2.1 (September 2008)
+------
+ - fix: filters out requests towards login.do when already authentified in AuthenticationFilter
+ - fix: EmailChecker smtp validation was broken
+ - new: getAuthenticatedIndexPage() takes the http session as argument
+ - fix: authentication filter now uses the overloadable getAuthenticatedIndexPage() method
+
+v2.2 (September 2008)
+----
+ - fix: RowIterator.hasNext now works when called several times in a row
+ - new: method velosurf.VelosurfTool.getDatabase() to ease the use of Velosurf from Java
+ - fix: Attribute.getRows() had a memory leak
+ - fix: Entity.fetch(Map) could fail without reason
+ - fix: corrected a concurrency problem in statement pools
+ - new: added an 'order' attribute to <exported-key>
+ - new: method HttpQueryTool.getExtraKeys()
+ - fix: compilation under java 1.6 now works
+ - new: mail notifications (see Logger.java api)
+ - new: caching attribute for entity attributes
+ - fix: Instance.get(key) now takes an Object argument to propery inherit parent's generic getter
+ - new: added the debugging method $query.queryString
+ - new: url, driver and schema can now be part of <database> or of <credentials>
+ - fix: populate last inserted IDs in instances when needed on insertion
+ - new: Entity.extractColumnValues now allows additionnal columns when comming from the sql side
+ - fix: HttpQueryTool needed a get(String) method besides the get(Object) one to properly override inherited generic getter
+ - new: added an optional <credentials> element in the config file to gather credentials out of the <database> element
+ - new: added method instance.setColumnValues
+ - fix: cache key calculation was not always right
+ - fix: internal instance values are now stored using sql column values and aliases can be multiple
+ - new: added an experimental DBResourceLoader Velocity resource loader
+ - fix: aliases were not taken into account in Entity.extractColumnValues
+ - fix: aliases were never read by the ConfigLoader
+ - fix: the localizer tool now checks if the locale changes in the session
+ - fix: authentication filter now also remembers the query string of the saved request
+ - new: added entityref.delete(string) and entityref.delete(number) for unique primary cols
+ - fix: exported keys were broken.
+ - fix: do not forget query string when redirecting!
+ - fix: validation: unecessary user context re-creations avoided
+ - new: added user context getter and setter to DBReference
+ - fix: Entity.fetch(Map) now checks for key values instead of throwing an exception if they are not present
+ - new: added the missing EntityReference.newInstance(Map) method
+ - fix: some methods of UserContext had to be synchronized
+ - fix: UserContext.getValidationErrors() now clears the validation errors for the next call
+ - new: made login and password form field names configurable in AuthenticationFilter
+ - new: added the getter BaseAuthenticator.getLoggedUser()
+ - fix: web.VelosurfTool now avoid overwriting a previously thread-locally initialized user context in the database
+ - fix: removed all VelosurfTool methods taking an unused UserContext argument
+ - fix: made the LocalizationFilter less verbose
+ - fix: SimpleDBLocalizer no longer throws an exception when the 'localized' table is not found
+
+v2.1 (November 2006)
+----
+ - fix: bug in last insert id feature (at least for hsqldb, not for mysql)
+ - added some new testcases
+ - fix: template name filter cache resetting produced a wrong output
+ - cleaned and reduced the use of ReadOnlyMap
+ - fix: NPE in Entity.insert
+ - simplified UserContext handling: now it is a thread-local member of sql.Database
+ - fix: RowIterator behaviour is now ok for empty result sets with bugged JDBC drivers like HSQLDB
+ - docfix: parameter 'config' was named 'configuration' in the documentation
+
+v2.0 (November 2006)
+----
+ - full code review (field accesses, javadoc, unused methods)
+ - added an ant/vpp example (thanks to Mike Kienenberger)
+ - added a Logger.log2File(String file) method
+ - changed the behaviour of the 'full' caching method.
+ - aliases tag for column names
+ - manual definition of imported and exported keys
+ - optimized reflection code in ExternalObjectWrapper
+ - case used in context can now be set using the system property velosurf.case
+ - cleaned behaviour of RowIterator: hasNext() can now be called sereval times per iteration
+ - Velosurf now has a functional DTD - thanks to Mike Kienenberger
+ - suppressed the autofetching feature (can be implemented by a custom filter)
+ - last inserted ID is now hold by the user context
+ - localized messages can now have arguments
+ - build files moved under the /build/ directory
+ - reverse enginering of imported and exported keys, new reverse level ("tables")
+ - removed unused method vel.sql.Database.readConfigFile(String file)
+ - XInclude basic inclusion mechanism
+ - new method velosurf.Velosurf.setConfigFile to facilitate VPP inclusion
+   the velosurf.Velosurf class now does a late initialization.
+ - HSQLDB infos updated in DriverInfo
+ - renamed DataAccessor to ReadOnlyMap and MapDataAccessor to ReadOnlyWrapper
+ - HttpQueryTool now inherits org.apache.velocity.tools.view.tools.ParameterParser
+ - bugfix: Entity.fetch(Number) no longer bypass obfuscation
+ - DriverInfo now has an ignorePrefix String per driver (should be generalized with a regex)
+ - added an EntityReference.getName() method which returns the name of the wrapped entity.
+ - bugfix: rewrote code for transactions which did not ensure a proper isolation
+ - the ConnectionWrapper busy state is now an integer, to allow imbriqued busy states
+ - created a UserContext map (that is stored in the session in a webapp context):
+   contains sql error messages, validation error messages and localizer.
+ - blackbox testcases using Jetty and HttpUnit
+ - whitebox testcases using JUnit
+ - needed jar libraries are now automatically downloaded from the maven repository at build time
+ - bugfix: instance.update() was possible on a read-only entity
+ - replaced database attribute "default-access=rw|ro" with attribute "read-only=true|false"
+ - added validation constraints and a ValidationFilter
+ - added a ReverseEngineer class and moved corresponding code out of Database
+ - added a ConfigLoader class and moved corresponding code out of Database
+ - added a TemplateNameFilter which adds ".vtl" to template URIs
+ - added an abstract localization tool (HTTPLocalizerTool) and a mechanism by which localized
+   columns of an instance are resolved on-the-fly.
+ - added a LocalizationFilter that triggers redirections and forwards in respect to the localization scheme.
+ - added an authentication scheme (AuthenticationFilter and AuthenticatorTool).
+ - added an example webapp to demonstrate authentication and l10n.
+ - "Using config file..." message only logged on database connection creation.
+ - marked the "full" caching method as deprecated.
+ - replaced gnu regexps by jdk ones.
+ - tolerate and eat a semi-colon at the end of queries.
+ - sources reorganization - got rid of the 'tools' package, web tools now are in a 'web' package
+
+v1.4.4 (November 2006)
+------
+Mainly some backports of the v2.0 development.
+ - docfix: separate the DTD from the doc (and put a valid DTD file, thanks to Mike Kienenberger).
+ - fix: cache invalidation on update and delete
+ - fix: operations now REALLY forbidden on read-only database!
+ - updated driver infos for HSQLDB, added ones for DERBY
+ - backported the late init mechanism in velosurf.Velosurf
+ - fix: fetch(Number) no longer bypass obfuscation
+ - explicitely use velocity-tools 1.2
+
+v1.4.3 (September 2006)
+------
+ - added static methods getConnection(configfile,servletcontext) and getDefaultConnection(servletcontext)
+   to VelosurfTool.
+ - renamed Database.newInstance to Database.getInstance (consistency).
+ - fix: bug in the recovery process (bad statements not properly removed)
+ - fix: ConnectionWrapper now handles itself a 'closed' boolean flag (to work around buggy drivers)
+
+v1.4.2 (May 2006)
+------
+ - fix: bug in the recovery process (concurrent access to the list of statements)
+
+v1.4.1 (May 2006)
+------
+ - fix: AttributeReference properties are cleared from DatabaseReference when new values
+   are set into external parameters
+ - fix: the process of deletion of bad statements during the recovery was broken
+
+
+v1.4 (March 2006)
+----
+
+ - added the database 'seed' property to specify the random seed used by the cryptograph
+ - supressed the deprecated reference to RowInterator in Instance
+ - Instance method internalGet now checks external object
+ - added the ability to map rows with external objets (POJOs) via an ExternalObjectWrapper class
+ - added some new constructors to the standalone tool
+ - copied the class velosurf.standalone.Velosurf to class velosurf.Velosurf and deprecated the latter
+ - made Database internal maps private
+ - use a stringbuffer where possible in queries construction
+ - removed some old deprecated methods
+ - added a default constructor for Instance
+ - corrected classpath errors in build.xml
+ - doc: updated the class-diagram
+ - added an Instance.equals() method that checks key values if possible
+ - added a getRows() method to RowIterator, AttributeReference and EntityReference
+
+v1.3.1 (June 2005)
+------
+
+ - getLastInsertID now returns an obfuscated value if the ID column is obfuscated for that column
+ - doc: speech about not keeping long lifecycle references of prep statements objects
+ - doc: the 'table' attribute was missing
+ - fix: clear the DBReference cache when external parameters are set on the db
+ - fix: 'ro' and 'rw' param values for 'default-access' where inverted
+ - fix: obfuscate and deobfuscate methods now also do http encoding and decoding
+
+v1.3 (November 2004)
+---
+
+ - added min-connections and max-connections parameters to the database configuration
+ - docs: added details about obfuscation and autofetching in the overview
+ - docs: added a page about Velosurf architecture
+ - the jars for Velocity, Velocity-tools and their dependencies are no longer included in the tarball
+ - introduced a ConnectionWrapper class to handle a 'busy' state per connection
+ - moved getLastInsertId method to DriverInfo
+ - renamed DBConnection to Database
+ - moved checkConnection to ConnectionWrapper
+ - introduced a ConnectionPool class
+ - removed Database.reconnect() method: meaningless when using connection pools
+ - moved all the calls to Pooled[Prepared]Statement.notifyInUse() from Database to [Prepared]StatementPool
+ - fix: PreparedStatementPool.evaluate was throwing an exception for an empty result
+
+v1.2 (September 2004)
+----
+
+ - fix: obfuscation was broken.
+ - added VelosurfTool.getConnection(config) and VelosurfTool.getDefaultConnection() methods
+
+v1.1 (September 2004)
+----
+
+ - made Instance inherit from TreeMap so that order of columns is preserved
+ - fix: a root attribute with a rowset result throwed a NullException under some case policies
+ - made standalone.Velosurf.findConfig() static
+ - fix: VelosurfTool.configure was throwing a NullException when a null parameter was given
+ - add the missing method getColumns( ) to EntityReference
+ - made Instance.getEntity( ) return an EntityReference instead of an Entity
+
+v1.0 (June 2004)
+----
+
+ - fix: added missing DOCTYPE tag to the bookstore sample web.xml
+ - fix: the ISBN field was missing in book_form.html in the bookstore sample
+ - velosurf.tool.VelosurfTool now supports VelTools initialization parameters (very usefull when dealing with several DBs)
+ - new 'reverse' option to control the degree of reverse enginering (none|partial|full)
+ - reenginering of the initialization methods for sql.DBConnection: now the config file is fully parsed before connecting to the database
+ - docs: some clarifications on the case-sensivity policy
+ - fix: external parameters now work with entities (were working only with root attributes)
+ - logging debug level now set via velosurf.xml
+ - jce1_2_2.jar and sunjce_provider.jar not included anymore in the tarball
+ - the Cryptograph class is loaded only if obfuscation is actually used
+  - VelosurfTool.initDB made protected
+  - connection caches (by connection params or by config file)
+  - entities can be referenced across VelosurfTool instances binded to different schemas
+
+v0.9.1 (March 2004)
+------
+
+ - fix: root actions were not visible from VTL
+ - fix: bookstore sample was broken (reviewed sql file, added missing autofetch attributes)
+ - full rewrite of the driver-specific infos
+ - 'startup' root action executed at startup
+ - code cleaning in DBConnection and Entity - deprecated methods removed
+ - case handling policies
+ - schemas: added automatic selection of current schema (schema was only used for name resolution)
+ - call DriverManager.setLogStream instead of DriverManager.setLogWriter so that JDBC 1.0 drivers can log
+ - fix: automatic database driver class determination wasn't working
+ - docs corrected for syntax, grammar and clarity by Kai Carver (thanks Kai!)
+
+v0.9 (February 2004)
+----
+
+ - added obfuscation methods to DBReference to allow by hand obfuscation
+ - updated license stuff files (apache/gnu/sun)
+ - Logger: log2stdout & log2stderr methods
+ - Logger: stdout and stderr methods renamed from startLogStdout
+ - added autofetching of instances from HTTP parameters
+ - added a FAQ
+ - added class and docs for standalone usage
+ - deprecated old instance fetch/update/insert methods of DBConnection
+ - deprecated Instance.getKeys in favor of the new method Instance.getPrimaryKey
+ - much cleaner parsing in refineQuery and orderQuery
+ - checkConnection behaviour is now specific to each database vendor
+ - applied changes submitted by Asar Khan:
+   . schema database attribute
+   . explicitely close resultsets in finally blocks
+   . don't load tables whose name contains '/'
+ - bookstore sample
+ - docs: updated configuration documentation for the 'table' attribute
+ - query parameters automatic obfuscation
+ - table aliasing
+ - bug "java.lang.NoClassDefFoundError:org/gjt/mm/mysql/Statement" (when using another dbms than MySql) corrected
+ - bug: several DBConnection methods were checking the normal connection, not the one dedicated to transactions
+
+v0.8 (October 17, 2003)
+----
+
+ - support for transactions
+ - javadoc'ed almost all the files
+ - fetch methods now take a Number instead of an Integer
+ - methods to clean the cache for an entity
+ - methods clearRefinement to remode any refinement on an attribute or an entity
+ - setting the order to an empty string reset it
+ - VelosurfTool can now be used in any scope (application / session / request)
+
+v0.7.1 (September 2003)
+------
+
+ - HttpQueryTool now has getStrings and getInts methods
+ - some simple examples added to the doc
+ - velocity wants a Map interface to allow a generic setter
+
+v0.7 (September 2003)
+----
+
+ - many additions to the docs
+ - method Instance.initialize()
+ - action tag
+ - soft caching
+ - When fetching instances, automatically read all fields and put them in the instance's map (allows iterations on fields and meta-info fetching)
+ - Moved all resultset metainfo stuff to SqlUtil
+ - Added a getUri() method to HttpQueryTool
+
+v0.6.1 (March 2003)
+------
+ - now compatible with the new velocity-tools sourcetree
+ - bug with java.sql.Timestamp columns: time was reseted at update
+
+v0.6 (February 21, 2003)
+----
+
+ - support for external parameters in attributes
+ - velosurf is no longer case insensitive for table and column names
+ - attribute lastInsertID for entities (only with mysql for now)
+ - db connections recovery is now functional
+
+v0.5.1 (July 22,2002)
+------
+ - bug in PreparedStatementPool.clear() corrected
+ - added $query.getInt(key)
+
+v0.5 (July 8,2002)
+----
+
+ - connection is checked and reopened if down
+ - config can be done via an xml file
+ - conversion utility def2xml: convert config file from .def format to .xml format
+ - access control (/entity)
+ - return the 'natural' slq->java type for each column
+ - behaviour with null values: issue calls to ResultSet.wasNull()
+ - velosurf appears as a Velocity ViewTool
+ - http query parameters are now parsed by HttpQueryTool, another ViewTool
+
+v0.3 & 0.4 (May-June 2002)
+----------
+
+ - added easier fetch methods for single-column primary keys
+ - property velosurf.template.extension (extension to add to extension-less uris to find templates)
+ - corrected newInstance package bug
+ - avoid putting multivalued arrays in a new instance value
+ - check that Instance methods 'update' and 'delete' affect only 1 row... warn if 0, error if >1
+ - log now adds a date & time header
+ - fetch(Map)
+ - VelosurfServlet now inherits VelocityViewServlet
+ - integers are returned as Integer
+ - fetch(Integer)
+ - uses ViewToolLogger
+ - instance update was calling Map.get and not Instance.get
+
+v0.2 (April 17,2002)
+----
+
+ - Query is now optional in non-root attribute definitions (in which case, the fetch query of the associated entity is used).
+ - Core objects are not any more passed to the context, but wrapped in 'reference' objects (see velosurf.context package).
+ - Attribute definitions can now be done from inside a template file ; the special file "database.vm", if found, is used to build a context from which new ones are chained.
+ - Iterators are created only on demand, thus no more velocity warning and entities and attributes properties can be accessed.
+ - Ordering can now be achieved via the 'order' property of entities and attributes.
+ - Entity and attribute queries can now be refined via the 'refine( )' method.
+
+v0.1 (March 1,2002)
+----
+
+ - Initial release

Added: velocity/sandbox/velosurf/LICENSE
URL: http://svn.apache.org/viewvc/velocity/sandbox/velosurf/LICENSE?rev=1298906&view=auto
==============================================================================
--- velocity/sandbox/velosurf/LICENSE (added)
+++ velocity/sandbox/velosurf/LICENSE Fri Mar  9 16:23:25 2012
@@ -0,0 +1,202 @@
+
+                                 Apache License
+                           Version 2.0, January 2004
+                        http://www.apache.org/licenses/
+
+   TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+   1. Definitions.
+
+      "License" shall mean the terms and conditions for use, reproduction,
+      and distribution as defined by Sections 1 through 9 of this document.
+
+      "Licensor" shall mean the copyright owner or entity authorized by
+      the copyright owner that is granting the License.
+
+      "Legal Entity" shall mean the union of the acting entity and all
+      other entities that control, are controlled by, or are under common
+      control with that entity. For the purposes of this definition,
+      "control" means (i) the power, direct or indirect, to cause the
+      direction or management of such entity, whether by contract or
+      otherwise, or (ii) ownership of fifty percent (50%) or more of the
+      outstanding shares, or (iii) beneficial ownership of such entity.
+
+      "You" (or "Your") shall mean an individual or Legal Entity
+      exercising permissions granted by this License.
+
+      "Source" form shall mean the preferred form for making modifications,
+      including but not limited to software source code, documentation
+      source, and configuration files.
+
+      "Object" form shall mean any form resulting from mechanical
+      transformation or translation of a Source form, including but
+      not limited to compiled object code, generated documentation,
+      and conversions to other media types.
+
+      "Work" shall mean the work of authorship, whether in Source or
+      Object form, made available under the License, as indicated by a
+      copyright notice that is included in or attached to the work
+      (an example is provided in the Appendix below).
+
+      "Derivative Works" shall mean any work, whether in Source or Object
+      form, that is based on (or derived from) the Work and for which the
+      editorial revisions, annotations, elaborations, or other modifications
+      represent, as a whole, an original work of authorship. For the purposes
+      of this License, Derivative Works shall not include works that remain
+      separable from, or merely link (or bind by name) to the interfaces of,
+      the Work and Derivative Works thereof.
+
+      "Contribution" shall mean any work of authorship, including
+      the original version of the Work and any modifications or additions
+      to that Work or Derivative Works thereof, that is intentionally
+      submitted to Licensor for inclusion in the Work by the copyright owner
+      or by an individual or Legal Entity authorized to submit on behalf of
+      the copyright owner. For the purposes of this definition, "submitted"
+      means any form of electronic, verbal, or written communication sent
+      to the Licensor or its representatives, including but not limited to
+      communication on electronic mailing lists, source code control systems,
+      and issue tracking systems that are managed by, or on behalf of, the
+      Licensor for the purpose of discussing and improving the Work, but
+      excluding communication that is conspicuously marked or otherwise
+      designated in writing by the copyright owner as "Not a Contribution."
+
+      "Contributor" shall mean Licensor and any individual or Legal Entity
+      on behalf of whom a Contribution has been received by Licensor and
+      subsequently incorporated within the Work.
+
+   2. Grant of Copyright License. Subject to the terms and conditions of
+      this License, each Contributor hereby grants to You a perpetual,
+      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+      copyright license to reproduce, prepare Derivative Works of,
+      publicly display, publicly perform, sublicense, and distribute the
+      Work and such Derivative Works in Source or Object form.
+
+   3. Grant of Patent License. Subject to the terms and conditions of
+      this License, each Contributor hereby grants to You a perpetual,
+      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+      (except as stated in this section) patent license to make, have made,
+      use, offer to sell, sell, import, and otherwise transfer the Work,
+      where such license applies only to those patent claims licensable
+      by such Contributor that are necessarily infringed by their
+      Contribution(s) alone or by combination of their Contribution(s)
+      with the Work to which such Contribution(s) was submitted. If You
+      institute patent litigation against any entity (including a
+      cross-claim or counterclaim in a lawsuit) alleging that the Work
+      or a Contribution incorporated within the Work constitutes direct
+      or contributory patent infringement, then any patent licenses
+      granted to You under this License for that Work shall terminate
+      as of the date such litigation is filed.
+
+   4. Redistribution. You may reproduce and distribute copies of the
+      Work or Derivative Works thereof in any medium, with or without
+      modifications, and in Source or Object form, provided that You
+      meet the following conditions:
+
+      (a) You must give any other recipients of the Work or
+          Derivative Works a copy of this License; and
+
+      (b) You must cause any modified files to carry prominent notices
+          stating that You changed the files; and
+
+      (c) You must retain, in the Source form of any Derivative Works
+          that You distribute, all copyright, patent, trademark, and
+          attribution notices from the Source form of the Work,
+          excluding those notices that do not pertain to any part of
+          the Derivative Works; and
+
+      (d) If the Work includes a "NOTICE" text file as part of its
+          distribution, then any Derivative Works that You distribute must
+          include a readable copy of the attribution notices contained
+          within such NOTICE file, excluding those notices that do not
+          pertain to any part of the Derivative Works, in at least one
+          of the following places: within a NOTICE text file distributed
+          as part of the Derivative Works; within the Source form or
+          documentation, if provided along with the Derivative Works; or,
+          within a display generated by the Derivative Works, if and
+          wherever such third-party notices normally appear. The contents
+          of the NOTICE file are for informational purposes only and
+          do not modify the License. You may add Your own attribution
+          notices within Derivative Works that You distribute, alongside
+          or as an addendum to the NOTICE text from the Work, provided
+          that such additional attribution notices cannot be construed
+          as modifying the License.
+
+      You may add Your own copyright statement to Your modifications and
+      may provide additional or different license terms and conditions
+      for use, reproduction, or distribution of Your modifications, or
+      for any such Derivative Works as a whole, provided Your use,
+      reproduction, and distribution of the Work otherwise complies with
+      the conditions stated in this License.
+
+   5. Submission of Contributions. Unless You explicitly state otherwise,
+      any Contribution intentionally submitted for inclusion in the Work
+      by You to the Licensor shall be under the terms and conditions of
+      this License, without any additional terms or conditions.
+      Notwithstanding the above, nothing herein shall supersede or modify
+      the terms of any separate license agreement you may have executed
+      with Licensor regarding such Contributions.
+
+   6. Trademarks. This License does not grant permission to use the trade
+      names, trademarks, service marks, or product names of the Licensor,
+      except as required for reasonable and customary use in describing the
+      origin of the Work and reproducing the content of the NOTICE file.
+
+   7. Disclaimer of Warranty. Unless required by applicable law or
+      agreed to in writing, Licensor provides the Work (and each
+      Contributor provides its Contributions) on an "AS IS" BASIS,
+      WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+      implied, including, without limitation, any warranties or conditions
+      of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+      PARTICULAR PURPOSE. You are solely responsible for determining the
+      appropriateness of using or redistributing the Work and assume any
+      risks associated with Your exercise of permissions under this License.
+
+   8. Limitation of Liability. In no event and under no legal theory,
+      whether in tort (including negligence), contract, or otherwise,
+      unless required by applicable law (such as deliberate and grossly
+      negligent acts) or agreed to in writing, shall any Contributor be
+      liable to You for damages, including any direct, indirect, special,
+      incidental, or consequential damages of any character arising as a
+      result of this License or out of the use or inability to use the
+      Work (including but not limited to damages for loss of goodwill,
+      work stoppage, computer failure or malfunction, or any and all
+      other commercial damages or losses), even if such Contributor
+      has been advised of the possibility of such damages.
+
+   9. Accepting Warranty or Additional Liability. While redistributing
+      the Work or Derivative Works thereof, You may choose to offer,
+      and charge a fee for, acceptance of support, warranty, indemnity,
+      or other liability obligations and/or rights consistent with this
+      License. However, in accepting such obligations, You may act only
+      on Your own behalf and on Your sole responsibility, not on behalf
+      of any other Contributor, and only if You agree to indemnify,
+      defend, and hold each Contributor harmless for any liability
+      incurred by, or claims asserted against, such Contributor by reason
+      of your accepting any such warranty or additional liability.
+
+   END OF TERMS AND CONDITIONS
+
+   APPENDIX: How to apply the Apache License to your work.
+
+      To apply the Apache License to your work, attach the following
+      boilerplate notice, with the fields enclosed by brackets "[]"
+      replaced with your own identifying information. (Don't include
+      the brackets!)  The text should be enclosed in the appropriate
+      comment syntax for the file format. We also recommend that a
+      file or class name and description of purpose be included on the
+      same "printed page" as the copyright notice for easier
+      identification within third-party archives.
+
+   Copyright [yyyy] [name of copyright owner]
+
+   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.

Added: velocity/sandbox/velosurf/NOTICE
URL: http://svn.apache.org/viewvc/velocity/sandbox/velosurf/NOTICE?rev=1298906&view=auto
==============================================================================
--- velocity/sandbox/velosurf/NOTICE (added)
+++ velocity/sandbox/velosurf/NOTICE Fri Mar  9 16:23:25 2012
@@ -0,0 +1,2 @@
+This product includes software developed by
+The Apache Software Foundation (http://www.apache.org/).

Added: velocity/sandbox/velosurf/README
URL: http://svn.apache.org/viewvc/velocity/sandbox/velosurf/README?rev=1298906&view=auto
==============================================================================
--- velocity/sandbox/velosurf/README (added)
+++ velocity/sandbox/velosurf/README Fri Mar  9 16:23:25 2012
@@ -0,0 +1,49 @@
+This is the README file for Velosurf.
+
+WHAT IS IT ? 
+------------
+
+Velosurf is a database access layer for the Apache Velocity template engine
+(http://velocity.apache.org). It provides an automatic database mapping
+of tables and relationships without any code generation.
+
+In the context of a Webapp, Velosurf also provides handy tools for
+authentication, localization and forms validation.
+
+WHY VELOSURF ?
+--------------
+
+Mainly, to avoid rewriting each time specific database mapping layers in each
+project involving velocity and database entities that template writers have to
+deal with.
+
+Velosurf comes from a design architecture paradigm called the Pull Model, or
+the Toolbox Model. It inherits the standard MVC (Model-View-Controller)
+architecture paradigm, and its main idea is that the view layer should rely on
+a series of dedicated tools that designers use to create views.
+
+The VelocityTools subproject offers the ability to configure context tools
+from a standard xml config for Velocity.
+
+Velosurf appears as such a tool.
+
+HOW TO USE ?
+----------------
+
+Velosurf can be used either from a standard java application, or from a
+VelocityTools webapp.
+
+Please refer to docs/download.html and docs/installation.html.
+
+HOW TO BUILD ?
+----------------
+
+First, you'll need to have Apache Ant installed.
+Then, go to the ./build/ directory and run 'ant jar'.
+
+HOW TO TEST ?
+-------------
+
+With ant installed, you can test Velosurf with the 'ant test' command.
+
+Any question or problem ? Feel free to contact us on the mailing list!

Added: velocity/sandbox/velosurf/TODO
URL: http://svn.apache.org/viewvc/velocity/sandbox/velosurf/TODO?rev=1298906&view=auto
==============================================================================
--- velocity/sandbox/velosurf/TODO (added)
+++ velocity/sandbox/velosurf/TODO Fri Mar  9 16:23:25 2012
@@ -0,0 +1,60 @@
+ - Instance.update() should fail if key field is dirty (or make key field read only?)
+ - DBReference.fetch(Object) => fetch(String) to resolve ambiguities
+ - user hooks on attribute names
+ - new scalar attribute types: <boolean>, <int[eger]>, <long>, <float>, <double>, <string>
+ - debug attribute per attribute/action
+ - serialization of processing when connection pool is empty
+ - strict mode that gives errors/warnings for unkown columns
+ - allow aliases for schema names
+ - timed cache
+ - avoid repetitive error messages in logger
+ - review the ToolFinder mechanism
+ - logger: loglevel should stick to one velosurf instance
+ - Instance should maybe reference a DBRef and not a DB (to control subclasses access)
+ - allow customization of LIMIT (like order and refinement)
+ - getMap can work with more than 2 cols (keycol -> instance)
+ - map as an attribute result: "map/id:name", or "map/id:entityname" to have instances as values
+ - foreign keys referencing non-primary keys generate exceptions
+ - authenticator option for case sensivity
+ - add attribute result types: rowset/scalar, map, ...
+ - remember when an instance comes from newInstance (for the cache)
+ - review UserContext life cycle (threads/sessions) - is it thread-pooling resistant? => seems so.
+ - strip ('mangle') tablename/field prefixes on demand (like "tab_")
+ - factorize Action and Attribute!
+ - do sthing about serialization / transience (cf. tomcat sessions persistance for instance)
+ - optionnaly use foreign key names when reverse enginering => should be a database option
+ - display build # in logs at startup
+ - naming collisions detection for aliases
+ - TagCloudTool as an example
+ - Instances should check external POJOs for some additional methods, like "validate"
+ - RowIterator has to be splitted: one core object in sql (with more advanced accessors like InputStreams), one wrapper in context
+ - tool for one-shot messages in the session (like error messages that vanish once displayed)
+ - configLoader should know FATAL error level, even if very unfrequent
+ - review policy when column name clashes with attribute name: maybe add a RowIterator.internalGet called from ReadOnlyMap.
+ - testcase for exported key
+ - when SQL exceptions are thrown from context objects, would it be possible to display line/col position in template?
+ - clarify user context scope and life cycle => very clear for a webapp (equals session)
+ - put version and debugging options in build.properties => 2.3
+ - validation filter: form values should be put as request attributes after the redirect
+ - testcase for aliasing
+ - testcases for POJO mapping
+ - testcase for localization
+ - use DatabaseMetaData.storeXXXCaseIdentifiers() to determine case sensivity
+ - a good dissertation about HTTP authentication to place somewhere http://www.artima.com/weblogs/viewpost.jsp?thread=155252
+ - l10n: provide flags
+ - obfuscation key should be specific to entities
+ - integration with a graphic reporting library
+ - docfix: a drivers.html page about DriverInfo
+ - allow the database connection to be configured via a jndi resource
+ - inheritance of entities in model.xml?
+ - ability to query current schema (ex : under Oracle :  select sys_context('userenv','current_schema') from dual) [done by caching the given schema for now]
+ - add EntityReference.insert(List(columns in natural order))?
+ - SQL enums? is there sthing to do to support them?
+ - id broker? => not really a job for Velosurf?
+ - automatic reload when the configuration file is changed (but depends upon container!) => see feasibility
+ - 'size' attribute on multivalued attributes? (approx JDBC size? exact size?) (workaround: .rows.size)
+ - positionned updates and deletes (via UserContext) => maybe
+ - paging via AbstractSearchTool
+ - database metadata informations and operations
+ - XML databases access via IBM XML Data Mediator?
+ - isolation levels

Added: velocity/sandbox/velosurf/build.properties
URL: http://svn.apache.org/viewvc/velocity/sandbox/velosurf/build.properties?rev=1298906&view=auto
==============================================================================
--- velocity/sandbox/velosurf/build.properties (added)
+++ velocity/sandbox/velosurf/build.properties Fri Mar  9 16:23:25 2012
@@ -0,0 +1,56 @@
+#   Copyright 2003-2004 The Apache Software Foundation
+#
+#   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.
+
+# Velosurf
+project=velosurf
+version=3.0-dev
+final.name=${project}-${version}
+
+# download jars from
+proxy.host=
+proxy.port=80
+repo.url=http://mirrors.ibiblio.org/pub/mirrors/maven2
+
+# versions for downloaded jars - main build
+jar.commons-beanutils.version=1.7.0
+jar.commons-lang.version=2.3
+jar.commons-logging.version=1.1
+jar.commons-net.version=1.4.1
+jar.crimson.version=1.1.3
+jar.jdom.version=1.1.2
+jar.servletapi.version=2.4
+jar.velocity.version=1.7
+jar.velocity-tools.version=2.0
+
+# versions for downloaded jars - tests
+jar.commons-collections.version=3.2
+jar.commons-digester.version=1.8
+jar.hsqldb.version=2.2.8
+jar.httpunit.version=1.6.1
+## TODO jetty has changed its packaging after 6.1
+## (and package org.mortbay.jetty.log disappeared in 6.0.2)
+jar.jetty.version=6.0.1
+jar.js.version=1.6R5
+jar.nekohtml.version=0.9.5
+jar.xercesimpl.version=2.8.1
+jar.xmlparserapis.version=2.6.2
+jar.junit.version=4.3
+
+# jetty parameters
+test.webcontainer.port=8081
+test.webcontainer.control.port=8082
+
+# hsqldb parameters
+test.database.port=9001
+

Added: velocity/sandbox/velosurf/build.xml
URL: http://svn.apache.org/viewvc/velocity/sandbox/velosurf/build.xml?rev=1298906&view=auto
==============================================================================
--- velocity/sandbox/velosurf/build.xml (added)
+++ velocity/sandbox/velosurf/build.xml Fri Mar  9 16:23:25 2012
@@ -0,0 +1,703 @@
+<?xml version="1.0" encoding="iso-8859-1" ?>
+
+<!--
+ Copyright 2000-2006 The Apache Software Foundation.
+
+ 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.
+-->
+
+<project name="velosurf" default="usage" basedir=".">
+  
+  
+  
+  <!-- COMPILATION PARAMETERS -->
+<!--  <property name="build.compiler"          value="jikes"/> -->
+<!--  <property name="build.compiler.emacs"    value="true"/> -->
+
+  <property name="debug" value="on"/>
+
+  <!-- DIRECTORIES -->		
+  <property name="build.dir"         value="${basedir}"/>
+  <property name="src.dir"           value="${basedir}/src/java"/>
+  <property name="output.dir" 	     value="${basedir}/class"/>
+  <property name="lib.dir"           value="${basedir}/lib"/>
+  <property name="test.dir"          value="${basedir}/test"/>
+  <property name="tmp.dir"           value="${basedir}/tmp"/>
+  <property name="docs.dir"           value="${basedir}/docs"/>
+  <property name="javadoc.destdir"   value="${basedir}/docs/api"/>
+  <property name="dist.root"         value="${basedir}/dist"/>
+  <property name="test.src.dir"      value="${test.dir}/src"/>
+  <property name="test.lib.dir"      value="${test.dir}/lib"/>
+  <property name="test.rst.dir"      value="${test.dir}/rst"/>
+  <property name="test.log.dir"      value="${test.dir}/log"/>
+  <property name="test.output.dir"    value="${test.dir}/class"/>
+  <property name="test.webapp.dir"    value="${test.dir}/webapp"/>
+
+  <property name="test.jetty.dir"        value="${test.dir}/jetty"/>
+
+  <!-- BUILD PROPERTIES -->
+  <property file="${build.dir}/build.properties"/>                <!-- Component local   -->
+  <property file="${user.home}/.ant.properties"/>   <!-- User local        -->
+  <property file="${user.home}/build.properties"/>   <!-- User local        -->
+
+  <!-- Build classpath automatically -->
+   <path id="classpath">
+     <fileset dir="./lib">
+       <include name="**/*.jar"/>
+     </fileset>
+   </path>
+
+    <!-- test classpath -->
+    <path id="test.classpath">
+      <path refid="classpath"/>
+      <fileset dir="${test.lib.dir}">
+        <include name="**/*.jar"/>
+      </fileset>
+      <pathelement location="${test.output.dir}"/>
+    </path>
+  
+
+  <!-- PATTERN SETS -->
+  <patternset id="sources" >
+    <include name="org/apache/velocity/velosurf/**/*" />
+  </patternset>
+
+<!-- targets section -->
+
+  <target name="usage" description="- list main ant targets">
+    <echo>
+No target specified.
+Please specify a target among :
+  jar : builds Velosurf jar
+  clean : deletes all intermediary files
+  javadoc : builds Velosurf javadoc
+  tarball : builds Velosurf tgz package
+  test : tests Velosurf
+    </echo>
+  </target>
+
+  <target name="-prepare">
+
+    <!-- MAKE THE DIRECTORIES IF NEEDED -->
+    <mkdir dir="${lib.dir}"/>
+    <mkdir dir="${output.dir}"/>
+    <mkdir dir="${dist.root}/${final.name}" />
+    <delete dir="${tmp.dir}" />
+    <mkdir dir="${tmp.dir}" />
+    <mkdir dir="${test.output.dir}" />
+    <mkdir dir="${test.lib.dir}" />
+    <mkdir dir="${test.log.dir}" />
+    <mkdir dir="${test.log.dir}" />
+    <mkdir dir="${test.jetty.dir}/logs" />
+    <mkdir dir="${test.jetty.dir}/lib" />
+    <mkdir dir="${test.webapp.dir}/WEB-INF/lib"/>
+    <mkdir dir="${test.webapp.dir}/WEB-INF/log"/>
+    <tstamp />
+
+    <!-- CHECK JAVA VERSION -->
+    <echo message="java version: ${ant.java.version}"/>
+    <condition property="java.version.ok">
+      <not>
+        <or>
+          <equals arg1="${ant.java.version}" arg2="1.1"/>
+          <equals arg1="${ant.java.version}" arg2="1.2"/>
+          <equals arg1="${ant.java.version}" arg2="1.3"/>
+          <equals arg1="${ant.java.version}" arg2="1.4"/>
+        </or>
+      </not>
+    </condition>
+    <fail message="Velosurf requires at least Java 1.5" unless="java.version.ok"/>
+
+    <condition property="use.java.1.5">
+      <equals arg1="${ant.java.version}" arg2="1.5"/>
+    </condition>
+    <antcall target="-prepare.java.1.5"/>
+    <condition property="use.java.1.6">
+      <equals arg1="${ant.java.version}" arg2="1.6"/>
+    </condition>
+    <antcall target="-prepare.java.1.6"/>
+    
+    <!-- DOWNLOAD LIBRARIES IF NEEDED -->
+    <antcall target="download" />
+<!-- not downloadable libraries are kept in build.dir/lib -->
+    <copy todir="${lib.dir}">
+      <fileset dir="${build.dir}/lib"/>
+    </copy>
+  </target>
+
+  <target name="-prepare.java.1.5" if="use.java.1.5">
+    <copy file="${src.dir}/org/apache/velocity/velosurf/sql/ConnectionWrapper.java.jdk5" tofile="${src.dir}/org/apache/velocity/velosurf/sql/ConnectionWrapper.java" overwrite="true"/>
+  </target>
+
+  <target name="-prepare.java.1.6" if="use.java.1.6">
+    <copy file="${src.dir}/org/apache/velocity/velosurf/sql/ConnectionWrapper.java.jdk6" tofile="${src.dir}/org/apache/velocity/velosurf/sql/ConnectionWrapper.java" overwrite="true"/>
+  </target>
+
+  <target name="clean" description="- clean all temporary build files">
+    <delete dir="${output.dir}"/>
+    <delete dir="${tmp.dir}"/>
+    <delete dir="${dist.root}"/>
+    <delete dir="${test.output.dir}"/>
+    <delete dir="${test.rst.dir}"/>
+    <delete dir="${test.log.dir}"/>
+    <delete dir="${test.jetty.dir}/logs"/>
+    <delete dir="${test.webapp.dir}/WEB-INF/lib"/>
+    <delete dir="${test.webapp.dir}/WEB-INF/log"/>
+  </target>
+
+  <target name="clean-all" description="- clean all generated build files">
+    <antcall target="clean"/>
+    <delete dir="${lib.dir}"/>
+    <delete dir="${test.lib.dir}"/>
+    <delete dir="${test.jetty.dir}/lib"/>
+    <delete dir="${dist.root}/${final.name}"/>
+  </target>
+  
+  <target name="-download-if-needed" unless="skip.jar.loading">
+    <condition property="jar.present">
+      <and>
+        <isfalse value="${force.jar.loading}"/>
+        <available file="${download.dir}/${download.jar}-${download.version}.jar"/>
+      </and>
+    </condition>
+    <antcall target="-http-download"/>
+  </target>
+
+  <target name="-http-download" unless="jar.present">
+    <property name="download.group" value="${download.jar}"/> <!-- if not set previously -->
+    <setproxy proxyhost="${proxy.host}" proxyport="${proxy.port}"/>
+    <get src="${repo.url}/${download.group}/${download.jar}/${download.version}/${download.jar}-${download.version}.jar"
+         dest="${download.dir}/${download.jar}-${download.version}.jar"
+         usetimestamp="true"
+         verbose="false"
+         ignoreerrors="false" />
+  </target>
+
+  <target name="download" description="- download all dependancy libraries needed for building">
+   <property name="download.dir" value="${lib.dir}"/>
+   <antcall target="-commons-beanutils-download"/>
+   <antcall target="-commons-collections-download"/>
+   <antcall target="-commons-lang-download"/>
+   <antcall target="-commons-net-download"/>
+   <antcall target="-crimson-download"/>
+   <antcall target="-jdom-download"/>
+   <antcall target="-servletapi-download"/>
+   <antcall target="-velocity-download"/>
+   <antcall target="-velocity-tools-download"/>
+  </target>
+
+  <target name="-commons-beanutils-download">
+   <property name="download.jar" value="commons-beanutils" />
+   <property name="download.version" value="${jar.commons-beanutils.version}" />
+   <antcall target="-download-if-needed"/>
+  </target>
+
+  <target name="-commons-digester-download">
+   <property name="download.jar" value="commons-digester" />
+   <property name="download.version" value="${jar.commons-digester.version}" />
+   <antcall target="-download-if-needed"/>
+  </target>
+
+  <target name="-commons-lang-download">
+   <property name="download.jar" value="commons-lang" />
+   <property name="download.version" value="${jar.commons-lang.version}" />
+   <antcall target="-download-if-needed"/>
+  </target>
+
+  <target name="-commons-net-download">
+   <property name="download.jar" value="commons-net" />
+   <property name="download.version" value="${jar.commons-net.version}" />
+   <antcall target="-download-if-needed"/>
+  </target>
+
+  <target name="-commons-collections-download">
+   <property name="download.jar" value="commons-collections" />
+   <property name="download.version" value="${jar.commons-collections.version}" />
+   <antcall target="-download-if-needed"/>
+  </target>
+
+  <target name="-commons-logging-download">
+   <property name="download.jar" value="commons-logging" />
+   <property name="download.version" value="${jar.commons-logging.version}" />
+   <antcall target="-download-if-needed"/>
+  </target>
+
+  <target name="-crimson-download">
+   <property name="download.jar" value="crimson" />
+   <property name="download.version" value="${jar.crimson.version}" />
+   <antcall target="-download-if-needed"/>
+  </target>
+
+  <target name="-dom4j-download">
+   <property name="download.jar" value="dom4j" />
+   <property name="download.version" value="${jar.dom4j.version}" />
+   <antcall target="-download-if-needed"/>
+  </target>
+
+  <target name="-jdom-download">
+   <property name="download.group" value="org/jdom"/>
+   <property name="download.jar" value="jdom" />
+   <property name="download.version" value="${jar.jdom.version}" />
+   <antcall target="-download-if-needed"/>
+  </target>
+
+  <target name="-servletapi-download">
+   <property name="download.jar" value="servletapi" />
+   <property name="download.version" value="${jar.servletapi.version}" />
+   <antcall target="-download-if-needed"/>
+  </target>
+
+  <target name="-velocity-download">
+   <property name="download.group" value="org/apache/velocity"/>
+   <property name="download.jar" value="velocity" />
+   <property name="download.version" value="${jar.velocity.version}" />
+   <antcall target="-download-if-needed"/>
+  </target>
+
+  <target name="-velocity-tools-download">
+   <property name="download.group" value="org/apache/velocity"/>
+   <property name="download.jar" value="velocity-tools"/>
+   <property name="download.version" value="${jar.velocity-tools.version}" />
+   <antcall target="-download-if-needed"/>
+  </target>
+
+  <!-- test downloads --> 
+
+  <target name="test-download" description="- download all dependancy libraries needed for testing">
+   <property name="download.dir" value="${test.lib.dir}"/>
+   <antcall target="-commons-digester-download"/>
+   <antcall target="-hsqldb-download"/>
+   <antcall target="-httpunit-download"/>
+   <antcall target="-js-download"/>
+   <antcall target="-junit-download"/>
+   <antcall target="-nekohtml-download"/>
+   <antcall target="-xerces-download"/>
+   <antcall target="-xmlparserapis-download"/>
+  </target>
+
+  <target name="-jetty-main-download">
+   <property name="download.dir" value="${test.jetty.dir}/lib"/>  
+   <antcall target="-commons-logging-download"/>
+   <antcall target="-jetty-download"/>
+   <antcall target="-jetty-util-download"/>
+   <antcall target="-servlet-api-2.5-download"/>
+   <antcall target="-start-download"/>
+  </target>
+
+  <target name="-hsqldb-download">
+   <property name="download.group" value="org/hsqldb"/>
+   <property name="download.jar" value="hsqldb" />
+   <property name="download.version" value="${jar.hsqldb.version}" />
+   <antcall target="-download-if-needed"/>
+  </target>
+
+  <target name="-httpunit-download">
+   <property name="download.jar" value="httpunit" />
+   <property name="download.version" value="${jar.httpunit.version}" />
+   <antcall target="-download-if-needed"/>
+  </target>
+
+  <target name="-jetty-download">
+   <property name="download.jar" value="jetty" />
+   <property name="download.version" value="${jar.jetty.version}" />
+   <antcall target="-download-if-needed"/>
+  </target>
+
+  <target name="-jetty-util-download">
+   <property name="download.group" value="jetty"/>
+   <property name="download.jar" value="jetty-util" />
+   <property name="download.version" value="${jar.jetty.version}" />
+   <antcall target="-download-if-needed"/>
+  </target>
+
+  <target name="-js-download">
+   <property name="download.group" value="rhino"/>
+   <property name="download.jar" value="js" />
+   <property name="download.version" value="${jar.js.version}" />
+   <antcall target="-download-if-needed"/>
+   <!-- httpunit wants a js.jar -->
+   <copy file="${download.dir}/${download.jar}-${download.version}.jar" tofile="${download.dir}/js.jar"/>
+  </target>
+
+  <target name="-nekohtml-download">
+   <property name="download.jar" value="nekohtml" />
+   <property name="download.version" value="${jar.nekohtml.version}" />
+   <antcall target="-download-if-needed"/>
+  </target>
+
+  <target name="-xerces-download">
+   <property name="download.group" value="xerces" />
+   <property name="download.jar" value="xercesImpl" />
+   <property name="download.version" value="${jar.xercesimpl.version}" />
+   <antcall target="-download-if-needed"/>
+  </target>
+
+  <target name="-xmlparserapis-download">
+   <property name="download.group" value="xerces" />
+   <property name="download.jar" value="xmlParserAPIs" />
+   <property name="download.version" value="${jar.xmlparserapis.version}" />
+   <antcall target="-download-if-needed"/>
+  </target>
+
+  <target name="-servlet-api-2.5-download">
+   <property name="download.group" value="jetty"/>
+   <property name="download.jar" value="servlet-api" />
+   <property name="download.version" value="2.5-${jar.jetty.version}" />
+   <antcall target="-download-if-needed"/>
+  </target>
+
+  <target name="-start-download">
+   <property name="download.group" value="jetty"/>
+   <property name="download.jar" value="start" />
+   <property name="download.version" value="${jar.jetty.version}" />
+   <antcall target="-download-if-needed"/>
+  </target>
+
+  <target name="-junit-download">
+   <property name="download.jar" value="junit" />
+   <property name="download.version" value="${jar.junit.version}" />
+   <antcall target="-download-if-needed"/>
+  </target>
+
+  <target name="jar" depends="-prepare" description="- builds Velosurf jar">
+    <property name="myclasspath" refid="classpath"/>
+    <echo message="using classpath= ${myclasspath}"/>
+    <javac 
+        srcdir="${src.dir}"
+        destdir="${output.dir}"
+        debug="${debug}"
+        debuglevel="lines,vars,source"
+        deprecation="on"
+        optimize="on"
+        encoding="UTF-8"
+        source="1.5"
+        target="1.5"
+        includeantruntime="false">
+	  <patternset refid="sources"/>
+      <classpath refid="classpath"/>
+<!--      <compilerarg value="-Xlint:unchecked"/> -->
+	</javac>
+    <jar jarfile="${basedir}/velosurf-${version}.jar" basedir="${output.dir}" >
+	  <patternset refid="sources"/>
+	</jar>
+  </target>
+
+  <target name="-compile-test" depends="-prepare,jar">
+    <antcall target="test-download"/>
+    <antcall target="-jetty-main-download"/>
+    <copy file="${lib.dir}/commons-collections-${jar.commons-collections.version}.jar" todir="${test.lib.dir}"/>
+    <property name="testclasspath" refid="test.classpath"/>
+    <echo message="using classpath= ${testclasspath}"/>
+    <javac srcdir="${test.src.dir}"
+        destdir="${test.output.dir}"
+        encoding="UTF-8"
+        debug="${debug}"
+        debuglevel="lines,vars,source"
+        deprecation="on"
+        optimize="on"
+        source="1.5"
+        target="1.5">
+      <classpath>
+        <path refid="classpath" />
+        <path refid="test.classpath" />
+        <filelist dir="${basedir}" files="velosurf-${version}.jar"/>
+      </classpath>
+    </javac>
+    <javac srcdir="${test.jetty.dir}/src" destdir="${tmp.dir}" source="1.5" target="1.5">
+      <classpath>
+        <filelist dir="${test.jetty.dir}/lib" files="jetty-${jar.jetty.version}.jar,jetty-util-${jar.jetty.version}.jar"/>
+      </classpath>
+    </javac>
+    <jar jarfile="${test.jetty.dir}/lib/webapplogger.jar" basedir="${tmp.dir}" includes="WebappLogger.class"/>
+  </target>
+
+  <target name="-stop-previous-jetty" if="${jetty-already-running}">
+    <echo>Found a previously running instance of Jetty. Closing it...</echo>
+    <antcall target="stop-jetty"/>
+<!--
+    <waitfor maxwait="2" maxwaitunit="minute" checkevery="500">
+      <not>
+        <http url="http://localhost:${test.webcontainer.port}/"/>
+      </not>
+    </waitfor>
+-->
+  </target>
+
+  <target name="start-jetty" description="- start the Jetty J2EE container">
+    <copy todir="${test.webapp.dir}/WEB-INF/lib">
+      <fileset dir="${lib.dir}"/>
+    </copy>
+    <copy file="${basedir}/velosurf-${version}.jar" todir="${test.webapp.dir}/WEB-INF/lib"/>
+    <copy file="${test.lib.dir}/hsqldb-${jar.hsqldb.version}.jar" todir="${test.webapp.dir}/WEB-INF/lib"/>
+    <copy file="${test.lib.dir}/commons-collections-${jar.commons-collections.version}.jar" todir="${test.webapp.dir}/WEB-INF/lib"/>
+    <copy file="${test.lib.dir}/commons-digester-${jar.commons-digester.version}.jar" todir="${test.webapp.dir}/WEB-INF/lib"/>
+     <condition property="jetty-already-running">
+       <socket server="127.0.0.1" port="${test.webcontainer.control.port}"/>
+     </condition>
+     <antcall target="-stop-previous-jetty"/>
+     <java fork="true" spawn="true" jar="${test.jetty.dir}/lib/start-6.0.1.jar" dir="${test.jetty.dir}">
+       <arg value="etc/jetty.xml"/>
+<!--       <sysproperty key="DEBUG" value="true"/> -->
+       <sysproperty key="jetty.home" value="${test.jetty.dir}"/>
+       <sysproperty key="jetty.port" value="${test.webcontainer.port}"/>
+       <sysproperty key="STOP.PORT" value="${test.webcontainer.control.port}"/>
+       <sysproperty key="STOP.KEY" value="verysecret"/>
+       <sysproperty key="org.mortbay.log.class" value="WebappLogger"/>
+       <sysproperty key="velosurf.test.webapp.log.file" value="${test.webapp.dir}/WEB-INF/log/error.log"/>
+       <sysproperty key="velosurf.test.webapp.log.context" value="/"/>
+       <sysproperty key="velosurf.test.webapp.log.debug" value="${debug}"/>
+       <sysproperty key="velosurf.test.webapp.log.debug" value="on"/>
+     </java>
+    <waitfor maxwait="2" maxwaitunit="minute" checkevery="500">
+      <socket server="127.0.0.1" port="${test.webcontainer.port}"/>
+    </waitfor>
+    <echo message="web server launched successfully."/>
+  </target>
+
+  <target name="stop-jetty" description="- stop the Jetty J2EE container">
+    <java fork="true" jar="${test.jetty.dir}/lib/start-6.0.1.jar" dir="${test.jetty.dir}">
+      <arg value="--stop"/>
+      <sysproperty key="STOP.PORT" value="${test.webcontainer.control.port}"/>
+      <sysproperty key="STOP.KEY" value="verysecret"/>
+    </java>
+  </target>
+
+  <target name="-stop-previous-hsqldb" if="${hsqldb-already-running}">
+    <echo>Found a previously running instance of HSQLDB. Closing it...</echo>
+    <antcall target="stop-hsqldb"/>
+<!--
+    <waitfor maxwait="2" maxwaitunit="minute" checkevery="500">
+      <not>
+        <socket server="127.0.0.1" port="${test.database.port}"/>
+      </not>
+    </waitfor>
+-->
+  </target>
+
+  <target name="start-hsqldb" description="- start the HSQLDB database engine">
+     <condition property="hsqldb-already-running">
+       <socket server="127.0.0.1" port="${test.database.port}"/>
+     </condition>
+     <antcall target="-stop-previous-hsqldb"/>
+    <java fork="true" spawn="true" classname="org.hsqldb.Server">
+      <arg value="-address"/>
+      <arg value="127.0.0.1"/>
+      <arg value="-port"/>
+      <arg value="${test.database.port}"/>
+      <arg value="-database.0"/>
+      <arg value="mem:test"/>
+      <arg value="-dbname.0"/>
+      <arg value="test"/>
+      <classpath>
+        <filelist dir="${test.lib.dir}" files="hsqldb-${jar.hsqldb.version}.jar"/>
+      </classpath>
+    </java>
+    <waitfor maxwait="2" maxwaitunit="minute" checkevery="500">
+      <socket server="127.0.0.1" port="${test.database.port}"/>
+    </waitfor>
+    <echo message="database server launched successfully."/>
+    <sql driver="org.hsqldb.jdbcDriver" 
+         classpath="${test.lib.dir}/hsqldb-${jar.hsqldb.version}.jar"
+         url="jdbc:hsqldb:hsql://127.0.0.1:${test.database.port}/test" 
+         userid="sa" 
+         password=""
+         autocommit="true"
+         src="${test.dir}/sql/initial.sql"/>
+  </target>
+
+  <target name="stop-hsqldb" description="- stop the HSQLDB database engine">
+    <sql driver="org.hsqldb.jdbcDriver" 
+         classpath="${test.lib.dir}/hsqldb-${jar.hsqldb.version}.jar"
+         url="jdbc:hsqldb:hsql://127.0.0.1:${test.database.port}/test" 
+         userid="sa" 
+         password=""
+         autocommit="true">
+      SHUTDOWN;
+    </sql>
+  </target>
+
+  <target name="test" depends="-prepare,-compile-test">
+    <antcall target="start-hsqldb"/>
+    <antcall target="start-jetty"/>
+    <delete dir="${test.rst.dir}"/>
+    <mkdir dir="${test.rst.dir}"/>
+    <junit dir="${test.dir}"
+           fork="true"
+           printSummary="withOutAndErr"
+           haltonerror="false"
+           haltonfailure="false">
+<!--
+<sysproperty key="log4j.configuration"
+                   value="file:///tmp/log4j.properties"/>
+-->
+      <classpath>
+        <path refid="classpath" />
+        <path refid="test.classpath" />
+        <pathelement path="${test.output.dir}"/>
+        <filelist dir="${basedir}" files="velosurf-${version}.jar"/>
+      </classpath>
+
+      <batchtest todir="${test.rst.dir}">
+        <fileset dir="${test.src.dir}" includes="whitebox/**/*"/>
+      </batchtest>
+
+      <batchtest todir="${test.rst.dir}">
+        <fileset dir="${test.src.dir}" includes="blackbox/*"/>
+      </batchtest>
+
+      <formatter type="plain"/>
+    </junit>
+    <antcall target="stop-jetty"/>
+    <antcall target="stop-hsqldb"/>
+  </target>
+
+  <target name="javadoc" depends="-prepare" description="- build javadoc files">
+
+    <property name="javadoc.breakiterator" value="" />	<mkdir dir="${javadoc.destdir}"/>
+    <condition property="javadoc.breakiterator" value="-breakiterator" >
+      <or>
+        <equals arg1="${ant.java.version}" arg2="1.4" />
+        <equals arg1="${ant.java.version}" arg2="1.5" />
+      </or>
+    </condition>
+
+    <property name="javadoc.jdk.href" value="" />
+    <property name="javadoc.jdk.offline" value="false" />
+    <property name="javadoc.jdk.packaglistLoc" value="" />
+    <condition property="javadoc.jdk.href" value="http://java.sun.com/products/jdk/1.2/docs/api/">
+      <equals arg1="${ant.java.version}" arg2="1.2" />
+    </condition>
+    <condition property="javadoc.jdk.href" value="http://java.sun.com/j2se/1.3/docs/api/">
+      <equals arg1="${ant.java.version}" arg2="1.3" />
+    </condition>
+    <condition property="javadoc.jdk.href" value="http://java.sun.com/j2se/1.4/docs/api/">
+      <equals arg1="${ant.zojava.version}" arg2="1.4" />
+    </condition>
+    <condition property="javadoc.jdk.href" value="http://java.sun.com/j2se/1.5/docs/api/">
+      <equals arg1="${ant.java.version}" arg2="1.5" />
+    </condition>
+	
+    <javadoc
+      sourcepath="${src.dir}"
+      packagenames="velosurf.*"
+      destdir="${javadoc.destdir}"
+      author="true"
+      private="true"
+      version="true"
+      use="true"
+	  additionalparam="${javadoc.breakiterator}"
+      windowtitle="${project} ${version} API"
+      doctitle="${project} ${version} API">
+      <link offline="${javadoc.jdk.offline}" href="${javadoc.jdk.href}" packagelistLoc="${javadoc.jdk.packagelistLoc}" />
+      <bottom><![CDATA[<div align='center'>~ooOoo~</div>]]></bottom>
+      <classpath refid="classpath"/> 
+	</javadoc>
+  </target>
+
+  <target name="tarball" depends="javadoc,jar" description="- build distribution archive">
+
+    <antcall target="clean"/>
+
+    <mkdir dir="${dist.root}/${final.name}"/>
+    <mkdir dir="${dist.root}/${final.name}/src"/>
+    <mkdir dir="${dist.root}/${final.name}/docs"/>
+    <mkdir dir="${dist.root}/${final.name}/examples"/>
+    <mkdir dir="${dist.root}/${final.name}/test"/>
+    <mkdir dir="${dist.root}/${final.name}/test/jetty"/>
+    <mkdir dir="${dist.root}/${final.name}/test/webapp"/>
+    <mkdir dir="${dist.root}/${final.name}/test/webapp/WEB-INF"/>
+
+    <copy todir="${dist.root}/${final.name}/src">
+      <fileset dir="${basedir}/src">
+        <include name="**/*"/>
+      </fileset>
+    </copy>
+
+    <copy todir="${dist.root}/${final.name}/docs">
+      <fileset dir="${docs.dir}">
+        <include name="**"/>
+      </fileset>
+    </copy> 
+
+    <copy todir="${dist.root}/${final.name}">
+      <fileset dir="${basedir}">
+        <include name="CHANGELOG"/>
+        <include name="LICENSE"/>
+        <include name="NOTICE"/>
+        <include name="README"/>
+        <include name="TODO"/>
+        <include name="build.xml"/>
+        <include name="build.properties"/>
+      </fileset>
+    </copy>
+    
+    <copy todir="${dist.root}/${final.name}/test">
+      <fileset dir="${test.dir}">
+        <include name="conf/*"/>
+        <include name="hsqlclient.sh"/>
+        <include name="hsqldb.sh"/>
+        <include name="sql/*"/>
+        <include name="src/**"/>
+      </fileset>
+    </copy>
+
+    <copy todir="${dist.root}/${final.name}/test/webapp">
+      <fileset dir="${test.webapp.dir}">
+        <include name="*.html.vtl"/>
+        <include name="*.html"/>
+        <include name="*.js"/>
+        <include name="auth/**"/>
+        <include name="localized/**"/>
+      </fileset>
+    </copy>
+
+    <copy todir="${dist.root}/${final.name}/test/jetty">
+      <fileset dir="${test.jetty.dir}">
+        <include name="etc/*"/>
+        <include name="src/*"/>
+        <include name="jetty.sh"/>
+      </fileset>
+    </copy>
+
+    <copy todir="${dist.root}/${final.name}/test/webapp/WEB-INF">
+      <fileset dir="${test.webapp.dir}/WEB-INF">
+        <include name="*.xml"/>
+        <include name="*.properties"/>
+      </fileset>
+    </copy>
+    
+    <copy todir="${dist.root}/${final.name}/examples">
+      <fileset dir="${basedir}/examples/">
+        <include name="*.*"/>
+      </fileset>
+    </copy>
+
+    <copy file="${basedir}/${final.name}.jar" tofile="${dist.root}/${final.name}/${final.name}.jar"/>
+
+    <delete file="${basedir}/${final.name}.tar" quiet="true"/>
+    <delete file="${basedir}/${final.name}.tgz" quiet="true"/>
+    <tar tarfile="${basedir}/${final.name}.tar" basedir="${dist.root}" 
+         includes="**/${final.name}/**" longfile="gnu"/>
+    <gzip zipfile="${basedir}/${final.name}.tgz" src="${basedir}/${final.name}.tar"/>
+    <delete file="${basedir}/${final.name}.tar" quiet="true"/>
+  </target>
+
+  <target name="dependencies" depends="download" description="- builds an archive of all dependancy libraries">
+    <delete file="${basedir}/${final.name}-dependencies.tar" quiet="true"/>
+    <delete file="${basedir}/${final.name}-dependencies.tgz" quiet="true"/>
+    <tar tarfile="${basedir}/${final.name}-dependencies.tar" basedir="${basedir}" includes="lib/*.jar" longfile="gnu"/>
+    <gzip zipfile="${basedir}/${final.name}-dependencies.tgz" src="${basedir}/${final.name}-dependencies.tar"/>
+    <delete file="${basedir}/${final.name}-dependencies.tar" quiet="true"/>
+  </target>
+
+</project>



Mime
View raw message