|
From: <be...@us...> - 2006-08-23 12:15:05
|
Revision: 35 Author: benoitx Date: 2006-08-23 05:14:53 -0700 (Wed, 23 Aug 2006) ViewCVS: http://svn.sourceforge.net/objectlabkit/?rev=35&view=rev Log Message: ----------- moved package from net.objectlab to net.objectlab.kit all dependencies need to be updated. Modified Paths: -------------- trunk/common-build/project.xml trunk/datecalc-jdk/project.xml trunk/datecalc-joda/project.xml Modified: trunk/common-build/project.xml =================================================================== --- trunk/common-build/project.xml 2006-08-23 11:02:06 UTC (rev 34) +++ trunk/common-build/project.xml 2006-08-23 12:14:53 UTC (rev 35) @@ -11,7 +11,7 @@ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/3.0.0 http://maven.apache.org/maven-v3_0_0.xsd"> <pomVersion>3</pomVersion> - <groupId>net.objectlab</groupId> + <groupId>net.objectlab.kit</groupId> <currentVersion>1.0</currentVersion> <organization> <name>ObjectLab Financial Ltd</name> Modified: trunk/datecalc-jdk/project.xml =================================================================== --- trunk/datecalc-jdk/project.xml 2006-08-23 11:02:06 UTC (rev 34) +++ trunk/datecalc-jdk/project.xml 2006-08-23 12:14:53 UTC (rev 35) @@ -21,7 +21,7 @@ </repository> <dependencies> <dependency> - <groupId>net.objectlab</groupId> + <groupId>net.objectlab.kit</groupId> <artifactId>datecalc-common</artifactId> <version>${pom.currentVersion}</version> <type>jar</type> Modified: trunk/datecalc-joda/project.xml =================================================================== --- trunk/datecalc-joda/project.xml 2006-08-23 11:02:06 UTC (rev 34) +++ trunk/datecalc-joda/project.xml 2006-08-23 12:14:53 UTC (rev 35) @@ -21,7 +21,7 @@ </repository> <dependencies> <dependency> - <groupId>net.objectlab</groupId> + <groupId>net.objectlab.kit</groupId> <artifactId>datecalc-common</artifactId> <version>${pom.currentVersion}</version> <type>jar</type> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
|
From: <be...@us...> - 2006-08-23 22:23:44
|
Revision: 43 Author: benoitx Date: 2006-08-23 15:23:12 -0700 (Wed, 23 Aug 2006) ViewCVS: http://svn.sourceforge.net/objectlabkit/?rev=43&view=rev Log Message: ----------- new stats Modified Paths: -------------- trunk/datecalc-common/qalab.xml trunk/datecalc-jdk/qalab.xml trunk/datecalc-joda/qalab.xml Modified: trunk/datecalc-common/qalab.xml =================================================================== --- trunk/datecalc-common/qalab.xml 2006-08-23 22:05:50 UTC (rev 42) +++ trunk/datecalc-common/qalab.xml 2006-08-23 22:23:12 UTC (rev 43) @@ -34,9 +34,9 @@ <summaryresult date="2006-08-20" filecount="7" statvalue="1" type="checkstyle"/> <summaryresult date="2006-08-20" filecount="6" statvalue="90" type="cobertura-line"/> <summaryresult date="2006-08-20" filecount="6" statvalue="100" type="cobertura-branch"/> - <summaryresult date="2006-08-23" filecount="9" statvalue="24" type="checkstyle"/> - <summaryresult date="2006-08-23" filecount="8" statvalue="75" type="cobertura-line"/> - <summaryresult date="2006-08-23" filecount="8" statvalue="91" type="cobertura-branch"/> + <summaryresult date="2006-08-23" filecount="10" statvalue="25" type="checkstyle"/> + <summaryresult date="2006-08-23" filecount="9" statvalue="74" type="cobertura-line"/> + <summaryresult date="2006-08-23" filecount="9" statvalue="87" type="cobertura-branch"/> </summary> <file id="net_objectlab_kit_datecalc_common_package.html" path="net/objectlab/kit/datecalc/common/package.html"> <result date="2006-08-08" statvalue="1" type="checkstyle"/> @@ -124,12 +124,17 @@ </file> <file id="net_objectlab_kit_datecalc_common_AbstractDateCalculator.java" path="net/objectlab/kit/datecalc/common/AbstractDateCalculator.java"> - <result date="2006-08-23" statvalue="4" type="checkstyle"/> + <result date="2006-08-23" statvalue="5" type="checkstyle"/> </file> <file - id="net_objectlab_kit_datecalc_common_DateCalculatorGeneric.java" path="net/objectlab/kit/datecalc/common/DateCalculatorGeneric.java"> + id="net_objectlab_kit_datecalc_common_DateCalculatorGeneric.java" path="net/objectlab/kit/datecalc/common/DateCalculatorGeneric.java"/> + <file id="net_objectlab_kit_datecalc_common_DateCalculator.java" path="net/objectlab/kit/datecalc/common/DateCalculator.java"> <result date="2006-08-23" statvalue="19" type="checkstyle"/> <result date="2006-08-23" statvalue="100" type="cobertura-line"/> <result date="2006-08-23" statvalue="100" type="cobertura-branch"/> </file> + <file id="net_objectlab_kit_datecalc_common_HolidayHandler.java" path="net/objectlab/kit/datecalc/common/HolidayHandler.java"> + <result date="2006-08-23" statvalue="100" type="cobertura-line"/> + <result date="2006-08-23" statvalue="100" type="cobertura-branch"/> + </file> </qalab> Modified: trunk/datecalc-jdk/qalab.xml =================================================================== --- trunk/datecalc-jdk/qalab.xml 2006-08-23 22:05:50 UTC (rev 42) +++ trunk/datecalc-jdk/qalab.xml 2006-08-23 22:23:12 UTC (rev 43) @@ -31,11 +31,10 @@ <summaryresult date="2006-08-20" filecount="1" statvalue="1" type="findbugs"/> <summaryresult date="2006-08-20" filecount="9" statvalue="77" type="cobertura-line"/> <summaryresult date="2006-08-20" filecount="9" statvalue="77" type="cobertura-branch"/> - <summaryresult date="2006-08-23" filecount="10" statvalue="8" type="checkstyle"/> + <summaryresult date="2006-08-23" filecount="8" statvalue="8" type="checkstyle"/> <summaryresult date="2006-08-23" filecount="1" statvalue="1" type="pmd"/> - <summaryresult date="2006-08-23" filecount="1" statvalue="1" type="findbugs"/> - <summaryresult date="2006-08-23" filecount="9" statvalue="82" type="cobertura-line"/> - <summaryresult date="2006-08-23" filecount="9" statvalue="80" type="cobertura-branch"/> + <summaryresult date="2006-08-23" filecount="7" statvalue="81" type="cobertura-line"/> + <summaryresult date="2006-08-23" filecount="7" statvalue="79" type="cobertura-branch"/> </summary> <file id="net_objectlab_kit_datecalc_jdk_package.html" path="net/objectlab/kit/datecalc/jdk/package.html"> <result date="2006-08-08" statvalue="1" type="checkstyle"/> @@ -61,9 +60,8 @@ <result date="2006-08-20" statvalue="75" type="cobertura-branch"/> <result date="2006-08-23" statvalue="5" type="checkstyle"/> <result date="2006-08-23" statvalue="1" type="pmd"/> - <result date="2006-08-23" statvalue="1" type="findbugs"/> - <result date="2006-08-23" statvalue="79" type="cobertura-line"/> - <result date="2006-08-23" statvalue="77" type="cobertura-branch"/> + <result date="2006-08-23" statvalue="78" type="cobertura-line"/> + <result date="2006-08-23" statvalue="76" type="cobertura-branch"/> </file> <file id="net_objectlab_kit_datecalc_jdk_DefaultDateCalculatorFactory.java" path="net/objectlab/kit/datecalc/jdk/DefaultDateCalculatorFactory.java"> @@ -92,8 +90,6 @@ <result date="2006-08-10" statvalue="100" type="cobertura-branch"/> <result date="2006-08-20" statvalue="100" type="cobertura-line"/> <result date="2006-08-20" statvalue="100" type="cobertura-branch"/> - <result date="2006-08-23" statvalue="100" type="cobertura-line"/> - <result date="2006-08-23" statvalue="100" type="cobertura-branch"/> </file> <file id="net_objectlab_kit_datecalc_jdk_DateCalculatorFactory.java" path="net/objectlab/kit/datecalc/jdk/DateCalculatorFactory.java"> <result date="2006-08-08" statvalue="100" type="cobertura-line"/> @@ -116,8 +112,6 @@ <result date="2006-08-10" statvalue="100" type="cobertura-branch"/> <result date="2006-08-20" statvalue="100" type="cobertura-line"/> <result date="2006-08-20" statvalue="100" type="cobertura-branch"/> - <result date="2006-08-23" statvalue="100" type="cobertura-line"/> - <result date="2006-08-23" statvalue="100" type="cobertura-branch"/> </file> <file id="net_objectlab_kit_datecalc_jdk_PeriodCountCalculator.java" path="net/objectlab/kit/datecalc/jdk/PeriodCountCalculator.java"> <result date="2006-08-08" statvalue="100" type="cobertura-line"/> Modified: trunk/datecalc-joda/qalab.xml =================================================================== --- trunk/datecalc-joda/qalab.xml 2006-08-23 22:05:50 UTC (rev 42) +++ trunk/datecalc-joda/qalab.xml 2006-08-23 22:23:12 UTC (rev 43) @@ -40,9 +40,9 @@ <summaryresult date="2006-08-20" filecount="1" statvalue="1" type="pmd"/> <summaryresult date="2006-08-20" filecount="12" statvalue="86" type="cobertura-line"/> <summaryresult date="2006-08-20" filecount="12" statvalue="88" type="cobertura-branch"/> - <summaryresult date="2006-08-23" filecount="13" statvalue="1" type="checkstyle"/> - <summaryresult date="2006-08-23" filecount="12" statvalue="93" type="cobertura-line"/> - <summaryresult date="2006-08-23" filecount="12" statvalue="95" type="cobertura-branch"/> + <summaryresult date="2006-08-23" filecount="11" statvalue="1" type="checkstyle"/> + <summaryresult date="2006-08-23" filecount="10" statvalue="93" type="cobertura-line"/> + <summaryresult date="2006-08-23" filecount="10" statvalue="95" type="cobertura-branch"/> </summary> <file id="net_objectlab_kit_datecalc_joda_package.html" path="net/objectlab/kit/datecalc/joda/package.html"> <result date="2006-08-08" statvalue="1" type="checkstyle"/> @@ -152,8 +152,6 @@ <result date="2006-08-19" statvalue="100" type="cobertura-branch"/> <result date="2006-08-20" statvalue="100" type="cobertura-line"/> <result date="2006-08-20" statvalue="100" type="cobertura-branch"/> - <result date="2006-08-23" statvalue="100" type="cobertura-line"/> - <result date="2006-08-23" statvalue="100" type="cobertura-branch"/> </file> <file id="net_objectlab_kit_datecalc_joda_DateCalculatorFactory.java" path="net/objectlab/kit/datecalc/joda/DateCalculatorFactory.java"> @@ -195,8 +193,6 @@ <result date="2006-08-19" statvalue="100" type="cobertura-branch"/> <result date="2006-08-20" statvalue="100" type="cobertura-line"/> <result date="2006-08-20" statvalue="100" type="cobertura-branch"/> - <result date="2006-08-23" statvalue="100" type="cobertura-line"/> - <result date="2006-08-23" statvalue="100" type="cobertura-branch"/> </file> <file id="net_objectlab_kit_datecalc_joda_PeriodCountCalculator.java" path="net/objectlab/kit/datecalc/joda/PeriodCountCalculator.java"> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
|
From: <be...@us...> - 2006-08-24 13:48:44
|
Revision: 46 Author: benoitx Date: 2006-08-24 06:48:39 -0700 (Thu, 24 Aug 2006) ViewCVS: http://svn.sourceforge.net/objectlabkit/?rev=46&view=rev Log Message: ----------- tidy up. Modified Paths: -------------- trunk/datecalc-jdk/maven.xml trunk/datecalc-jdk/pom.xml trunk/datecalc-jdk/project.xml Modified: trunk/datecalc-jdk/maven.xml =================================================================== --- trunk/datecalc-jdk/maven.xml 2006-08-24 13:48:14 UTC (rev 45) +++ trunk/datecalc-jdk/maven.xml 2006-08-24 13:48:39 UTC (rev 46) @@ -1,30 +1,27 @@ <?xml version="1.0"?> -<!-- -/* - * ======================================================================== - * - * - * ======================================================================== - */ ---> +<!-- + /* + * ======================================================================== + * ObjectLab Financial Ltd, proud sponsor of The Kit. + * ======================================================================== + */ +--> + +<project xmlns:j="jelly:core" xmlns:ant="jelly:ant" + xmlns:artifact="artifact" + xmlns:maven="jelly:org.apache.maven.jelly.tags.project.MavenTagLibrary"> -<project xmlns:j="jelly:core" xmlns:ant="jelly:ant" xmlns:artifact="artifact" xmlns:maven="jelly:org.apache.maven.jelly.tags.project.MavenTagLibrary"> - - <goal name="kit:rebuild" prereqs="kit:build" /> + <goal name="kit:rebuild" prereqs="clean,kit:build" /> - <goal name="kit:build" prereqs="jar:jar"> - <echo>ADD Common to full JAR</echo> - <ant:jar - basedir="./target/classes" - jarfile="${maven.build.dir}/${pom.artifactId}-full${pom.currentVersion}.jar" - update="yes" - > - <fileset dir="${basedir}/../datecalc-common/target/classes" - excludes="**/Test.class" - includes="**/*.class" - /> - </ant:jar> - - </goal> + <goal name="kit:build" prereqs="jar:jar"> + <echo>ADD Common to full JAR</echo> + <ant:jar basedir="target/classes" + jarfile="${maven.build.dir}/${pom.artifactId}-full-${pom.currentVersion}.jar" + update="yes"> + <fileset dir="${basedir}/../datecalc-common/target/classes" + excludes="**/Test.class" includes="**/*.class" /> + </ant:jar> + + </goal> </project> Modified: trunk/datecalc-jdk/pom.xml =================================================================== --- trunk/datecalc-jdk/pom.xml 2006-08-24 13:48:14 UTC (rev 45) +++ trunk/datecalc-jdk/pom.xml 2006-08-24 13:48:39 UTC (rev 46) @@ -1,45 +1,51 @@ <?xml version="1.0" encoding="UTF-8"?> -<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"> +<!-- + /* + * ======================================================================== + * ObjectLab Financial Ltd, proud sponsor of The Kit. + * ======================================================================== + */ +--> +<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> - <parent> - <groupId>net.objectlab.kit</groupId> - <artifactId>datecalc</artifactId> - <version>1.0-SNAPSHOT</version> - </parent> + <modelVersion>4.0.0</modelVersion> + <parent> + <groupId>net.objectlab.kit</groupId> + <artifactId>datecalc</artifactId> + <version>1.0-SNAPSHOT</version> + </parent> - <artifactId>datecalc-jdk</artifactId> - <packaging>jar</packaging> - <name>Date Calculator for JDK</name> - <description> - Date Calculator methods for JDK - </description> + <artifactId>datecalc-jdk</artifactId> + <packaging>jar</packaging> + <name>Date Calculator for JDK</name> + <description>Date Calculator methods for JDK</description> - <reporting> - <plugins> - <plugin> - <groupId>org.codehaus.mojo</groupId> - <artifactId>jdepend-maven-plugin</artifactId> - </plugin> - </plugins> - </reporting> + <reporting> + <plugins> + <plugin> + <groupId>org.codehaus.mojo</groupId> + <artifactId>jdepend-maven-plugin</artifactId> + </plugin> + </plugins> + </reporting> - <dependencies> - <dependency> - <groupId>net.objectlab.kit</groupId> - <artifactId>datecalc-common</artifactId> - <version>${pom.version}</version> - </dependency> + <dependencies> + <dependency> + <groupId>net.objectlab.kit</groupId> + <artifactId>datecalc-common</artifactId> + <version>${pom.version}</version> + </dependency> - <!-- TODO test cases should use log4j transparently --> - <dependency> - <groupId>log4j</groupId> - <artifactId>log4j</artifactId> - <scope>test</scope> - </dependency> + <!-- TODO test cases should use log4j transparently --> + <dependency> + <groupId>log4j</groupId> + <artifactId>log4j</artifactId> + <scope>test</scope> + </dependency> - </dependencies> + </dependencies> </project> \ No newline at end of file Modified: trunk/datecalc-jdk/project.xml =================================================================== --- trunk/datecalc-jdk/project.xml 2006-08-24 13:48:14 UTC (rev 45) +++ trunk/datecalc-jdk/project.xml 2006-08-24 13:48:39 UTC (rev 46) @@ -1,94 +1,66 @@ <?xml version="1.0"?> <!-- - /* - * ======================================================================== - * - * ======================================================================== - */ + /* + * ======================================================================== + * ObjectLab Financial Ltd, proud sponsor of The Kit. + * ======================================================================== + */ --> <project> - <extend>../common-build/project.xml</extend> - <name>DateCalc JDK</name> - <artifactId>datecalc-jdk</artifactId> - <package>net.objectlab.kit</package> - <shortDescription>DateCalc JDK library</shortDescription> - <description>This library provides pure JDK implementation of the Date Calculator.</description> - <repository> - <connection>scm:svn:https://svn.sourceforge.net/svnroot/objectlabkit/trunk/datecalc-jdk</connection> - <developerConnection>scm:svn:https://svn.sourceforge.net/svnroot/objectlabkit/trunk/datecalc-jdk</developerConnection> - </repository> - <dependencies> - <dependency> - <groupId>net.objectlab.kit</groupId> - <artifactId>datecalc-common</artifactId> - <version>${pom.currentVersion}</version> - <type>jar</type> - </dependency> - </dependencies> + <extend>../common-build/project.xml</extend> + <name>DateCalc JDK</name> + <artifactId>datecalc-jdk</artifactId> + <package>net.objectlab.kit</package> + <shortDescription>DateCalc JDK library</shortDescription> + <description> + This library provides pure JDK implementation of the Date + Calculator. + </description> + <repository> + <connection> + scm:svn:https://svn.sourceforge.net/svnroot/objectlabkit/trunk/datecalc-jdk + </connection> + <developerConnection> + scm:svn:https://svn.sourceforge.net/svnroot/objectlabkit/trunk/datecalc-jdk + </developerConnection> + </repository> + <dependencies> + <dependency> + <groupId>net.objectlab.kit</groupId> + <artifactId>datecalc-common</artifactId> + <version>${pom.currentVersion}</version> + <type>jar</type> + </dependency> + </dependencies> - <reports> - <report>maven-checkstyle-plugin</report> - <report>maven-findbugs-plugin</report> - <report>maven-pmd-plugin</report> - <report>maven-simian-plugin</report> - <report>maven-cobertura-plugin</report> - <report>maven-qalab-plugin</report> - <report>maven-ydoc-plugin</report> - <report>maven-jdepend-plugin</report> - <report>maven-faq-plugin</report> - <report>maven-junit-report-plugin</report> - <report>maven-jxr-plugin</report> - <report>maven-tasklist-plugin</report> - </reports> + <reports> + <report>maven-checkstyle-plugin</report> + <report>maven-findbugs-plugin</report> + <report>maven-pmd-plugin</report> + <report>maven-simian-plugin</report> + <report>maven-cobertura-plugin</report> + <report>maven-qalab-plugin</report> + <report>maven-ydoc-plugin</report> + <report>maven-jdepend-plugin</report> + <report>maven-faq-plugin</report> + <report>maven-junit-report-plugin</report> + <report>maven-jxr-plugin</report> + <report>maven-tasklist-plugin</report> + </reports> - <build> - <sourceDirectory>src/main/java</sourceDirectory> - <unitTestSourceDirectory>src/test/java</unitTestSourceDirectory> - <!-- TODO: to be removed as it is not generic --> - <nagEmailAddress>bx...@ob...</nagEmailAddress> - <unitTest> - <includes> - <include>**/*Test.java</include> - </includes> - <excludes> - <exclude>**/Abstract*.java</exclude> - </excludes> -<!-- <resources> - <resource> - <directory>src/test/conf</directory> - <includes> - <include>*.properties</include> - <include>**/*.xml</include> - </includes> - </resource> - </resources> - --> - </unitTest> -<!-- <resources> - <resource> - <directory>src/conf</directory> - <includes> - <include>*.properties</include> - <include>**/*.xml</include> - <include>*.template</include> - </includes> - </resource> - <resource> - <directory>src/har</directory> - <includes> - <include>**/*.xml</include> - </includes> - </resource> - <resource> - <directory>../common/target</directory> - <includes> - <include>safemargin-common-${pom.currentVersion}.jar</include> - </includes> - </resource> - </resources> - --> - </build> + <build> + <sourceDirectory>src/main/java</sourceDirectory> + <unitTestSourceDirectory>src/test/java</unitTestSourceDirectory> + <unitTest> + <includes> + <include>**/*Test.java</include> + </includes> + <excludes> + <exclude>**/Abstract*.java</exclude> + </excludes> + </unitTest> + </build> </project> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
|
From: <be...@us...> - 2006-08-24 22:18:09
|
Revision: 51 Author: benoitx Date: 2006-08-24 15:17:05 -0700 (Thu, 24 Aug 2006) ViewCVS: http://svn.sourceforge.net/objectlabkit/?rev=51&view=rev Log Message: ----------- Removed Checkstyle issues. new stats. Modified Paths: -------------- trunk/datecalc-common/qalab.xml trunk/datecalc-common/src/main/java/net/objectlab/kit/datecalc/common/AbstractDateCalculator.java trunk/datecalc-common/src/main/java/net/objectlab/kit/datecalc/common/DateCalculator.java trunk/datecalc-common/src/main/java/net/objectlab/kit/datecalc/common/WorkingWeek.java trunk/datecalc-jdk/qalab.xml trunk/datecalc-jdk/src/main/java/net/objectlab/kit/datecalc/jdk/BaseDateCalculator.java trunk/datecalc-jdk/src/main/java/net/objectlab/kit/datecalc/jdk/ForwardHandler.java trunk/datecalc-jdk/src/test/java/net/objectlab/kit/datecalc/jdk/DateCalculatorCombinationTest.java trunk/datecalc-jdk/src/test/java/net/objectlab/kit/datecalc/jdk/DateCalculatorFactoryTest.java trunk/datecalc-jdk/src/test/java/net/objectlab/kit/datecalc/jdk/ForwardDateCalculatorTest.java trunk/datecalc-jdk/src/test/java/net/objectlab/kit/datecalc/jdk/JodaWorkingWeekTest.java trunk/datecalc-jdk/src/test/java/net/objectlab/kit/datecalc/jdk/PeriodCountCalculatorTest.java trunk/datecalc-joda/qalab.xml trunk/datecalc-joda/src/main/java/net/objectlab/kit/datecalc/joda/BackwardHandler.java trunk/datecalc-joda/src/main/java/net/objectlab/kit/datecalc/joda/BaseDateCalculator.java trunk/datecalc-joda/src/main/java/net/objectlab/kit/datecalc/joda/ForwardHandler.java trunk/datecalc-joda/src/main/java/net/objectlab/kit/datecalc/joda/ModifiedFollowingHandler.java trunk/datecalc-joda/src/main/java/net/objectlab/kit/datecalc/joda/ModifiedPreceedingHandler.java trunk/datecalc-joda/src/test/java/net/objectlab/kit/datecalc/joda/BackwardDateCalculatorTest.java trunk/datecalc-joda/src/test/java/net/objectlab/kit/datecalc/joda/DateCalculatorCombinationTest.java trunk/datecalc-joda/src/test/java/net/objectlab/kit/datecalc/joda/DateCalculatorFactoryTest.java trunk/datecalc-joda/src/test/java/net/objectlab/kit/datecalc/joda/ForwardDateCalculatorTest.java trunk/datecalc-joda/src/test/java/net/objectlab/kit/datecalc/joda/IMMDateTest.java trunk/datecalc-joda/src/test/java/net/objectlab/kit/datecalc/joda/ModifiedFollowingDateCalculatorTest.java trunk/datecalc-joda/src/test/java/net/objectlab/kit/datecalc/joda/ModifiedPreceedingDateCalculatorTest.java Modified: trunk/datecalc-common/qalab.xml =================================================================== --- trunk/datecalc-common/qalab.xml 2006-08-24 21:37:58 UTC (rev 50) +++ trunk/datecalc-common/qalab.xml 2006-08-24 22:17:05 UTC (rev 51) @@ -37,6 +37,9 @@ <summaryresult date="2006-08-23" filecount="10" statvalue="25" type="checkstyle"/> <summaryresult date="2006-08-23" filecount="9" statvalue="74" type="cobertura-line"/> <summaryresult date="2006-08-23" filecount="9" statvalue="87" type="cobertura-branch"/> + <summaryresult date="2006-08-24" filecount="10" statvalue="1" type="checkstyle"/> + <summaryresult date="2006-08-24" filecount="9" statvalue="62" type="cobertura-line"/> + <summaryresult date="2006-08-24" filecount="9" statvalue="65" type="cobertura-branch"/> </summary> <file id="net_objectlab_kit_datecalc_common_package.html" path="net/objectlab/kit/datecalc/common/package.html"> <result date="2006-08-08" statvalue="1" type="checkstyle"/> @@ -45,6 +48,7 @@ <result date="2006-08-19" statvalue="1" type="checkstyle"/> <result date="2006-08-20" statvalue="1" type="checkstyle"/> <result date="2006-08-23" statvalue="1" type="checkstyle"/> + <result date="2006-08-24" statvalue="1" type="checkstyle"/> </file> <file id="net_objectlab_kit_datecalc_common_Tenor.java" path="net/objectlab/kit/datecalc/common/Tenor.java"> <result date="2006-08-08" statvalue="1" type="checkstyle"/> @@ -62,6 +66,8 @@ <result date="2006-08-20" statvalue="100" type="cobertura-branch"/> <result date="2006-08-23" statvalue="100" type="cobertura-line"/> <result date="2006-08-23" statvalue="100" type="cobertura-branch"/> + <result date="2006-08-24" statvalue="100" type="cobertura-line"/> + <result date="2006-08-24" statvalue="100" type="cobertura-branch"/> </file> <file id="net_objectlab_kit_datecalc_common_WorkingWeek.java" path="net/objectlab/kit/datecalc/common/WorkingWeek.java"> <result date="2006-08-08" statvalue="3" type="checkstyle"/> @@ -80,6 +86,8 @@ <result date="2006-08-20" statvalue="100" type="cobertura-branch"/> <result date="2006-08-23" statvalue="100" type="cobertura-line"/> <result date="2006-08-23" statvalue="100" type="cobertura-branch"/> + <result date="2006-08-24" statvalue="100" type="cobertura-line"/> + <result date="2006-08-24" statvalue="100" type="cobertura-branch"/> </file> <file id="net_objectlab_kit_datecalc_common_TenorCode.java" path="net/objectlab/kit/datecalc/common/TenorCode.java"> <result date="2006-08-08" statvalue="100" type="cobertura-line"/> @@ -94,6 +102,8 @@ <result date="2006-08-20" statvalue="100" type="cobertura-branch"/> <result date="2006-08-23" statvalue="100" type="cobertura-line"/> <result date="2006-08-23" statvalue="100" type="cobertura-branch"/> + <result date="2006-08-24" statvalue="100" type="cobertura-line"/> + <result date="2006-08-24" statvalue="100" type="cobertura-branch"/> </file> <file id="net_objectlab_kit_datecalc_common_HolidayHandlerType.java" path="net/objectlab/kit/datecalc/common/HolidayHandlerType.java"> <result date="2006-08-08" statvalue="100" type="cobertura-branch"/> @@ -102,12 +112,14 @@ <result date="2006-08-19" statvalue="100" type="cobertura-branch"/> <result date="2006-08-20" statvalue="100" type="cobertura-branch"/> <result date="2006-08-23" statvalue="100" type="cobertura-branch"/> + <result date="2006-08-24" statvalue="100" type="cobertura-branch"/> </file> <file id="net_objectlab_kit_datecalc_common_PeriodCountBasis.java" path="net/objectlab/kit/datecalc/common/PeriodCountBasis.java"> <result date="2006-08-08" statvalue="100" type="cobertura-branch"/> <result date="2006-08-10" statvalue="100" type="cobertura-branch"/> <result date="2006-08-20" statvalue="100" type="cobertura-branch"/> <result date="2006-08-23" statvalue="100" type="cobertura-branch"/> + <result date="2006-08-24" statvalue="100" type="cobertura-branch"/> </file> <file id="net_objectlab_kit_datecalc_common_StandardTenor.java" path="net/objectlab/kit/datecalc/common/StandardTenor.java"> <result date="2006-08-08" statvalue="100" type="cobertura-branch"/> @@ -121,6 +133,8 @@ <result date="2006-08-20" statvalue="100" type="cobertura-branch"/> <result date="2006-08-23" statvalue="92" type="cobertura-line"/> <result date="2006-08-23" statvalue="100" type="cobertura-branch"/> + <result date="2006-08-24" statvalue="92" type="cobertura-line"/> + <result date="2006-08-24" statvalue="100" type="cobertura-branch"/> </file> <file id="net_objectlab_kit_datecalc_common_AbstractDateCalculator.java" path="net/objectlab/kit/datecalc/common/AbstractDateCalculator.java"> @@ -132,9 +146,13 @@ <result date="2006-08-23" statvalue="19" type="checkstyle"/> <result date="2006-08-23" statvalue="100" type="cobertura-line"/> <result date="2006-08-23" statvalue="100" type="cobertura-branch"/> + <result date="2006-08-24" statvalue="100" type="cobertura-line"/> + <result date="2006-08-24" statvalue="100" type="cobertura-branch"/> </file> <file id="net_objectlab_kit_datecalc_common_HolidayHandler.java" path="net/objectlab/kit/datecalc/common/HolidayHandler.java"> <result date="2006-08-23" statvalue="100" type="cobertura-line"/> <result date="2006-08-23" statvalue="100" type="cobertura-branch"/> + <result date="2006-08-24" statvalue="100" type="cobertura-line"/> + <result date="2006-08-24" statvalue="100" type="cobertura-branch"/> </file> </qalab> Modified: trunk/datecalc-common/src/main/java/net/objectlab/kit/datecalc/common/AbstractDateCalculator.java =================================================================== --- trunk/datecalc-common/src/main/java/net/objectlab/kit/datecalc/common/AbstractDateCalculator.java 2006-08-24 21:37:58 UTC (rev 50) +++ trunk/datecalc-common/src/main/java/net/objectlab/kit/datecalc/common/AbstractDateCalculator.java 2006-08-24 22:17:05 UTC (rev 51) @@ -14,13 +14,13 @@ private String name; - protected E startDate; + private E startDate; - protected E currentDate; + private E currentBusinessDate; - protected Set<E> nonWorkingDays; + private Set<E> nonWorkingDays; - protected HolidayHandler<E> holidayHandler; + private HolidayHandler<E> holidayHandler; protected AbstractDateCalculator(final String name, final Set<E> nonWorkingDays, final HolidayHandler<E> holidayHandler) { this.name = name; @@ -46,8 +46,8 @@ setCurrentBusinessDate(startDate); } - public E getCurrentDate() { - return currentDate; + public E getCurrentBusinessDate() { + return currentBusinessDate; } public Set<E> getNonWorkingDays() { @@ -106,15 +106,15 @@ } public boolean isCurrentDateNonWorking() { - return isNonWorkingDay(currentDate); + return isNonWorkingDay(currentBusinessDate); } public E setCurrentBusinessDate(final E date) { - currentDate = date; + currentBusinessDate = date; if (holidayHandler != null && date != null) { - currentDate = holidayHandler.moveCurrentDate(this); + currentBusinessDate = holidayHandler.moveCurrentDate(this); } - return currentDate; + return currentBusinessDate; } protected HolidayHandler<E> getHolidayHandler() { @@ -134,7 +134,7 @@ /** * Allows DateCalculators to be combined into a new one, the startDate and - * currentDate will be the ones from the existing calendar (not the + * currentBusinessDate will be the ones from the existing calendar (not the * parameter one). The name will be combined name1+"/"+calendar.getName(). * * @param calendar, @@ -172,17 +172,18 @@ * @return the next IMMDate based on current date. */ public E getNextIMMDate() { - return getNextIMMDate(true, currentDate); + return getNextIMMDate(true, currentBusinessDate); } /** * @return the previous IMMDate based on current date. */ public E getPreviousIMMDate() { - return getNextIMMDate(false, currentDate); + return getNextIMMDate(false, currentBusinessDate); } - protected abstract E getNextIMMDate(final boolean forward, final E startDate); + protected abstract E getNextIMMDate(final boolean forward, final E theStartDate); - protected abstract DateCalculator<E> createNewCalcultaor(String name, E startDate, Set<E> holidays, HolidayHandler<E> handler); + protected abstract DateCalculator<E> createNewCalcultaor(String calcName, E theStartDate, Set<E> holidays, + HolidayHandler<E> handler); } Modified: trunk/datecalc-common/src/main/java/net/objectlab/kit/datecalc/common/DateCalculator.java =================================================================== --- trunk/datecalc-common/src/main/java/net/objectlab/kit/datecalc/common/DateCalculator.java 2006-08-24 21:37:58 UTC (rev 50) +++ trunk/datecalc-common/src/main/java/net/objectlab/kit/datecalc/common/DateCalculator.java 2006-08-24 22:17:05 UTC (rev 51) @@ -28,7 +28,7 @@ * @param currentDate * held by the calendar. */ - E getCurrentDate(); + E getCurrentBusinessDate(); /** * is the given date on a weekend, according to the WorkingWeek Modified: trunk/datecalc-common/src/main/java/net/objectlab/kit/datecalc/common/WorkingWeek.java =================================================================== --- trunk/datecalc-common/src/main/java/net/objectlab/kit/datecalc/common/WorkingWeek.java 2006-08-24 21:37:58 UTC (rev 50) +++ trunk/datecalc-common/src/main/java/net/objectlab/kit/datecalc/common/WorkingWeek.java 2006-08-24 22:17:05 UTC (rev 51) @@ -39,11 +39,10 @@ private static final byte SUNDAY = 64; - private static final byte DEFAULT_WORKING_DAYS = (byte) (MONDAY + TUESDAY - + WEDNESDAY + THURSDAY + FRIDAY); + private static final byte DEFAULT_WORKING_DAYS = (byte) (MONDAY + TUESDAY + WEDNESDAY + THURSDAY + FRIDAY); - private static final byte[] WORKING_WEEK_DAYS_OFFSET = new byte[] { SUNDAY, - MONDAY, TUESDAY, WEDNESDAY, THURSDAY, FRIDAY, SATURDAY }; + private static final byte[] WORKING_WEEK_DAYS_OFFSET = new byte[] { SUNDAY, MONDAY, TUESDAY, WEDNESDAY, THURSDAY, FRIDAY, + SATURDAY }; public static final WorkingWeek DEFAULT = new WorkingWeek(); @@ -51,7 +50,7 @@ * Default Working Week Monday -> Friday. */ public WorkingWeek() { - this((byte) DEFAULT_WORKING_DAYS); + this(DEFAULT_WORKING_DAYS); } private WorkingWeek(final byte workingDays) { Modified: trunk/datecalc-jdk/qalab.xml =================================================================== --- trunk/datecalc-jdk/qalab.xml 2006-08-24 21:37:58 UTC (rev 50) +++ trunk/datecalc-jdk/qalab.xml 2006-08-24 22:17:05 UTC (rev 51) @@ -35,6 +35,10 @@ <summaryresult date="2006-08-23" filecount="1" statvalue="1" type="pmd"/> <summaryresult date="2006-08-23" filecount="7" statvalue="81" type="cobertura-line"/> <summaryresult date="2006-08-23" filecount="7" statvalue="79" type="cobertura-branch"/> + <summaryresult date="2006-08-24" filecount="8" statvalue="6" type="checkstyle"/> + <summaryresult date="2006-08-24" filecount="1" statvalue="1" type="pmd"/> + <summaryresult date="2006-08-24" filecount="7" statvalue="86" type="cobertura-line"/> + <summaryresult date="2006-08-24" filecount="7" statvalue="81" type="cobertura-branch"/> </summary> <file id="net_objectlab_kit_datecalc_jdk_package.html" path="net/objectlab/kit/datecalc/jdk/package.html"> <result date="2006-08-08" statvalue="1" type="checkstyle"/> @@ -42,6 +46,7 @@ <result date="2006-08-10" statvalue="1" type="checkstyle"/> <result date="2006-08-20" statvalue="1" type="checkstyle"/> <result date="2006-08-23" statvalue="1" type="checkstyle"/> + <result date="2006-08-24" statvalue="1" type="checkstyle"/> </file> <file id="net_objectlab_kit_datecalc_jdk_BaseDateCalculator.java" path="net/objectlab/kit/datecalc/jdk/BaseDateCalculator.java"> <result date="2006-08-08" statvalue="1" type="checkstyle"/> @@ -62,6 +67,10 @@ <result date="2006-08-23" statvalue="1" type="pmd"/> <result date="2006-08-23" statvalue="78" type="cobertura-line"/> <result date="2006-08-23" statvalue="76" type="cobertura-branch"/> + <result date="2006-08-24" statvalue="3" type="checkstyle"/> + <result date="2006-08-24" statvalue="1" type="pmd"/> + <result date="2006-08-24" statvalue="84" type="cobertura-line"/> + <result date="2006-08-24" statvalue="76" type="cobertura-branch"/> </file> <file id="net_objectlab_kit_datecalc_jdk_DefaultDateCalculatorFactory.java" path="net/objectlab/kit/datecalc/jdk/DefaultDateCalculatorFactory.java"> @@ -74,6 +83,9 @@ <result date="2006-08-23" statvalue="1" type="checkstyle"/> <result date="2006-08-23" statvalue="100" type="cobertura-line"/> <result date="2006-08-23" statvalue="100" type="cobertura-branch"/> + <result date="2006-08-24" statvalue="1" type="checkstyle"/> + <result date="2006-08-24" statvalue="100" type="cobertura-line"/> + <result date="2006-08-24" statvalue="100" type="cobertura-branch"/> </file> <file id="C:_project_objectlab-kit_datecalc-jdk_src_test_java_net_objectlab_kit_datecalc_jdk_DateCalculatorCombinationTest.java" path="C:/project/objectlab-kit/datecalc-jdk/src/test/java/net/objectlab/kit/datecalc/jdk/DateCalculatorCombinationTest.java"> @@ -102,6 +114,8 @@ <result date="2006-08-20" statvalue="100" type="cobertura-branch"/> <result date="2006-08-23" statvalue="100" type="cobertura-line"/> <result date="2006-08-23" statvalue="100" type="cobertura-branch"/> + <result date="2006-08-24" statvalue="100" type="cobertura-line"/> + <result date="2006-08-24" statvalue="100" type="cobertura-branch"/> </file> <file id="net_objectlab_kit_datecalc_jdk_HolidayHandler.java" path="net/objectlab/kit/datecalc/jdk/HolidayHandler.java"> <result date="2006-08-08" statvalue="100" type="cobertura-line"/> @@ -124,6 +138,8 @@ <result date="2006-08-20" statvalue="100" type="cobertura-branch"/> <result date="2006-08-23" statvalue="100" type="cobertura-line"/> <result date="2006-08-23" statvalue="100" type="cobertura-branch"/> + <result date="2006-08-24" statvalue="100" type="cobertura-line"/> + <result date="2006-08-24" statvalue="100" type="cobertura-branch"/> </file> <file id="net_objectlab_kit_datecalc_jdk_DefaultPeriodCountCalculator.java" path="net/objectlab/kit/datecalc/jdk/DefaultPeriodCountCalculator.java"> @@ -134,6 +150,8 @@ <result date="2006-08-20" statvalue="100" type="cobertura-branch"/> <result date="2006-08-23" statvalue="50" type="cobertura-line"/> <result date="2006-08-23" statvalue="100" type="cobertura-branch"/> + <result date="2006-08-24" statvalue="50" type="cobertura-line"/> + <result date="2006-08-24" statvalue="100" type="cobertura-branch"/> </file> <file id="C:_project_objectlabkit_datecalc-jdk_src_test_java_net_objectlab_kit_datecalc_jdk_DateCalculatorCombinationTest.java" path="C:/project/objectlabkit/datecalc-jdk/src/test/java/net/objectlab/kit/datecalc/jdk/DateCalculatorCombinationTest.java"/> @@ -144,11 +162,16 @@ <result date="2006-08-23" statvalue="1" type="checkstyle"/> <result date="2006-08-23" statvalue="75" type="cobertura-line"/> <result date="2006-08-23" statvalue="100" type="cobertura-branch"/> + <result date="2006-08-24" statvalue="1" type="checkstyle"/> + <result date="2006-08-24" statvalue="75" type="cobertura-line"/> + <result date="2006-08-24" statvalue="100" type="cobertura-branch"/> </file> <file id="net_objectlab_kit_datecalc_jdk_ForwardHandler.java" path="net/objectlab/kit/datecalc/jdk/ForwardHandler.java"> <result date="2006-08-20" statvalue="100" type="cobertura-line"/> <result date="2006-08-20" statvalue="100" type="cobertura-branch"/> <result date="2006-08-23" statvalue="100" type="cobertura-line"/> <result date="2006-08-23" statvalue="100" type="cobertura-branch"/> + <result date="2006-08-24" statvalue="100" type="cobertura-line"/> + <result date="2006-08-24" statvalue="100" type="cobertura-branch"/> </file> </qalab> Modified: trunk/datecalc-jdk/src/main/java/net/objectlab/kit/datecalc/jdk/BaseDateCalculator.java =================================================================== --- trunk/datecalc-jdk/src/main/java/net/objectlab/kit/datecalc/jdk/BaseDateCalculator.java 2006-08-24 21:37:58 UTC (rev 50) +++ trunk/datecalc-jdk/src/main/java/net/objectlab/kit/datecalc/jdk/BaseDateCalculator.java 2006-08-24 22:17:05 UTC (rev 51) @@ -35,7 +35,7 @@ * @author Benoit Xhenseval */ public class BaseDateCalculator extends AbstractDateCalculator<Date> { - + private WorkingWeek workingWeek = WorkingWeek.DEFAULT; @SuppressWarnings("unchecked") @@ -62,32 +62,31 @@ } public DateCalculator<Date> moveByDays(final int days) { - if (currentDate == null) { + if (getCurrentBusinessDate() == null) { initialise(); } - - final Calendar cal = Utils.getCal(currentDate); + + final Calendar cal = Utils.getCal(getCurrentBusinessDate()); cal.add(Calendar.DAY_OF_MONTH, days); setCurrentBusinessDate(cal.getTime()); - + return this; } private void initialise() { - if (startDate == null) { + if (getStartDate() == null) { setStartDate(new Date()); - } else if (currentDate == null) { + } else if (getCurrentBusinessDate() == null) { setCurrentBusinessDate(new Date()); } } @Override - protected DateCalculator<Date> createNewCalcultaor(final String name, final Date startDate, final Set<Date> holidays, + protected DateCalculator<Date> createNewCalcultaor(final String name, final Date startDate, final Set<Date> holidays, final HolidayHandler<Date> handler) { return new BaseDateCalculator(name, startDate, holidays, handler); } - - + /** * Calculates IMMDates between a start and end dates the 3rd wednesday of * Mar/Jun/Sep/Dec when a lot of derivative contracts expire @@ -95,7 +94,7 @@ * @return a List of Dates */ public List<Date> getIMMDates(final Date start, final Date end) { - + final List<Date> dates = new ArrayList<Date>(); Date date = start; while (true) { @@ -106,39 +105,37 @@ break; } } - - return dates; + + return dates; } @Override protected Date getNextIMMDate(final boolean forward, final Date startDate) { - + final Calendar cal = Utils.getCal(startDate); if (isIMMMonth(cal)) { moveToIMMDay(cal); // TODO simplify this if condition - if ((forward && cal.getTime().after(startDate)) || - (!forward && cal.getTime().before(startDate))) { + if ((forward && cal.getTime().after(startDate)) || (!forward && cal.getTime().before(startDate))) { return cal.getTime(); } } - + final int delta = (forward ? 1 : -1); do { cal.add(Calendar.MONTH, delta); } while (!isIMMMonth(cal)); - + moveToIMMDay(cal); return cal.getTime(); } private boolean isIMMMonth(final Calendar cal) { final int month = cal.get(Calendar.MONTH); - return (month == Calendar.MARCH || month == Calendar.JUNE || - month == Calendar.SEPTEMBER || month == Calendar.DECEMBER); + return (month == Calendar.MARCH || month == Calendar.JUNE || month == Calendar.SEPTEMBER || month == Calendar.DECEMBER); } - + /** * Assumes that the month is correct, get the day for the 3rd wednesday. * @@ -147,7 +144,7 @@ */ private void moveToIMMDay(final Calendar cal) { cal.set(Calendar.DAY_OF_MONTH, 1); - + // go to 1st wed final int dayOfWeek = cal.get(Calendar.DAY_OF_WEEK); if (dayOfWeek < Calendar.WEDNESDAY) { @@ -157,7 +154,7 @@ } else { cal.add(Calendar.DAY_OF_MONTH, (Calendar.WEDNESDAY + 7) - dayOfWeek); } - + // go to 3rd wednesday - i.e. move 2 weeks forward cal.add(Calendar.DAY_OF_MONTH, 7 * 2); } Modified: trunk/datecalc-jdk/src/main/java/net/objectlab/kit/datecalc/jdk/ForwardHandler.java =================================================================== --- trunk/datecalc-jdk/src/main/java/net/objectlab/kit/datecalc/jdk/ForwardHandler.java 2006-08-24 21:37:58 UTC (rev 50) +++ trunk/datecalc-jdk/src/main/java/net/objectlab/kit/datecalc/jdk/ForwardHandler.java 2006-08-24 22:17:05 UTC (rev 51) @@ -31,7 +31,7 @@ public Date moveCurrentDate(final DateCalculator<Date> calendar) { - final Calendar cal = Utils.getCal(calendar.getCurrentDate()); + final Calendar cal = Utils.getCal(calendar.getCurrentBusinessDate()); while (calendar.isNonWorkingDay(cal.getTime())) { cal.add(Calendar.DAY_OF_MONTH, 1); Modified: trunk/datecalc-jdk/src/test/java/net/objectlab/kit/datecalc/jdk/DateCalculatorCombinationTest.java =================================================================== --- trunk/datecalc-jdk/src/test/java/net/objectlab/kit/datecalc/jdk/DateCalculatorCombinationTest.java 2006-08-24 21:37:58 UTC (rev 50) +++ trunk/datecalc-jdk/src/test/java/net/objectlab/kit/datecalc/jdk/DateCalculatorCombinationTest.java 2006-08-24 22:17:05 UTC (rev 51) @@ -3,7 +3,6 @@ import java.util.Date; import junit.framework.Assert; - import net.objectlab.kit.datecalc.common.DateCalculator; import net.objectlab.kit.datecalc.common.HolidayHandlerType; @@ -62,7 +61,7 @@ Assert.assertEquals("Combo name", "bla/UK", combo.getName()); Assert.assertEquals("Combo type", HolidayHandlerType.FORWARD, combo.getHolidayHandlerType()); Assert.assertEquals("start", Date, combo.getStartDate()); - Assert.assertEquals("currentDate", Date, combo.getCurrentDate()); + Assert.assertEquals("currentDate", Date, combo.getCurrentBusinessDate()); Assert.assertEquals("Holidays", 4, combo.getNonWorkingDays().size()); } @@ -80,7 +79,7 @@ Assert.assertEquals("Combo name", "UK/UK", combo.getName()); Assert.assertEquals("Combo type", HolidayHandlerType.FORWARD, combo.getHolidayHandlerType()); Assert.assertEquals("start", Date, combo.getStartDate()); - Assert.assertEquals("currentDate", Date, combo.getCurrentDate()); + Assert.assertEquals("currentDate", Date, combo.getCurrentBusinessDate()); Assert.assertEquals("Holidays", 4, combo.getNonWorkingDays().size()); } @@ -98,7 +97,7 @@ Assert.assertEquals("Combo name", "US/UK", combo.getName()); Assert.assertEquals("Combo type", HolidayHandlerType.FORWARD, combo.getHolidayHandlerType()); Assert.assertEquals("start", Date, combo.getStartDate()); - Assert.assertEquals("currentDate", Date, combo.getCurrentDate()); + Assert.assertEquals("currentDate", Date, combo.getCurrentBusinessDate()); Assert.assertEquals("Holidays", 6, combo.getNonWorkingDays().size()); } @@ -114,7 +113,7 @@ Assert.assertEquals("Combo name", "US", combo.getName()); Assert.assertEquals("Combo type", HolidayHandlerType.FORWARD, combo.getHolidayHandlerType()); Assert.assertEquals("start", Date, combo.getStartDate()); - Assert.assertEquals("currentDate", Date, combo.getCurrentDate()); + Assert.assertEquals("currentDate", Date, combo.getCurrentBusinessDate()); Assert.assertEquals("Holidays", 3, combo.getNonWorkingDays().size()); } @@ -130,7 +129,7 @@ Assert.assertEquals("Combo name", "US", combo.getName()); Assert.assertEquals("Combo type", HolidayHandlerType.FORWARD, combo.getHolidayHandlerType()); Assert.assertEquals("start", Date, combo.getStartDate()); - Assert.assertEquals("currentDate", Date, combo.getCurrentDate()); + Assert.assertEquals("currentDate", Date, combo.getCurrentBusinessDate()); Assert.assertEquals("Holidays", 3, combo.getNonWorkingDays().size()); } } Modified: trunk/datecalc-jdk/src/test/java/net/objectlab/kit/datecalc/jdk/DateCalculatorFactoryTest.java =================================================================== --- trunk/datecalc-jdk/src/test/java/net/objectlab/kit/datecalc/jdk/DateCalculatorFactoryTest.java 2006-08-24 21:37:58 UTC (rev 50) +++ trunk/datecalc-jdk/src/test/java/net/objectlab/kit/datecalc/jdk/DateCalculatorFactoryTest.java 2006-08-24 22:17:05 UTC (rev 51) @@ -4,7 +4,6 @@ import java.util.Set; import junit.framework.Assert; - import net.objectlab.kit.datecalc.common.DateCalculator; import net.objectlab.kit.datecalc.common.HolidayHandlerType; Modified: trunk/datecalc-jdk/src/test/java/net/objectlab/kit/datecalc/jdk/ForwardDateCalculatorTest.java =================================================================== --- trunk/datecalc-jdk/src/test/java/net/objectlab/kit/datecalc/jdk/ForwardDateCalculatorTest.java 2006-08-24 21:37:58 UTC (rev 50) +++ trunk/datecalc-jdk/src/test/java/net/objectlab/kit/datecalc/jdk/ForwardDateCalculatorTest.java 2006-08-24 22:17:05 UTC (rev 51) @@ -1,12 +1,11 @@ package net.objectlab.kit.datecalc.jdk; import java.util.Calendar; -import java.util.HashSet; import java.util.Date; +import java.util.HashSet; import java.util.Set; import junit.framework.Assert; - import net.objectlab.kit.datecalc.common.DateCalculator; import net.objectlab.kit.datecalc.common.HolidayHandlerType; import net.objectlab.kit.datecalc.common.WorkingWeek; @@ -199,6 +198,6 @@ } private void checkDate(final String string, final DateCalculator calendar, final String string2) { - Assert.assertEquals(string, createDate(string2), calendar.getCurrentDate()); + Assert.assertEquals(string, createDate(string2), calendar.getCurrentBusinessDate()); } } Modified: trunk/datecalc-jdk/src/test/java/net/objectlab/kit/datecalc/jdk/JodaWorkingWeekTest.java =================================================================== --- trunk/datecalc-jdk/src/test/java/net/objectlab/kit/datecalc/jdk/JodaWorkingWeekTest.java 2006-08-24 21:37:58 UTC (rev 50) +++ trunk/datecalc-jdk/src/test/java/net/objectlab/kit/datecalc/jdk/JodaWorkingWeekTest.java 2006-08-24 22:17:05 UTC (rev 51) @@ -17,10 +17,9 @@ import java.util.Calendar; -import net.objectlab.kit.datecalc.common.WorkingWeek; - import junit.framework.Assert; import junit.framework.TestCase; +import net.objectlab.kit.datecalc.common.WorkingWeek; /** * @author Benoit Xhenseval Modified: trunk/datecalc-jdk/src/test/java/net/objectlab/kit/datecalc/jdk/PeriodCountCalculatorTest.java =====================================... [truncated message content] |
|
From: <ma...@us...> - 2006-08-26 09:08:45
|
Revision: 60 Author: marchy Date: 2006-08-26 02:08:30 -0700 (Sat, 26 Aug 2006) ViewCVS: http://svn.sourceforge.net/objectlabkit/?rev=60&view=rev Log Message: ----------- Added the Apache 2.0 licence to the project code template Added Paths: ----------- trunk/datecalc-common/.settings/ trunk/datecalc-common/.settings/org.eclipse.jdt.ui.prefs trunk/datecalc-jdk/.settings/ trunk/datecalc-jdk/.settings/org.eclipse.jdt.ui.prefs Added: trunk/datecalc-common/.settings/org.eclipse.jdt.ui.prefs =================================================================== --- trunk/datecalc-common/.settings/org.eclipse.jdt.ui.prefs (rev 0) +++ trunk/datecalc-common/.settings/org.eclipse.jdt.ui.prefs 2006-08-26 09:08:30 UTC (rev 60) @@ -0,0 +1,3 @@ +#Sat Aug 26 10:57:38 CAT 2006 +eclipse.preferences.version=1 +org.eclipse.jdt.ui.text.custom_code_templates=<?xml version\="1.0" encoding\="UTF-8"?><templates><template autoinsert\="true" context\="gettercomment_context" deleted\="false" description\="Comment for getter method" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.gettercomment" name\="gettercomment">/**\r\n * @return Returns the ${bare_field_name}.\r\n */</template><template autoinsert\="true" context\="settercomment_context" deleted\="false" description\="Comment for setter method" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.settercomment" name\="settercomment">/**\r\n * @param ${param} The ${bare_field_name} to set.\r\n */</template><template autoinsert\="true" context\="constructorcomment_context" deleted\="false" description\="Comment for created constructors" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.constructorcomment" name\="constructorcomment">/**\r\n * ${tags}\r\n */</template><template autoinsert\="false" context\="filecomment_context" deleted\="false" description\="Comment for created Java files" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.filecomment" name\="filecomment">/*\r\n * $$Id$$\r\n * \r\n * Copyright 2006 the original author or authors.\r\n *\r\n * Licensed under the Apache License, Version 2.0 (the "License"); you may not\r\n * use this file except in compliance with the License. You may obtain a copy of\r\n * the License at\r\n *\r\n * http\://www.apache.org/licenses/LICENSE-2.0\r\n *\r\n * Unless required by applicable law or agreed to in writing, software\r\n * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT\r\n * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the\r\n * License for the specific language governing permissions and limitations under\r\n * the License.\r\n */</template><template autoinsert\="false" context\="typecomment_context" deleted\="false" description\="Comment for created types" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.typecomment" name\="typecomment">/**\r\n *\r\n * @author Marcin Jekot\r\n * @author $$LastChangedBy$$\r\n * @version $$Revision$$ $$Date$$\r\n *\r\n * ${tags}\r\n */</template><template autoinsert\="true" context\="fieldcomment_context" deleted\="false" description\="Comment for fields" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.fieldcomment" name\="fieldcomment">/**\r\n * \r\n */</template><template autoinsert\="true" context\="methodcomment_context" deleted\="false" description\="Comment for non-overriding methods" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.methodcomment" name\="methodcomment">/**\r\n * ${tags}\r\n */</template><template autoinsert\="true" context\="overridecomment_context" deleted\="false" description\="Comment for overriding methods" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.overridecomment" name\="overridecomment">/* (non-Javadoc)\r\n * ${see_to_overridden}\r\n */</template><template autoinsert\="true" context\="newtype_context" deleted\="false" description\="Newly created files" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.newtype" name\="newtype">${filecomment}\r\n${package_declaration}\r\n\r\n${typecomment}\r\n${type_declaration}</template><template autoinsert\="true" context\="catchblock_context" deleted\="false" description\="Code in new catch blocks" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.catchblock" name\="catchblock">// ${todo} Auto-generated catch block\r\n${exception_var}.printStackTrace();</template><template autoinsert\="true" context\="methodbody_context" deleted\="false" description\="Code in created method stubs" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.methodbody" name\="methodbody">// ${todo} Auto-generated method stub\r\n${body_statement}</template><template autoinsert\="true" context\="constructorbody_context" deleted\="false" description\="Code in created constructor stubs" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.constructorbody" name\="constructorbody">${body_statement}\r\n// ${todo} Auto-generated constructor stub</template><template autoinsert\="true" context\="getterbody_context" deleted\="false" description\="Code in created getters" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.getterbody" name\="getterbody">return ${field};</template><template autoinsert\="true" context\="setterbody_context" deleted\="false" description\="Code in created setters" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.setterbody" name\="setterbody">${field} \= ${param};</template></templates> Added: trunk/datecalc-jdk/.settings/org.eclipse.jdt.ui.prefs =================================================================== --- trunk/datecalc-jdk/.settings/org.eclipse.jdt.ui.prefs (rev 0) +++ trunk/datecalc-jdk/.settings/org.eclipse.jdt.ui.prefs 2006-08-26 09:08:30 UTC (rev 60) @@ -0,0 +1,3 @@ +#Sat Aug 26 10:58:00 CAT 2006 +eclipse.preferences.version=1 +org.eclipse.jdt.ui.text.custom_code_templates=<?xml version\="1.0" encoding\="UTF-8"?><templates><template autoinsert\="true" context\="gettercomment_context" deleted\="false" description\="Comment for getter method" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.gettercomment" name\="gettercomment">/**\r\n * @return Returns the ${bare_field_name}.\r\n */</template><template autoinsert\="true" context\="settercomment_context" deleted\="false" description\="Comment for setter method" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.settercomment" name\="settercomment">/**\r\n * @param ${param} The ${bare_field_name} to set.\r\n */</template><template autoinsert\="true" context\="constructorcomment_context" deleted\="false" description\="Comment for created constructors" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.constructorcomment" name\="constructorcomment">/**\r\n * ${tags}\r\n */</template><template autoinsert\="false" context\="filecomment_context" deleted\="false" description\="Comment for created Java files" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.filecomment" name\="filecomment">/*\r\n * $$Id$$\r\n * \r\n * Copyright 2006 the original author or authors.\r\n *\r\n * Licensed under the Apache License, Version 2.0 (the "License"); you may not\r\n * use this file except in compliance with the License. You may obtain a copy of\r\n * the License at\r\n *\r\n * http\://www.apache.org/licenses/LICENSE-2.0\r\n *\r\n * Unless required by applicable law or agreed to in writing, software\r\n * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT\r\n * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the\r\n * License for the specific language governing permissions and limitations under\r\n * the License.\r\n */</template><template autoinsert\="false" context\="typecomment_context" deleted\="false" description\="Comment for created types" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.typecomment" name\="typecomment">/**\r\n *\r\n * @author Marcin Jekot\r\n * @author $$LastChangedBy$$\r\n * @version $$Revision$$ $$Date$$\r\n *\r\n * ${tags}\r\n */</template><template autoinsert\="true" context\="fieldcomment_context" deleted\="false" description\="Comment for fields" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.fieldcomment" name\="fieldcomment">/**\r\n * \r\n */</template><template autoinsert\="true" context\="methodcomment_context" deleted\="false" description\="Comment for non-overriding methods" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.methodcomment" name\="methodcomment">/**\r\n * ${tags}\r\n */</template><template autoinsert\="true" context\="overridecomment_context" deleted\="false" description\="Comment for overriding methods" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.overridecomment" name\="overridecomment">/* (non-Javadoc)\r\n * ${see_to_overridden}\r\n */</template><template autoinsert\="true" context\="newtype_context" deleted\="false" description\="Newly created files" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.newtype" name\="newtype">${filecomment}\r\n${package_declaration}\r\n\r\n${typecomment}\r\n${type_declaration}</template><template autoinsert\="true" context\="catchblock_context" deleted\="false" description\="Code in new catch blocks" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.catchblock" name\="catchblock">// ${todo} Auto-generated catch block\r\n${exception_var}.printStackTrace();</template><template autoinsert\="true" context\="methodbody_context" deleted\="false" description\="Code in created method stubs" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.methodbody" name\="methodbody">// ${todo} Auto-generated method stub\r\n${body_statement}</template><template autoinsert\="true" context\="constructorbody_context" deleted\="false" description\="Code in created constructor stubs" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.constructorbody" name\="constructorbody">${body_statement}\r\n// ${todo} Auto-generated constructor stub</template><template autoinsert\="true" context\="getterbody_context" deleted\="false" description\="Code in created getters" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.getterbody" name\="getterbody">return ${field};</template><template autoinsert\="true" context\="setterbody_context" deleted\="false" description\="Code in created setters" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.setterbody" name\="setterbody">${field} \= ${param};</template></templates> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |