portals-jetspeed-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From wea...@apache.org
Subject cvs commit: jakarta-jetspeed-2/cornerstone-demo/registry/implementation/org.apache.cornerstone.framework.demo.bo.api.IY y3.reg.properties
Date Tue, 02 Dec 2003 17:46:53 GMT
weaver      2003/12/02 09:46:53

  Added:       cornerstone-demo/hsqldb/data test.properties select.sql
                        test.script insert.sql drop.sql create.sql
                        query.bat
               cornerstone-demo/registry/implementation/cornerstone.service
                        cornerstone.demo.getDate3.reg.properties
                        cornerstone.demo.getDate102.reg.properties
                        cornerstone.demo.getDate103.reg.properties
                        cornerstone.demo.getDate101.reg.properties
                        cornerstone.demo.getDate.reg.properties
                        cornerstone.demo.getDate2.reg.properties
                        cornerstone.demo.getDate1x1.reg.properties
               cornerstone-demo/src/java/org/apache/cornerstone/framework/demo/bo/api
                        IUser.java IB.java IGroup.java IX.java IY.java
                        IA.java
               cornerstone-demo RUNNING.txt project.properties
                        log4j.properties maven.xml project.xml
               cornerstone-demo/registry/implementation/org.apache.cornerstone.framework.demo.bo.api.IA
                        a1b2.reg.properties a1_viaParentName.reg.properties
                        a1_viaFactoryClassName.reg.properties
                        a1_viaInstanceClassName.reg.properties
                        a1b1.reg.properties
               cornerstone-demo/src/java/org/apache/cornerstone/framework/demo/bo
                        B1.java BaseUser.java BaseGroup.java A1.java
                        X1.java Y3.java Y1.java Y2.java B2.java
               cornerstone-demo/registry/implementation/org.apache.cornerstone.framework.demo.bo.api.IB
                        b1.reg.properties b2.reg.properties
               cornerstone-demo/src/java/org/apache/cornerstone/framework/demo/service
                        DateServiceFactory.java
                        DateServiceFactory.properties DateService.java
               cornerstone-demo/src/java/org/apache/cornerstone/framework/demo/bo/factory/api
                        IAFactory.java IXFactory.java
               cornerstone-demo/src/resources/org/apache/cornerstone/framework/demo/bo/factory
                        AFactory.properties
               cornerstone-demo/registry/implementation/org.apache.cornerstone.framework.demo.bo.factory.api.IXFactory
                        x1y3.reg.properties x1y1.reg.properties
                        x1y2.reg.properties
               cornerstone-demo/registry/implementation/cornerstone.dataSource
                        hsqldb-standalone.reg.properties
                        oracle1.reg.properties default.reg.properties
               cornerstone-demo/registry/implementation/cornerstone.factory
                        cornerstone.demo.groupFactory.reg.properties
                        cornerstone.demo.userFactory.reg.properties
                        cornerstone.demo.userListFactory.reg.properties
               cornerstone-demo/hsqldb/bin runUtil.bat runUtil.sh
               cornerstone-demo/src/java/org/apache/cornerstone/framework/demo/main
                        DemoPersistence.java DemoMain.java
               cornerstone-demo/hsqldb/lib hsqldb.jar
               cornerstone-demo/registry/implementation/org.apache.cornerstone.framework.demo.bo.factory.api.IAFactory
                        .reg.properties
               cornerstone-demo/src/java/org/apache/cornerstone/framework/demo/bo/factory
                        XFactory.java AFactory.java Y2Factory.java
               cornerstone-demo/registry/implementation/org.apache.cornerstone.framework.demo.bo.api.IY
                        y3.reg.properties
  Log:
  Seperated the cornerstone demo from the cornerstone core.
  
  Revision  Changes    Path
  1.1                  jakarta-jetspeed-2/cornerstone-demo/hsqldb/data/test.properties
  
  Index: test.properties
  ===================================================================
  #HSQL database
  #Wed Nov 26 22:25:19 PST 2003
  sql.strict_fk=true
  readonly=false
  sql.strong_fk=true
  hsqldb.version=1.7.1
  version=1.7.1
  hsqldb.cache_scale=14
  sql.compare_in_locale=false
  sql.month=true
  hsqldb.log_size=200
  modified=no
  hsqldb.cache_version=1.7.0
  hsqldb.original_version=1.7.1
  hsqldb.compatible_version=1.7.0
  sql.enforce_size=false
  
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/hsqldb/data/select.sql
  
  Index: select.sql
  ===================================================================
  select * from test_user
  go
  select * from test_group
  go
  select * from test_user_group
  
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/hsqldb/data/test.script
  
  Index: test.script
  ===================================================================
  CREATE TABLE TEST_USER(ID INTEGER NOT NULL IDENTITY PRIMARY KEY,LOGIN_NAME VARCHAR,FIRST_NAME VARCHAR,LAST_NAME VARCHAR)
  CREATE TABLE TEST_GROUP(ID INTEGER NOT NULL IDENTITY PRIMARY KEY,NAME VARCHAR)
  CREATE TABLE TEST_USER_GROUP(ID INTEGER NOT NULL IDENTITY PRIMARY KEY,USER_ID INTEGER,GROUP_ID INTEGER,CONSTRAINT SYS_FK_1 FOREIGN KEY(USER_ID) REFERENCES TEST_USER(ID),CONSTRAINT SYS_FK_2 FOREIGN KEY(GROUP_ID) REFERENCES TEST_GROUP(ID))
  GRANT ALL ON CLASS "java.lang.Math" TO PUBLIC
  GRANT ALL ON CLASS "org.hsqldb.Library" TO PUBLIC
  CREATE USER SA PASSWORD "" ADMIN
  CREATE ALIAS DAYNAME FOR "org.hsqldb.Library.dayname"
  CREATE ALIAS SPACE FOR "org.hsqldb.Library.space"
  CREATE ALIAS SUBSTRING FOR "org.hsqldb.Library.substring"
  CREATE ALIAS HEXTORAW FOR "org.hsqldb.Library.hexToRaw"
  CREATE ALIAS SQRT FOR "java.lang.Math.sqrt"
  CREATE ALIAS ABS FOR "org.hsqldb.Library.abs"
  CREATE ALIAS POWER FOR "java.lang.Math.pow"
  CREATE ALIAS CHAR FOR "org.hsqldb.Library.character"
  CREATE ALIAS CONCAT FOR "org.hsqldb.Library.concat"
  CREATE ALIAS PI FOR "org.hsqldb.Library.pi"
  CREATE ALIAS RAWTOHEX FOR "org.hsqldb.Library.rawToHex"
  CREATE ALIAS SECOND FOR "org.hsqldb.Library.second"
  CREATE ALIAS TRUNCATE FOR "org.hsqldb.Library.truncate"
  CREATE ALIAS MONTH FOR "org.hsqldb.Library.month"
  CREATE ALIAS LOWER FOR "org.hsqldb.Library.lcase"
  CREATE ALIAS ATAN2 FOR "java.lang.Math.atan2"
  CREATE ALIAS REPEAT FOR "org.hsqldb.Library.repeat"
  CREATE ALIAS DAYOFMONTH FOR "org.hsqldb.Library.dayofmonth"
  CREATE ALIAS TAN FOR "java.lang.Math.tan"
  CREATE ALIAS RADIANS FOR "java.lang.Math.toRadians"
  CREATE ALIAS FLOOR FOR "java.lang.Math.floor"
  CREATE ALIAS NOW FOR "org.hsqldb.Library.now"
  CREATE ALIAS ACOS FOR "java.lang.Math.acos"
  CREATE ALIAS DAYOFWEEK FOR "org.hsqldb.Library.dayofweek"
  CREATE ALIAS CEILING FOR "java.lang.Math.ceil"
  CREATE ALIAS DAYOFYEAR FOR "org.hsqldb.Library.dayofyear"
  CREATE ALIAS LCASE FOR "org.hsqldb.Library.lcase"
  CREATE ALIAS WEEK FOR "org.hsqldb.Library.week"
  CREATE ALIAS SOUNDEX FOR "org.hsqldb.Library.soundex"
  CREATE ALIAS ASIN FOR "java.lang.Math.asin"
  CREATE ALIAS LOCATE FOR "org.hsqldb.Library.locate"
  CREATE ALIAS EXP FOR "java.lang.Math.exp"
  CREATE ALIAS MONTHNAME FOR "org.hsqldb.Library.monthname"
  CREATE ALIAS YEAR FOR "org.hsqldb.Library.year"
  CREATE ALIAS LEFT FOR "org.hsqldb.Library.left"
  CREATE ALIAS ROUNDMAGIC FOR "org.hsqldb.Library.roundMagic"
  CREATE ALIAS BITOR FOR "org.hsqldb.Library.bitor"
  CREATE ALIAS LTRIM FOR "org.hsqldb.Library.ltrim"
  CREATE ALIAS COT FOR "org.hsqldb.Library.cot"
  CREATE ALIAS COS FOR "java.lang.Math.cos"
  CREATE ALIAS MOD FOR "org.hsqldb.Library.mod"
  CREATE ALIAS SIGN FOR "org.hsqldb.Library.sign"
  CREATE ALIAS DEGREES FOR "java.lang.Math.toDegrees"
  CREATE ALIAS LOG FOR "java.lang.Math.log"
  CREATE ALIAS SIN FOR "java.lang.Math.sin"
  CREATE ALIAS CURTIME FOR "org.hsqldb.Library.curtime"
  CREATE ALIAS DIFFERENCE FOR "org.hsqldb.Library.difference"
  CREATE ALIAS INSERT FOR "org.hsqldb.Library.insert"
  CREATE ALIAS SUBSTR FOR "org.hsqldb.Library.substring"
  CREATE ALIAS DATABASE FOR "org.hsqldb.Library.database"
  CREATE ALIAS MINUTE FOR "org.hsqldb.Library.minute"
  CREATE ALIAS HOUR FOR "org.hsqldb.Library.hour"
  CREATE ALIAS IDENTITY FOR "org.hsqldb.Library.identity"
  CREATE ALIAS QUARTER FOR "org.hsqldb.Library.quarter"
  CREATE ALIAS CURDATE FOR "org.hsqldb.Library.curdate"
  CREATE ALIAS BITAND FOR "org.hsqldb.Library.bitand"
  CREATE ALIAS USER FOR "org.hsqldb.Library.user"
  CREATE ALIAS UCASE FOR "org.hsqldb.Library.ucase"
  CREATE ALIAS RTRIM FOR "org.hsqldb.Library.rtrim"
  CREATE ALIAS LOG10 FOR "org.hsqldb.Library.log10"
  CREATE ALIAS RIGHT FOR "org.hsqldb.Library.right"
  CREATE ALIAS ATAN FOR "java.lang.Math.atan"
  CREATE ALIAS UPPER FOR "org.hsqldb.Library.ucase"
  CREATE ALIAS ASCII FOR "org.hsqldb.Library.ascii"
  CREATE ALIAS RAND FOR "java.lang.Math.random"
  CREATE ALIAS LENGTH FOR "org.hsqldb.Library.length"
  CREATE ALIAS ROUND FOR "org.hsqldb.Library.round"
  CREATE ALIAS REPLACE FOR "org.hsqldb.Library.replace"
  INSERT INTO TEST_USER VALUES(101,'dilbert','Dilbert','Funny')
  INSERT INTO TEST_USER VALUES(102,'outm','Out','of Mind')
  INSERT INTO TEST_USER VALUES(201,'pointy','Pointy','Hair')
  INSERT INTO TEST_USER VALUES(202,'outt','Out','of Touch')
  INSERT INTO TEST_USER VALUES(301,'userd','User','Dumb')
  INSERT INTO TEST_USER VALUES(302,'userp','User','Picky')
  INSERT INTO TEST_GROUP VALUES(100,'engineers')
  INSERT INTO TEST_GROUP VALUES(200,'managers')
  INSERT INTO TEST_GROUP VALUES(300,'users')
  INSERT INTO TEST_USER_GROUP VALUES(1,101,100)
  INSERT INTO TEST_USER_GROUP VALUES(2,102,100)
  INSERT INTO TEST_USER_GROUP VALUES(3,201,200)
  INSERT INTO TEST_USER_GROUP VALUES(4,202,200)
  INSERT INTO TEST_USER_GROUP VALUES(5,301,300)
  INSERT INTO TEST_USER_GROUP VALUES(6,302,300)
  
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/hsqldb/data/insert.sql
  
  Index: insert.sql
  ===================================================================
  insert into test_user values (101, 'dilbert', 'Dilbert', 'Funny')
  insert into test_user values (102, 'outm', 'Out', 'of Mind')
  insert into test_user values (201, 'pointy', 'Pointy', 'Hair')
  insert into test_user values (202, 'outt', 'Out', 'of Touch')
  insert into test_user values (301, 'userd', 'User', 'Dumb')
  insert into test_user values (302, 'userp', 'User', 'Picky')
  
  insert into test_group values (100, 'engineers')
  insert into test_group values (200, 'managers')
  insert into test_group values (300, 'users')
  
  insert into test_user_group values (1, 101, 100)
  insert into test_user_group values (2, 102, 100)
  insert into test_user_group values (3, 201, 200)
  insert into test_user_group values (4, 202, 200)
  insert into test_user_group values (5, 301, 300)
  insert into test_user_group values (6, 302, 300)
  
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/hsqldb/data/drop.sql
  
  Index: drop.sql
  ===================================================================
  drop table test_user;
  drop table test_group;
  drop table test_user_group;
  
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/hsqldb/data/create.sql
  
  Index: create.sql
  ===================================================================
  create table test_user
  (
  	id int identity,
  	login_name varchar,
  	first_name varchar, 
  	last_name varchar
  );
  go
  
  create table test_group
  (
  	id int identity,
  	name varchar
  );
  go
  
  create table test_user_group
  (
  	id int identity,
  	user_id int,
  	group_id int,
  	foreign key (user_id) references test_user(id),
  	foreign key (group_id) references test_group(id)
  );
  go
  
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/hsqldb/data/query.bat
  
  Index: query.bat
  ===================================================================
  ..\bin\runUtil.bat ScriptTool -script %1
  
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/registry/implementation/cornerstone.service/cornerstone.demo.getDate3.reg.properties
  
  Index: cornerstone.demo.getDate3.reg.properties
  ===================================================================
  _.parent.name=cornerstone.demo.getDate
  dateFormatPattern=yyyy.MM.dd G 'at' HH:mm:ss z
  
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/registry/implementation/cornerstone.service/cornerstone.demo.getDate102.reg.properties
  
  Index: cornerstone.demo.getDate102.reg.properties
  ===================================================================
  _.parent.name=cornerstone.demo.getDate2
  _.invokeDirect.inputs=df102,tz102
  _.invokeDirect.output=date102
  
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/registry/implementation/cornerstone.service/cornerstone.demo.getDate103.reg.properties
  
  Index: cornerstone.demo.getDate103.reg.properties
  ===================================================================
  _.parent.name=cornerstone.demo.getDate3
  _.invokeDirect.inputs=df103,tz103
  _.invokeDirect.output=date103
  
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/registry/implementation/cornerstone.service/cornerstone.demo.getDate101.reg.properties
  
  Index: cornerstone.demo.getDate101.reg.properties
  ===================================================================
  _.parent.name=cornerstone.demo.getDate
  _.invokeDirect.inputs=df101,tz101
  _.invokeDirect.output=date101
  
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/registry/implementation/cornerstone.service/cornerstone.demo.getDate.reg.properties
  
  Index: cornerstone.demo.getDate.reg.properties
  ===================================================================
  _.factory.className=org.apache.cornerstone.framework.demo.service.DateServiceFactory
  
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/registry/implementation/cornerstone.service/cornerstone.demo.getDate2.reg.properties
  
  Index: cornerstone.demo.getDate2.reg.properties
  ===================================================================
  _.parent.name=cornerstone.demo.getDate
  dateFormatPattern=EEE, MMM d, yyyy
  
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/registry/implementation/cornerstone.service/cornerstone.demo.getDate1x1.reg.properties
  
  Index: cornerstone.demo.getDate1x1.reg.properties
  ===================================================================
  _.parent.name=cornerstone.controller.sequence
  sequence=s1,s2,s3
  sequence.s1.parent.name=cornerstone.demo.getDate101
  sequence.s2.parent.name=cornerstone.demo.getDate102
  sequence.s3.parent.name=cornerstone.demo.getDate103
  
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/src/java/org/apache/cornerstone/framework/demo/bo/api/IUser.java
  
  Index: IUser.java
  ===================================================================
  package org.apache.cornerstone.framework.demo.bo.api;
  
  public interface IUser
  {
      public static final String REVISION = "$Revision: 1.1 $";
  
      public Integer getId();
      public void setId(Integer id);
  
      public String getLoginName();
      public void setLoginName(String loginName);
  
      public String getFirstName();
      public void setFirstName(String firstName);
  
      public String getLastName();
      public void setLastName(String lastName);
  }
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/src/java/org/apache/cornerstone/framework/demo/bo/api/IB.java
  
  Index: IB.java
  ===================================================================
  package org.apache.cornerstone.framework.demo.bo.api;
  
  public interface IB
  {
  	public static final String REVISION = "$Revision: 1.1 $";
  
  	public int getQ();
  	public void setQ(int q);
  }
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/src/java/org/apache/cornerstone/framework/demo/bo/api/IGroup.java
  
  Index: IGroup.java
  ===================================================================
  package org.apache.cornerstone.framework.demo.bo.api;
  
  import java.util.List;
  
  public interface IGroup
  {
      public static final String REVISION = "$Revision: 1.1 $";
  
      public Integer getId();
      public void setId(Integer id);
  
      public String getName();
      public void setName(String name);
  
      public List getUserList();
      public void setUserList(List userList);
  }
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/src/java/org/apache/cornerstone/framework/demo/bo/api/IX.java
  
  Index: IX.java
  ===================================================================
  package org.apache.cornerstone.framework.demo.bo.api;
  
  public interface IX
  {
      public static final String REVISION = "$Revision: 1.1 $";
  
      public String getP();
      public void setP(String p);
  
      public IY getY();
      public void setY(IY y);
  }
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/src/java/org/apache/cornerstone/framework/demo/bo/api/IY.java
  
  Index: IY.java
  ===================================================================
  package org.apache.cornerstone.framework.demo.bo.api;
  
  public interface IY
  {
      public static final String REVISION = "$Revision: 1.1 $";
  
      public int getQ();
      public void setQ(int q);
  }
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/src/java/org/apache/cornerstone/framework/demo/bo/api/IA.java
  
  Index: IA.java
  ===================================================================
  package org.apache.cornerstone.framework.demo.bo.api;
  
  public interface IA
  {
  	public static final String REVISION = "$Revision: 1.1 $";
  
  	public String getP();
  	public void setP(String p);
  
  	public IB getB();
  	public void setB(IB b);
  }
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/RUNNING.txt
  
  Index: RUNNING.txt
  ===================================================================
  How to Build and Run:
  
  1.  Make sure the cornerstone project has been successfuly built.
  2.  from the cornerstone-demo directory just invoke "maven" which defaults to the "run-demo" goal.
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/project.properties
  
  Index: project.properties
  ===================================================================
  # Display the date on the Maven web site
  maven.xdoc.date = left
  
  # Display the maven version the web site is documenting
  maven.xdoc.version = ${pom.currentVersion}
  
  maven.checkstyle.properties=${basedir}/../checkstyle.properties
  
  maven.compile.deprecation=on
  
  # Include private method and field in Javadoc.
  maven.javadoc.private=true
  
  # Removed the rule ${plugin.resources}/rulesets/naming.xml from the default
  # maven.pmd.rulesetfiles.  This is because the LongVariableName rule is to
  # restrictive.  We need to increase the limit from 12 to 20
  maven.pmd.rulesetfiles=${plugin.resources}/rulesets/strings.xml,${plugin.resources}/rulesets/junit.xml,${plugin.resources}/rulesets/braces.xml,${plugin.resources}/rulesets/basic.xml,${plugin.resources}/rulesets/unusedcode.xml,${plugin.resources}/rulesets/design.xml,${plugin.resources}/rulesets/imports.xml,${plugin.resources}/rulesets/codesize.xml
  
  jar.name=${maven.final.name}.jar
  
  CORNERSTONE_HOME=../cornerstone
  CORNERSTONE_RUNTIME_HOME=${CORNERSTONE_HOME}/target/runtime
  CORNERSTONE_RUNTIME_REGISTRY_DIR=${CORNERSTONE_RUNTIME_HOME}/registry
  
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/log4j.properties
  
  Index: log4j.properties
  ===================================================================
  # Set root category priority to DEBUG and its only appender to A1.
  log4j.rootCategory=INFO, A1
    
  # A1 is set to be a ConsoleAppender. 
  log4j.appender.A1=org.apache.log4j.ConsoleAppender
    
  # A1 uses PatternLayout.
  log4j.appender.A1.layout=org.apache.log4j.PatternLayout
  log4j.appender.A1.layout.ConversionPattern=%d %-4r [%t] %-5p %c %x - %m%n
  
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/maven.xml
  
  Index: maven.xml
  ===================================================================
  <project default="run-demo"
           xmlns:j="jelly:core" 
           xmlns:define="jelly:define"
           xmlns:reactor="reactor">
           
           
   <goal name="run-demo">
  
       <attainGoal name="jar:jar" />
       <!-- Merge standard runtime and demo into same directory -->
       <copy todir="${maven.build.dir}/runtime">
  			<fileset dir="${CORNERSTONE_RUNTIME_HOME}"/>
  	  </copy>	  
  	  <copy todir="${maven.build.dir}/runtime/registry">
  			<fileset dir="${basedir}/registry"/>
  	  </copy>
  
  
       <java classname="org.apache.cornerstone.framework.demo.main.DemoMain" fork="yes">
        <sysproperty key="log4j.configuration" value="log4j.properties"/> 
        <sysproperty key="CORNERSTONE_RUNTIME_HOME" value="${basedir}/target/runtime"/>
         <classpath>
           <path refid="maven.dependency.classpath"/>
           <pathelement path="${maven.build.dir}/${jar.name}"/>
          </classpath>
        </java>
  
    </goal>
  
  
    
  </project>
  
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/project.xml
  
  Index: project.xml
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?>
  
  <project>
    <extend>${basedir}/../project.xml</extend>
    <pomVersion>3</pomVersion>
    <id>jetspeed-cornerstone-demo</id>
    <name>Cornerstone Component Framework Demo</name>
    <currentVersion>1.0</currentVersion>
    <package>org.apache.cornerstone</package>
    <description>
  	This is a demo of the Cornerstone, which is IoC/Aspect based component framework
    </description>
    <shortDescription>Cornerstone Component Framework Demo</shortDescription>
    <dependencies>
    	 <dependency>  	  
        <id>jetspeed-cornerstone</id>   
        <groupId>jetspeed2</groupId>   
        <version>1.0</version>
        <properties>
          <war.bundle.jar>true</war.bundle.jar>
        </properties>
      </dependency> 	
    	
    	 <dependency>
        <id>commons-collections</id>
        <version>2.1</version>
        <properties>
          <war.bundle.jar>true</war.bundle.jar>
        </properties>
      </dependency>
      
      <dependency>
        <id>commons-logging</id>
        <version>1.0.2</version>
        <properties>
          <war.bundle.jar>false</war.bundle.jar>
        </properties>
      </dependency>
    	
    	
    	 <dependency>
        <id>commons-beanutils</id>
        <version>1.6</version>
        <properties>
          <war.bundle.jar>true</war.bundle.jar>
        </properties>
      </dependency>
      
        <dependency>
        <id>junit</id>
        <version>3.8.1</version>
        <properties>
          <war.bundle.jar>false</war.bundle.jar>
        </properties>
      </dependency>
      
      <dependency>
        <id>log4j</id>
        <version>1.2.8</version>
        <properties>
          <war.bundle.jar>true</war.bundle.jar>
        </properties>
      </dependency>
      
      <dependency>
      	<id>jmxri</id>
         <groupId>jmx</groupId>
        
        <version>1.2.1</version>
        <properties>
          <war.bundle.jar>true</war.bundle.jar>
        </properties>
      </dependency>
      
      <dependency>
       <id>jmxtools</id>
       <groupId>jmx</groupId>
        
        <version>1.2.1</version>
        <properties>
          <war.bundle.jar>true</war.bundle.jar>
        </properties>
      </dependency>
      
      <dependency>
        <id>servletapi</id>
        <version>2.3</version>
        <properties>
          <war.bundle.jar>false</war.bundle.jar>
        </properties> 
      </dependency>
      
    </dependencies>
    <build>
      <sourceDirectory>${basedir}/src/java</sourceDirectory>
      <resources>
   	  <resource>
  	   <directory>${basedir}/src/resources</directory>
  	  </resource>
      </resources>    
    </build>
  </project>
  
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/registry/implementation/org.apache.cornerstone.framework.demo.bo.api.IA/a1b2.reg.properties
  
  Index: a1b2.reg.properties
  ===================================================================
  _.instance.className=org.apache.cornerstone.framework.demo.bo.A1
  property.b.instance.className=org.apache.cornerstone.framework.demo.bo.B2
  
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/registry/implementation/org.apache.cornerstone.framework.demo.bo.api.IA/a1_viaParentName.reg.properties
  
  Index: a1_viaParentName.reg.properties
  ===================================================================
  _.parent.name=a1_viaInstanceClassName
  
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/registry/implementation/org.apache.cornerstone.framework.demo.bo.api.IA/a1_viaFactoryClassName.reg.properties
  
  Index: a1_viaFactoryClassName.reg.properties
  ===================================================================
  _.factory.className=org.apache.cornerstone.framework.demo.bo.factory.AFactory
  
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/registry/implementation/org.apache.cornerstone.framework.demo.bo.api.IA/a1_viaInstanceClassName.reg.properties
  
  Index: a1_viaInstanceClassName.reg.properties
  ===================================================================
  _.instance.className=org.apache.cornerstone.framework.demo.bo.A1
  
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/registry/implementation/org.apache.cornerstone.framework.demo.bo.api.IA/a1b1.reg.properties
  
  Index: a1b1.reg.properties
  ===================================================================
  _.instance.className=org.apache.cornerstone.framework.demo.bo.A1
  property.b.instance.className=org.apache.cornerstone.framework.demo.bo.B1
  
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/src/java/org/apache/cornerstone/framework/demo/bo/B1.java
  
  Index: B1.java
  ===================================================================
  package org.apache.cornerstone.framework.demo.bo;
  
  import org.apache.cornerstone.framework.demo.bo.api.IB;
  
  public class B1 implements IB
  {
  	public static final String REVISION = "$Revision: 1.1 $";
  
  	/* (non-Javadoc)
  	 * @see org.apache.cornerstone.framework.demo.bo.api.IB#getQ()
  	 */
  	public int getQ()
  	{
  		return _q;
  	}
  
  	/* (non-Javadoc)
  	 * @see org.apache.cornerstone.framework.demo.bo.api.IB#setQ(java.lang.String)
  	 */
  	public void setQ(int q)
  	{
  		_q = q;
  	}
  
  	protected int _q = 100;
  }
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/src/java/org/apache/cornerstone/framework/demo/bo/BaseUser.java
  
  Index: BaseUser.java
  ===================================================================
  package org.apache.cornerstone.framework.demo.bo;
  
  import org.apache.cornerstone.framework.demo.bo.api.IUser;
  
  public class BaseUser implements IUser
  {
  	/* (non-Javadoc)
  	 * @see org.apache.cornerstone.framework.demo.bo.api.IUser#getId()
  	 */
  	public Integer getId()
  	{
          return _id;
  	}
  
  	/* (non-Javadoc)
  	 * @see org.apache.cornerstone.framework.demo.bo.api.IUser#setId(java.math.BigDecimal)
  	 */
  	public void setId(Integer id)
  	{
  		_id = id;
  	}
  
      /* (non-Javadoc)
  	 * @see org.apache.cornerstone.framework.demo.bo.api.IUser#getLoginName()
  	 */
  	public String getLoginName()
  	{
  		return _loginName;
  	}
  
  	/* (non-Javadoc)
  	 * @see org.apache.cornerstone.framework.demo.bo.api.IUser#getFirstName()
  	 */
  	public String getFirstName()
  	{
  		return _firstName;
  	}
  
      /* (non-Javadoc)
  	 * @see org.apache.cornerstone.framework.demo.bo.api.IUser#getLastName()
  	 */
  	public String getLastName()
  	{
  		return _lastName;
  	}
  
      /* (non-Javadoc)
  	 * @see org.apache.cornerstone.framework.demo.bo.api.IUser#setLoginName(java.lang.String)
  	 */
  	public void setLoginName(String loginName)
  	{
  		_loginName = loginName;
  	}
  
  	/* (non-Javadoc)
  	 * @see org.apache.cornerstone.framework.demo.bo.api.IUser#setFirstName(java.lang.String)
  	 */
  	public void setFirstName(String firstName)
  	{
  		_firstName = firstName;
  	}
  
  	/* (non-Javadoc)
  	 * @see org.apache.cornerstone.framework.demo.bo.api.IUser#setLastName(java.lang.String)
  	 */
  	public void setLastName(String lastName)
  	{
  		_lastName = lastName;
  	}
  
      protected Integer _id;
      protected String _loginName;
      protected String _firstName;
      protected String _lastName;
  }
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/src/java/org/apache/cornerstone/framework/demo/bo/BaseGroup.java
  
  Index: BaseGroup.java
  ===================================================================
  package org.apache.cornerstone.framework.demo.bo;
  
  import java.util.List;
  import org.apache.cornerstone.framework.demo.bo.api.IGroup;
  
  public class BaseGroup implements IGroup
  {
  	public static final String REVISION = "$Revision: 1.1 $";
  
      /* (non-Javadoc)
  	 * @see org.apache.cornerstone.framework.demo.bo.api.IGroup#getId()
  	 */
  	public Integer getId()
  	{
  		return _id;
  	}
  
  	/* (non-Javadoc)
  	 * @see org.apache.cornerstone.framework.demo.bo.api.IGroup#setId(java.math.BigDecimal)
  	 */
  	public void setId(Integer id)
  	{
  		_id = id;
  	}
  
      /* (non-Javadoc)
  	 * @see org.apache.cornerstone.framework.demo.bo.api.IGroup#getName()
  	 */
  	public String getName()
  	{
  		return _name;
  	}
  
      /* (non-Javadoc)
  	 * @see org.apache.cornerstone.framework.demo.bo.api.IGroup#setName(java.lang.String)
  	 */
  	public void setName(String name)
  	{
  		_name = name;
  	}
  
      /* (non-Javadoc)
  	 * @see org.apache.cornerstone.framework.demo.bo.api.IGroup#getUserList()
  	 */
  	public List getUserList()
  	{
  		return _userList;
  	}
  
      /* (non-Javadoc)
  	 * @see org.apache.cornerstone.framework.demo.bo.api.IGroup#setUserList(java.util.List)
  	 */
  	public void setUserList(List userList)
  	{
  		_userList = userList;
  	}
  
      protected Integer _id;
      protected String _name;
      protected List _userList;
  }
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/src/java/org/apache/cornerstone/framework/demo/bo/A1.java
  
  Index: A1.java
  ===================================================================
  package org.apache.cornerstone.framework.demo.bo;
  
  import org.apache.cornerstone.framework.demo.bo.api.IA;
  import org.apache.cornerstone.framework.demo.bo.api.IB;
  
  public class A1 implements IA
  {
  	public static final String REVISION = "$Revision: 1.1 $";
  
  	/* (non-Javadoc)
  	 * @see org.apache.cornerstone.framework.demo.bo.api.IA#getP()
  	 */
  	public String getP()
  	{
  		return _p;
  	}
  
  	/* (non-Javadoc)
  	 * @see org.apache.cornerstone.framework.demo.bo.api.IA#setP(java.lang.String)
  	 */
  	public void setP(String p)
  	{
  		_p = p;
  	}
  
  	/* (non-Javadoc)
  	 * @see org.apache.cornerstone.framework.demo.bo.api.IA#getB()
  	 */
  	public IB getB()
  	{
  		return _b;
  	}
  
  	/* (non-Javadoc)
  	 * @see org.apache.cornerstone.framework.demo.bo.api.IA#setB(org.apache.cornerstone.framework.demo.bo.api.IB)
  	 */
  	public void setB(IB b)
  	{
  		_b = b;
  	}
  
  	protected String _p = "p";
  	protected IB _b;
  }
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/src/java/org/apache/cornerstone/framework/demo/bo/X1.java
  
  Index: X1.java
  ===================================================================
  package org.apache.cornerstone.framework.demo.bo;
  
  import org.apache.cornerstone.framework.demo.bo.api.IX;
  import org.apache.cornerstone.framework.demo.bo.api.IY;
  
  public class X1 implements IX
  {
      public static final String REVISION = "$Revision: 1.1 $";
  
  	/* (non-Javadoc)
  	 * @see org.apache.cornerstone.framework.demo.bo.api.IX#getP()
  	 */
  	public String getP()
  	{
  		return _p;
  	}
  
      /* (non-Javadoc)
  	 * @see org.apache.cornerstone.framework.demo.bo.api.IX#getY()
  	 */
  	public IY getY()
  	{
  		return _y;
  	}
  
  	/* (non-Javadoc)
  	 * @see org.apache.cornerstone.framework.demo.bo.api.IX#setP(java.lang.String)
  	 */
  	public void setP(String p)
  	{
  		_p = p;
  	}
  
  	/* (non-Javadoc)
  	 * @see org.apache.cornerstone.framework.demo.bo.api.IX#setY(org.apache.cornerstone.framework.demo.bo.api.IY)
  	 */
  	public void setY(IY y)
  	{
  		_y = y;
  	}
  
      protected String _p;
      protected IY _y;
  }
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/src/java/org/apache/cornerstone/framework/demo/bo/Y3.java
  
  Index: Y3.java
  ===================================================================
  package org.apache.cornerstone.framework.demo.bo;
  
  import org.apache.cornerstone.framework.demo.bo.api.IY;
  
  public class Y3 implements IY
  {
      public static final String REVISION = "$Revision: 1.1 $";
  
      /* (non-Javadoc)
       * @see org.apache.cornerstone.framework.demo.bo.api.IY#getQ()
       */
      public int getQ()
      {
          return _q;
      }
  
      /* (non-Javadoc)
       * @see org.apache.cornerstone.framework.demo.bo.api.IY#setQ(int)
       */
      public void setQ(int q)
      {
          _q = q;
      }
  
      protected int _q = 3000;
  }
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/src/java/org/apache/cornerstone/framework/demo/bo/Y1.java
  
  Index: Y1.java
  ===================================================================
  package org.apache.cornerstone.framework.demo.bo;
  
  import org.apache.cornerstone.framework.demo.bo.api.IY;
  
  public class Y1 implements IY
  {
      public static final String REVISION = "$Revision: 1.1 $";
  
  	/* (non-Javadoc)
  	 * @see org.apache.cornerstone.framework.demo.bo.api.IY#getQ()
  	 */
  	public int getQ()
  	{
  		return _q;
  	}
  
      /* (non-Javadoc)
  	 * @see org.apache.cornerstone.framework.demo.bo.api.IY#setQ(int)
  	 */
  	public void setQ(int q)
  	{
  		_q = q;
  	}
  
  	protected int _q = 1000;
  }
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/src/java/org/apache/cornerstone/framework/demo/bo/Y2.java
  
  Index: Y2.java
  ===================================================================
  package org.apache.cornerstone.framework.demo.bo;
  
  import org.apache.cornerstone.framework.demo.bo.api.IY;
  
  public class Y2 implements IY
  {
      public static final String REVISION = "$Revision: 1.1 $";
  
      /* (non-Javadoc)
       * @see org.apache.cornerstone.framework.demo.bo.api.IY#getQ()
       */
      public int getQ()
      {
          return _q;
      }
  
      /* (non-Javadoc)
       * @see org.apache.cornerstone.framework.demo.bo.api.IY#setQ(int)
       */
      public void setQ(int q)
      {
          _q = q;
      }
  
      protected int _q = 2000;
  }
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/src/java/org/apache/cornerstone/framework/demo/bo/B2.java
  
  Index: B2.java
  ===================================================================
  package org.apache.cornerstone.framework.demo.bo;
  
  import org.apache.cornerstone.framework.demo.bo.api.IB;
  
  public class B2 implements IB
  {
  	public static final String REVISION = "$Revision: 1.1 $";
  
  	/* (non-Javadoc)
  	 * @see org.apache.cornerstone.framework.demo.bo.api.IB#getQ()
  	 */
  	public int getQ()
  	{
  		return _q;
  	}
  
  	/* (non-Javadoc)
  	 * @see org.apache.cornerstone.framework.demo.bo.api.IB#setQ(java.lang.String)
  	 */
  	public void setQ(int q)
  	{
  		_q = q;
  	}
  
  	protected int _q = 200;
  }
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/registry/implementation/org.apache.cornerstone.framework.demo.bo.api.IB/b1.reg.properties
  
  Index: b1.reg.properties
  ===================================================================
  _.instance.className=org.apache.cornerstone.framework.demo.bo.B1
  
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/registry/implementation/org.apache.cornerstone.framework.demo.bo.api.IB/b2.reg.properties
  
  Index: b2.reg.properties
  ===================================================================
  _.instance.className=org.apache.cornerstone.framework.demo.bo.B2
  
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/src/java/org/apache/cornerstone/framework/demo/service/DateServiceFactory.java
  
  Index: DateServiceFactory.java
  ===================================================================
  package org.apache.cornerstone.framework.demo.service;
  
  import org.apache.cornerstone.framework.api.factory.CreationException;
  import org.apache.cornerstone.framework.service.BaseServiceFactory;
  
  public class DateServiceFactory extends BaseServiceFactory
  {
  	public static final String REVISION = "$Revision: 1.1 $";
  
      public static final String CONFIG_DATE_SERVICE_CLASS_NAME = "dateService.className";
      public static final String DEFAULT_DATE_SERVICE_CLASS_NAME = "org.apache.cornerstone.framework.demo.service.DateService";
  
  	// ---------------
  	// Factory Pattern
  
  	public Object createInstance() throws CreationException
  	{
          // get class name from configuration (DateServiceFactory.properties)
          String dateServiceClassName = getConfigPropertyWithDefault(CONFIG_DATE_SERVICE_CLASS_NAME, DEFAULT_DATE_SERVICE_CLASS_NAME);
  		try
  		{
  			return Class.forName(dateServiceClassName).newInstance();
  		}
  		catch (Exception e)
  		{
  			throw new CreationException(e);
  		}
  	}
  
  	// -----------------
  	// Singleton Pattern
  
  	public static DateServiceFactory getSingleton()
  	{
  		return _Singleton;
  	}
  
  	private static DateServiceFactory _Singleton = new DateServiceFactory();
  }
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/src/java/org/apache/cornerstone/framework/demo/service/DateServiceFactory.properties
  
  Index: DateServiceFactory.properties
  ===================================================================
  dateService.className=org.apache.cornerstone.framework.demo.service.DateService
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/src/java/org/apache/cornerstone/framework/demo/service/DateService.java
  
  Index: DateService.java
  ===================================================================
  package org.apache.cornerstone.framework.demo.service;
  
  import java.util.*;
  import java.text.*;
  import org.apache.cornerstone.framework.api.service.ServiceException;
  import org.apache.cornerstone.framework.service.BaseService;
  
  public class DateService extends BaseService
  {
  	public static final String REVISION = "$Revision: 1.1 $";
  
  	public static final String INPUT_TIME_ZONE = "timeZone";
  	public static final String INPUT_DATE_FORMAT = "dateFormat";
  	public static final String OUTPUT_DATE = "date";
  
  	public static final String DATE_FORMAT_FULL = "FULL";
  	public static final String DATE_FORMAT_SHORT = "SHORT";
  
  	public static final String CONFIG_DATE_FORMAT_PATTERN = "dateFormatPattern";
  
  	/**
  	 * Object configuration metadata
  	 */
  	public static final String CONFIG_PARAMS = CONFIG_DATE_FORMAT_PATTERN;
  
  	/**
  	 * Service metadata
  	 */
  	public static final String INVOKE_DIRECT_INPUTS = INPUT_TIME_ZONE + "," + INPUT_DATE_FORMAT;
  	public static final String INVOKE_DIRECT_OUTPUT = OUTPUT_DATE;
  
  	/**
  	 * Gets current date in time zone
  	 * @param timeZone String E.g. "GMT-0800"
  	 * @param dateStyle String DATE_FORMAT_FULL or DATE_FORMAT_SHORT
  	 * @return Current date in time zone.
  	 */
  	public String invokeDirect(String timeZone, String dateStyle) throws ServiceException
  	{
  		if (timeZone == null) timeZone = "GMT-0000";
  		if (dateStyle == null) dateStyle = DATE_FORMAT_FULL;
  
  		int dateStyleInt = DateFormat.FULL;
  		if (dateStyle.equals(DATE_FORMAT_FULL))
  			dateStyleInt = DateFormat.FULL;
  		else if (dateStyle.equals(DATE_FORMAT_SHORT))
  			dateStyleInt = DateFormat.SHORT;
  
  		String dateFormatPattern = getConfigProperty(CONFIG_DATE_FORMAT_PATTERN);
  		DateFormat df =
  			dateFormatPattern == null ?
  			DateFormat.getDateInstance(dateStyleInt) :
  			new SimpleDateFormat(dateFormatPattern);
  		df.setTimeZone(TimeZone.getTimeZone(timeZone));
  
  		Date date = new Date();
  		String dateString = df.format(date); 
  
  		return dateString;
  	}
  }
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/src/java/org/apache/cornerstone/framework/demo/bo/factory/api/IAFactory.java
  
  Index: IAFactory.java
  ===================================================================
  package org.apache.cornerstone.framework.demo.bo.factory.api;
  
  import org.apache.cornerstone.framework.api.factory.IFactory;
  
  public interface IAFactory extends IFactory
  {
  	public static final String REVISION = "$Revision: 1.1 $";
  }
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/src/java/org/apache/cornerstone/framework/demo/bo/factory/api/IXFactory.java
  
  Index: IXFactory.java
  ===================================================================
  package org.apache.cornerstone.framework.demo.bo.factory.api;
  
  import org.apache.cornerstone.framework.api.factory.IFactory;
  
  public interface IXFactory extends IFactory
  {
      public static final String REVISION = "$Revision: 1.1 $";
  }
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/src/resources/org/apache/cornerstone/framework/demo/bo/factory/AFactory.properties
  
  Index: AFactory.properties
  ===================================================================
  property.a.instance.className=org.apache.cornerstone.framework.demo.bo.A1
  ### property.b.instance.className=org.apache.cornerstone.framework.demo.bo.B1
  property.b.instance.className=org.apache.cornerstone.framework.demo.bo.B2
  
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/registry/implementation/org.apache.cornerstone.framework.demo.bo.factory.api.IXFactory/x1y3.reg.properties
  
  Index: x1y3.reg.properties
  ===================================================================
  _.instance.className=org.apache.cornerstone.framework.demo.bo.factory.XFactory
  product.instance.className=org.apache.cornerstone.framework.demo.bo.X1
  product.property.y.parent.name=y3
  product.property.p.value=x1y3
  
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/registry/implementation/org.apache.cornerstone.framework.demo.bo.factory.api.IXFactory/x1y1.reg.properties
  
  Index: x1y1.reg.properties
  ===================================================================
  _.instance.className=org.apache.cornerstone.framework.demo.bo.factory.XFactory
  product.instance.className=org.apache.cornerstone.framework.demo.bo.X1
  product.property.y.instance.className=org.apache.cornerstone.framework.demo.bo.Y1
  product.property.p.value=x1y1
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/registry/implementation/org.apache.cornerstone.framework.demo.bo.factory.api.IXFactory/x1y2.reg.properties
  
  Index: x1y2.reg.properties
  ===================================================================
  _.instance.className=org.apache.cornerstone.framework.demo.bo.factory.XFactory
  product.instance.className=org.apache.cornerstone.framework.demo.bo.X1
  product.property.y.factory.className=org.apache.cornerstone.framework.demo.bo.factory.Y2Factory
  product.property.p.value=x1y2
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/registry/implementation/cornerstone.dataSource/hsqldb-standalone.reg.properties
  
  Index: hsqldb-standalone.reg.properties
  ===================================================================
  _.instance.className=org.apache.cornerstone.framework.persistence.datasource.BaseDataSource
  _.instance.isSingleton=true
  driver.className=org.hsqldb.jdbcDriver
  connection.url=jdbc:hsqldb:../hsqldb/data/test
  connection.userName=sa
  connection.password=
  
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/registry/implementation/cornerstone.dataSource/oracle1.reg.properties
  
  Index: oracle1.reg.properties
  ===================================================================
  _.instance.className=org.apache.cornerstone.framework.persistence.datasource.BaseDataSource
  _.instance.isSingleton=true
  driver.className=com.oracle.jdbc.Driver
  connection.url=jdbc:thin:...
  connection.userName=scott
  connection.password=tiger
  
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/registry/implementation/cornerstone.dataSource/default.reg.properties
  
  Index: default.reg.properties
  ===================================================================
  _.parent.name=hsqldb-standalone
  
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/registry/implementation/cornerstone.factory/cornerstone.demo.groupFactory.reg.properties
  
  Index: cornerstone.demo.groupFactory.reg.properties
  ===================================================================
  _.instance.className=org.apache.cornerstone.framework.persistence.factory.BasePersistentObjectFactory
  dataSource.name=default
  product.instance.className=org.apache.cornerstone.framework.demo.bo.BaseGroup
  
  product.association.userList.factory.parent.name=cornerstone.demo.userListFactory
  product.association.userList.factory.parameter.queryName=byGroup
  ### product.association.userList.factory.parameter.groupId=product.property.id
  product.association.userList.factory.parameter.groupId=java.lang.Integer:100
  
  primaryKey.propertyName=id
  primaryKey.columnName=id
  query.byId=select * from test_group where id = ?
  db.columnToPropertyMap.id=id
  db.columnToPropertyMap.name=name
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/registry/implementation/cornerstone.factory/cornerstone.demo.userFactory.reg.properties
  
  Index: cornerstone.demo.userFactory.reg.properties
  ===================================================================
  _.instance.className=org.apache.cornerstone.framework.persistence.factory.BasePersistentObjectFactory
  dataSource.name=default
  product.instance.className=org.apache.cornerstone.framework.demo.bo.BaseUser
  primaryKey.propertyName=id
  primaryKey.columnName=id
  query.byId=select * from test_user where id = ?
  db.columnToPropertyMap.id=id
  db.columnToPropertyMap.login_name=loginName
  db.columnToPropertyMap.first_name=firstName
  db.columnToPropertyMap.last_name=lastName
  
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/registry/implementation/cornerstone.factory/cornerstone.demo.userListFactory.reg.properties
  
  Index: cornerstone.demo.userListFactory.reg.properties
  ===================================================================
  _.instance.className=org.apache.cornerstone.framework.persistence.factory.BasePersistentObjectListFactory
  dataSource.name=default
  query.all=select * from test_user
  query.byGroup=select tu.* from test_user tu, test_user_group tug where tug.user_id = tu.id and tug.group_id = ?
  query.byGroup.parameters=groupId
  query.default=all
  element.parent.name=cornerstone.demo.userFactory
  
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/hsqldb/bin/runUtil.bat
  
  Index: runUtil.bat
  ===================================================================
  cd ..\data
  @java -classpath ..\lib\hsqldb.jar org.hsqldb.util.%1 %2 %3 %4 %5 %6 %7 %8 %9
  
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/hsqldb/bin/runUtil.sh
  
  Index: runUtil.sh
  ===================================================================
  #!/bin/sh
  # -----------------------------------------------------
  # Run with -help for usage.
  # If $JAVA_HOME is set, editing this script should not be required.
  # Send any questions to fchoong@user.sourceforge.net
  # -----------------------------------------------------
  
  # the value set here will override the value passed by $JAVA_HOME or the -jdkhome switch
  jdkhome=""
  jdkhome=""
  jargs=""
  thread_flag=""
  
  PRG=$0
  
  #
  # resolve symlinks
  #
  
  while [ -h "$PRG" ]; do
      ls=`ls -ld "$PRG"`
      link=`expr "$ls" : '^.*-> \(.*\)$' 2>/dev/null`
      if expr "$link" : '^/' 2> /dev/null >/dev/null; then
  	PRG="$link"
      else
  	PRG="`dirname $PRG`/$link"
      fi
  done
  
  progdir=`dirname $PRG`
  progname=`basename $0`
  
  # ../ will lead us to the home
  dbhome="$progdir/.."
  
  # absolutize dbhome
  
  dbhome=`cd ${dbhome}; pwd`
  
  #
  # bring in needed functions
  
  . ${dbhome}/lib/functions
  
  #--------------------------------------------------------------------------------------------------------------
  pre_main
  
  #
  # let's go
  #
      cd $dbhome/data
      exec "$jdkhome/bin/java" $thread_flag -classpath "$cp" $jargs "org.hsqldb.util.$@"
  # and we exit.
  
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/src/java/org/apache/cornerstone/framework/demo/main/DemoPersistence.java
  
  Index: DemoPersistence.java
  ===================================================================
  package org.apache.cornerstone.framework.demo.main;
  
  import java.util.List;
  
  import org.apache.cornerstone.framework.api.factory.CreationException;
  import org.apache.cornerstone.framework.api.factory.IFactory;
  import org.apache.cornerstone.framework.api.implementation.ImplementationException;
  import org.apache.cornerstone.framework.bean.visitor.BeanPrinter;
  import org.apache.cornerstone.framework.demo.bo.api.IGroup;
  import org.apache.cornerstone.framework.demo.bo.api.IUser;
  import org.apache.cornerstone.framework.init.Cornerstone;
  import org.apache.cornerstone.framework.init.InitException;
  import org.apache.log4j.PropertyConfigurator;
  
  public class DemoPersistence
  {
      public static final String REVISION = "$Revision: 1.1 $";
  
      public static void main(String[] args) throws InitException, ImplementationException, CreationException
      {
          // init log4j
          String log4jConfigFilePath = System.getProperty("log4j.configuration", "log4j.properties");
          PropertyConfigurator.configure(log4jConfigFilePath);
  
          Cornerstone.init();
  
          IFactory groupFactory = (IFactory) Cornerstone.getImplementationManager().createImplementation(
          	IFactory.class,
          	"cornerstone.demo.groupFactory"
          );
          IGroup group = (IGroup) groupFactory.createInstance(new Integer(100));
          System.out.println("group=" + BeanPrinter.getPrintString(group));
  
  		IFactory userFactory = (IFactory) Cornerstone.getImplementationManager().createImplementation(
  			IFactory.class,
  			"cornerstone.demo.userFactory"
  		);
  		IUser user = (IUser) userFactory.createInstance(new Integer(101));
  		System.out.println("user=" + BeanPrinter.getPrintString(user));
  
  		IFactory userListFactory = (IFactory) Cornerstone.getImplementationManager().createImplementation(
  			IFactory.class,
  			"cornerstone.demo.userListFactory"
  		);
  		List userList = (List) userListFactory.createInstance();
  		System.out.println("userList=" + BeanPrinter.getPrintString(userList));
  
          // TODO: auto-population of associations not implemented yet
  //        IContext context = new BaseContext();
  //        context.setValue(IPersistenceFactory.CTX_QUERY_NAME, "byGroup");
  //        context.setValue("groupId", new Integer(100));
  //        List group100UserList = (List) userListFactory.createInstance(context);
  //        System.out.println("group100UserList=" + BeanPrinter.getPrintString(userList));
      }
  }
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/src/java/org/apache/cornerstone/framework/demo/main/DemoMain.java
  
  Index: DemoMain.java
  ===================================================================
  package org.apache.cornerstone.framework.demo.main;
  
  import org.apache.log4j.PropertyConfigurator;
  import org.apache.cornerstone.framework.api.context.IContext;
  import org.apache.cornerstone.framework.api.service.IService;
  import org.apache.cornerstone.framework.bean.visitor.BeanPrinter;
  import org.apache.cornerstone.framework.context.BaseContext;
  import org.apache.cornerstone.framework.init.Cornerstone;
  import org.apache.cornerstone.framework.demo.bo.api.IA;
  import org.apache.cornerstone.framework.demo.bo.api.IX;
  import org.apache.cornerstone.framework.demo.bo.factory.api.IAFactory;
  import org.apache.cornerstone.framework.demo.bo.factory.api.IXFactory;
  import org.apache.cornerstone.framework.demo.service.DateService;
  
  public class DemoMain
  {
      public static final String REVISION = "$Revision: 1.1 $";
  
      public static void main(String[] args) throws Exception
      {
          // init log4j
          String log4jConfigFilePath = System.getProperty("log4j.configuration", "log4j.properties");
          PropertyConfigurator.configure(log4jConfigFilePath);
  
          // init Cornerstone
          Cornerstone.init();
  
          // ------------------------------------------------------------------------
          // Demo of calling services of the same class with different configurations
  
          // ServiceManager looks into
          // ${CORNERSTONE_RUNTIME_HOME}/registry/implementation/cornerstone.demo.service/cornerstone.demo.getDate.reg.properties
          // for the definition of this service
          String serviceName = "cornerstone.demo.getDate";
          IService service = Cornerstone.getServiceManager().createServiceByName(serviceName);
  
  		// call passing no values in context
  		// service will use its defaults
          IContext context = new BaseContext();
          String dateString = (String) service.invoke(context);
  		printDate(serviceName, dateString, context);
  
  		// call passing value of one of invoke_direct_inputs
          context = new BaseContext();
          context.setValue(DateService.INPUT_TIME_ZONE, "GMT-0800");	// San Jose, CA
          dateString = (String) service.invoke(context);
  		printDate(serviceName, dateString, context);
  
  		// call passing all values of invoke_direct_inputs
          context = new BaseContext();
  		context.setValue(DateService.INPUT_TIME_ZONE, "GMT+0800");	// Beijing, China
  		context.setValue(DateService.INPUT_DATE_FORMAT, DateService.DATE_FORMAT_SHORT);
  		dateString = (String) service.invoke(context);
  		printDate(serviceName, dateString, context);
  
  		// call another instance of DateService which has different configurations
          // ${CORNERSTONE_RUNTIME_HOME}/registry/implementation/cornerstone.demo.service/cornerstone.demo.getDate2.reg.properties
  		serviceName = "cornerstone.demo.getDate2";
  		service = Cornerstone.getServiceManager().createServiceByName(serviceName);
  		context = new BaseContext();
  		dateString = (String) service.invoke(context);
  		printDate(serviceName, dateString, context);
  
  		// call yet another instance of DateService which has different configurations
          // ${CORNERSTONE_RUNTIME_HOME}/registry/implementation/cornerstone.demo.service/cornerstone.demo.getDate3.reg.properties
  		serviceName = "cornerstone.demo.getDate3";
  		service = Cornerstone.getServiceManager().createServiceByName(serviceName);
  		context = new BaseContext();
  		dateString = (String) service.invoke(context);
  		printDate(serviceName, dateString, context);
  
          // --------------------------------------
          // Demo of calling services in a sequence
  
          // ${CORNERSTONE_RUNTIME_HOME}/registry/implementation/cornerstone.demo.service/cornerstone.demo.getDate1x1.reg.properties
          // Notice getDate10? has overwriting _.invokeDirect.inputs and _.invokeDirect.output and
          // "spread" the inputs and outputs around different names; otherwise the 3 getDate10?
          // services will share the same inputs and output, whihc is not desirable.  This
          // "spreading" is unnecessary if the services in the sequence are of different classes.
  		serviceName = "cornerstone.demo.getDate1x1";     // name of service controller
          service = Cornerstone.getServiceManager().createServiceByName(serviceName);
          context = new BaseContext();
          context.setValue("tz102", "GMT-0800");
          context.setValue("tz103", "GMT+0800");
          context.setValue("df103", DateService.DATE_FORMAT_SHORT);
          // s1 will use defaults for both dateFormat and timeZone
          // s2 will use "tz102" passed in and default for dateFormat
          // s3 will use "tz103" and "df103" passed in
          String lastDateString = (String) service.invoke(context);
          String date101 = (String) context.getValue("date101");
          System.out.println("date101: '" + date101 + "'");
          String date102 = (String) context.getValue("date102");
          System.out.println("date102: '" + date102 + "'");
          String date103 = (String) context.getValue("date103");
          System.out.println("date103: '" + date103 + "'");
  
          // ----------------------------------------------------------------------------
          // Demo of indirect creation of implementations of an interface in various ways
  
          // get the single implementation of an factory interface
          // ${CORNERSTONE_RUNTIME_HOME}/registry/implementation/...IAFactory/.reg.properties
  		IAFactory aFactory = (IAFactory) Cornerstone.getImplementationManager().createImplementation(IAFactory.class);
  		IA a = (IA) aFactory.createInstance();
  		String aPrintString = BeanPrinter.getPrintString(a);
  		System.out.println("a=" + aPrintString);
  
          // get the "a1_viaInstanceClassName" implementation variant of interface IA
          // This variant defines how an instance should be created by using "instance.className".
          // ${CORNERSTONE_RUNTIME_HOME}/registry/implementation/...IA/a1_viaInstanceClassName.reg.properties
          IA a1_viaInstanceClassName = (IA) Cornerstone.getImplementationManager().createImplementation(IA.class, "a1_viaInstanceClassName");
          String a1_viaInstanceClassNamePrintString = BeanPrinter.getPrintString(a1_viaInstanceClassName);
          System.out.println("a1_viaInstanceClassName=" + a1_viaInstanceClassNamePrintString);
  
          // get the "a1_viaFactoryClassName" implementation variant of interface IA
          // This variant defines how an instance should be created by using "factory.className".
          // ${CORNERSTONE_RUNTIME_HOME}/registry/implementation/...IA/a1_viaFactoryClassName.reg.properties
          IA a1_viaFactoryClassName = (IA) Cornerstone.getImplementationManager().createImplementation(IA.class, "a1_viaFactoryClassName");
          String a1_viaFactoryClassNamePrintString = BeanPrinter.getPrintString(a1_viaFactoryClassName);
          System.out.println("a1_viaFactoryClassName=" + a1_viaFactoryClassNamePrintString);
  
          // get the "a1_viaParentName" implementation variant of interface IA
          // This variant doesn't specify either instance.className or factory.className but gets that
          // from its parent (another implementation for the same interface) specified by "parent.name".
          // ${CORNERSTONE_RUNTIME_HOME}/registry/implementation/...IA/a1_viaParentName.reg.properties
          IA a1_viaParentName = (IA) Cornerstone.getImplementationManager().createImplementation(IA.class, "a1_viaParentName");
          String a1_viaParentNamePrintString = BeanPrinter.getPrintString(a1_viaParentName);
          System.out.println("a1_viaParentName=" + a1_viaParentNamePrintString);
  
          // ----------------------
          // Demo of an IoC Factory
  
          // First notice the demo.bo.api and demo.bo packages are completely independent of any framework
  
          // get the implementation variant "x1y1" of factory interface IXFactory and create an instance
          // the instance of X1 will be associated with an instance of Y1
          // ${CORNERSTONE_RUNTIME_HOME}/registry/implementation/...IXFactory/x1y1.reg.properties
          IXFactory xFactory = (IXFactory) Cornerstone.getImplementationManager().createImplementation(IXFactory.class, "x1y1");
          IX x1y1 = (IX) xFactory.createInstance();
          String x1y1PrintString = BeanPrinter.getPrintString(x1y1);
          System.out.println("x1y1=" + x1y1PrintString);
  
          // get the implementation variant "x1y2" of factory interface IXFactory and create an instance
          // the instance of X1 will be associated with an instance of Y2
          // ${CORNERSTONE_RUNTIME_HOME}/registry/implementation/...IXFactory/x1y2.reg.properties
          xFactory = (IXFactory) Cornerstone.getImplementationManager().createImplementation(IXFactory.class, "x1y2");
          IX x1y2 = (IX) xFactory.createInstance();
          String x1y2PrintString = BeanPrinter.getPrintString(x1y2);
          System.out.println("x1y2=" + x1y2PrintString);
  
          // get the implementation variant "x1y3" of factory interface IXFactory and create an instance
          // the instance of X1 will be associated with an instance of Y3
          // ${CORNERSTONE_RUNTIME_HOME}/registry/implementation/...IXFactory/x1y3.reg.properties
          xFactory = (IXFactory) Cornerstone.getImplementationManager().createImplementation(IXFactory.class, "x1y3");
          IX x1y3 = (IX) xFactory.createInstance();
          String x1y3PrintString = BeanPrinter.getPrintString(x1y3);
          System.out.println("x1y3=" + x1y3PrintString);
      }
  
      protected static void printDate(String serviceName, String dateString, IContext context)
      {
      	String timeZoneName = DateService.INPUT_TIME_ZONE;
      	String timeZoneValue = (String) context.getValue(timeZoneName);
      	String dateFormatName = DateService.INPUT_DATE_FORMAT;
      	String dateFormatValue = (String) context.getValue(dateFormatName);
  
      	System.out.println(
      		serviceName +
      		" (" + timeZoneName + "=" + timeZoneValue + ", " +
      		dateFormatName + "=" + dateFormatValue + "):\n" +
      		"    " + dateString
      	);
      }
  }
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/hsqldb/lib/hsqldb.jar
  
  	<<Binary file>>
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/registry/implementation/org.apache.cornerstone.framework.demo.bo.factory.api.IAFactory/.reg.properties
  
  Index: .reg.properties
  ===================================================================
  _.instance.className=org.apache.cornerstone.framework.demo.bo.factory.AFactory
  
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/src/java/org/apache/cornerstone/framework/demo/bo/factory/XFactory.java
  
  Index: XFactory.java
  ===================================================================
  package org.apache.cornerstone.framework.demo.bo.factory;
  
  import org.apache.cornerstone.framework.demo.bo.factory.api.IXFactory;
  import org.apache.cornerstone.framework.factory.ioc.InversionOfControlFactory;
  
  public class XFactory extends InversionOfControlFactory implements IXFactory
  {
      public static final String REVISION = "$Revision: 1.1 $";
  }
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/src/java/org/apache/cornerstone/framework/demo/bo/factory/AFactory.java
  
  Index: AFactory.java
  ===================================================================
  package org.apache.cornerstone.framework.demo.bo.factory;
  
  import org.apache.cornerstone.framework.api.factory.CreationException;
  import org.apache.cornerstone.framework.constant.Constant;
  import org.apache.cornerstone.framework.demo.bo.api.IA;
  import org.apache.cornerstone.framework.demo.bo.api.IB;
  import org.apache.cornerstone.framework.demo.bo.factory.api.IAFactory;
  import org.apache.cornerstone.framework.factory.BaseFactory;
  
  public class AFactory extends BaseFactory implements IAFactory
  {
  	public static final String REVISION = "$Revision: 1.1 $";
  
  	public static final String CONFIG_A_INSTANCE_CLASS_NAME = Constant.PROPERTY_DOT + "a" + Constant.DOT + Constant.INSTANCE_CLASS_NAME;
  	public static final String CONFIG_B_INSTANCE_CLASS_NAME = Constant.PROPERTY_DOT + "b" + Constant.DOT + Constant.INSTANCE_CLASS_NAME;
  
  	public static final String CONFIG_PARAMS = CONFIG_A_INSTANCE_CLASS_NAME + "," + CONFIG_B_INSTANCE_CLASS_NAME;
  
  	/* (non-Javadoc)
  	 * @see org.apache.cornerstone.framework.api.factory.IFactory#createInstance()
  	 */
  	public Object createInstance() throws CreationException
  	{
  		try
  		{
  			String aClassName = getConfigProperty(CONFIG_A_INSTANCE_CLASS_NAME);
  			IA a = (IA) Class.forName(aClassName).newInstance();
  
  			String bClassName = getConfigProperty(CONFIG_B_INSTANCE_CLASS_NAME);
  			IB b = (IB) Class.forName(bClassName).newInstance();
  
  			a.setB(b);
  
  			return a;
  		}
  		catch (Exception e)
  		{
  			throw new CreationException(e);
  		}
  	}
  }
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/src/java/org/apache/cornerstone/framework/demo/bo/factory/Y2Factory.java
  
  Index: Y2Factory.java
  ===================================================================
  package org.apache.cornerstone.framework.demo.bo.factory;
  
  import org.apache.cornerstone.framework.api.factory.CreationException;
  import org.apache.cornerstone.framework.factory.BaseFactory;
  import org.apache.cornerstone.framework.demo.bo.Y2;
  
  public class Y2Factory extends BaseFactory
  {
      public static final String REVISION = "$Revision: 1.1 $";
  
  	/* (non-Javadoc)
  	 * @see org.apache.cornerstone.framework.api.factory.IFactory#createInstance()
  	 */
  	public Object createInstance() throws CreationException
  	{
  		return new Y2();
  	}
  }
  
  
  1.1                  jakarta-jetspeed-2/cornerstone-demo/registry/implementation/org.apache.cornerstone.framework.demo.bo.api.IY/y3.reg.properties
  
  Index: y3.reg.properties
  ===================================================================
  _.instance.className=org.apache.cornerstone.framework.demo.bo.Y3
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jetspeed-dev-help@jakarta.apache.org


Mime
View raw message