Skip to Content.
Sympa Menu

notify-dpml - r1475 - in trunk/main: depot/library/src/main/net/dpml/library/info depot/tools/builder/src/main/net/dpml/tools depot/tools/builder/src/main/net/dpml/tools/tasks lang/module/etc metro metro/runtime metro/state/impl metro/test planet/process station station/server transit

notify-dpml AT lists.ibiblio.org

Subject: DPML Notify

List archive

Chronological Thread  
  • From: mcconnell at BerliOS <mcconnell AT mail.berlios.de>
  • To: notify-dpml AT lists.ibiblio.org
  • Subject: r1475 - in trunk/main: depot/library/src/main/net/dpml/library/info depot/tools/builder/src/main/net/dpml/tools depot/tools/builder/src/main/net/dpml/tools/tasks lang/module/etc metro metro/runtime metro/state/impl metro/test planet/process station station/server transit
  • Date: Tue, 30 May 2006 04:05:18 +0200

Author: mcconnell
Date: 2006-05-30 04:04:21 +0200 (Tue, 30 May 2006)
New Revision: 1475

Added:
trunk/main/depot/tools/builder/src/main/net/dpml/tools/package.html
trunk/main/metro/runtime/build.xml
trunk/main/metro/state/impl/build.xml
trunk/main/planet/process/module.xml
Removed:

trunk/main/depot/library/src/main/net/dpml/library/info/JarTypeDirective.java
Modified:
trunk/main/depot/library/src/main/net/dpml/library/info/LibraryDecoder.java
trunk/main/depot/tools/builder/src/main/net/dpml/tools/tasks/BuildTask.java
trunk/main/lang/module/etc/module.xsd
trunk/main/metro/module.xml
trunk/main/metro/test/build.xml
trunk/main/station/module.xml
trunk/main/station/server/build.xml
trunk/main/transit/module.xml
Log:
removal of production info from project definition (reverting to build.xml
customization)

Deleted:
trunk/main/depot/library/src/main/net/dpml/library/info/JarTypeDirective.java
===================================================================
---
trunk/main/depot/library/src/main/net/dpml/library/info/JarTypeDirective.java
2006-05-29 15:53:56 UTC (rev 1474)
+++
trunk/main/depot/library/src/main/net/dpml/library/info/JarTypeDirective.java
2006-05-30 02:04:21 UTC (rev 1475)
@@ -1,133 +0,0 @@
-/*
- * Copyright 2006 Stephen J. McConnell
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
- * implied.
- *
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package net.dpml.library.info;
-
-import java.util.Arrays;
-
-import net.dpml.util.ElementHelper;
-
-import org.w3c.dom.Element;
-
-/**
- * Jar file production criteria.
- *
- * @author <a href="@PUBLISHER-URL@">@PUBLISHER-NAME@</a>
- * @version @PROJECT-VERSION@
- */
-public class JarTypeDirective extends TypeDirective
-{
- private final String[] m_rmicIncludes;
- private final String[] m_rmicExcludes;
-
- /**
- * Creation of a new jar type directive.
- * @param element DOM element defining the type
- * @param alias the alias production policy
- */
- public JarTypeDirective( Element element, boolean alias )
- {
- super( element, "jar", alias );
-
- Element src = ElementHelper.getChild( element, "src" );
- if( null != src )
- {
- throw new UnsupportedOperationException( "src" );
- }
- Element rmic = ElementHelper.getChild( element, "rmic" );
- if( null != rmic )
- {
- Element[] includes = ElementHelper.getChildren( rmic, "include"
);
- m_rmicIncludes = new String[ includes.length ];
- for( int i=0; i<includes.length; i++ )
- {
- Element include = includes[i];
- String name = ElementHelper.getAttribute( include, "name" );
- m_rmicIncludes[i] = name;
- }
- Element[] excludes = ElementHelper.getChildren( rmic, "exclude"
);
- m_rmicExcludes = new String[ excludes.length ];
- for( int i=0; i<excludes.length; i++ )
- {
- Element exclude = excludes[i];
- String name = ElementHelper.getAttribute( exclude, "name" );
- m_rmicExcludes[i] = name;
- }
- }
- else
- {
- m_rmicIncludes = new String[0];
- m_rmicExcludes = new String[0];
- }
- }
-
- /**
- * Return the rmic include names.
- * @return the include array
- */
- public String[] getRMICIncludes()
- {
- return m_rmicIncludes;
- }
-
- /**
- * Return the rmic include names.
- * @return the include array
- */
- public String[] getRMICExcludes()
- {
- return m_rmicExcludes;
- }
-
- /**
- * Compare this object with another for equality.
- * @param other the other object
- * @return true if equal
- */
- public boolean equals( Object other )
- {
- if( super.equals( other ) && ( other instanceof JarTypeDirective ) )
- {
- JarTypeDirective object = (JarTypeDirective) other;
- if( !Arrays.equals( m_rmicIncludes, object.m_rmicIncludes ) )
- {
- return false;
- }
- else
- {
- return Arrays.equals( m_rmicExcludes, object.m_rmicExcludes
);
- }
- }
- else
- {
- return false;
- }
- }
-
- /**
- * Compute the hash value.
- * @return the hascode value
- */
- public int hashCode()
- {
- int hash = super.hashCode();
- hash ^= hashArray( m_rmicIncludes );
- hash ^= hashArray( m_rmicExcludes );
- return hash;
- }
-}

Modified:
trunk/main/depot/library/src/main/net/dpml/library/info/LibraryDecoder.java
===================================================================
---
trunk/main/depot/library/src/main/net/dpml/library/info/LibraryDecoder.java
2006-05-29 15:53:56 UTC (rev 1474)
+++
trunk/main/depot/library/src/main/net/dpml/library/info/LibraryDecoder.java
2006-05-30 02:04:21 UTC (rev 1475)
@@ -668,84 +668,6 @@
}
}

- /*
- private DataDirective[] buildDataDirectives( Element element ) throws
Exception
- {
- Element[] children = ElementHelper.getChildren( element );
- DataDirective[] data = new DataDirective[ children.length ];
- for( int i=0; i<children.length; i++ )
- {
- Element child = children[i];
- data[i] = buildDataDirective( child );
- }
- return data;
- }
-
- private DataDirective buildDataDirective( Element element ) throws
Exception
- {
- TypeInfo info = element.getSchemaTypeInfo();
- String namespace = info.getTypeNamespace();
- if( null == namespace )
- {
- throw new NullPointerException( "namespace" );
- }
- else if( MODULE_XSD_URI.equals( namespace ) )
- {
- String tag = element.getTagName();
- //if( FiltersDirective.KEY.equals( tag ) )
- //{
- // return buildFiltersDirective( element );
- //}
- //else
-
- // TODO: rework all of the following to allow for arbitrary
process
- // parameters
-
- if( RMICDirective.KEY.equals( tag ) )
- {
- return buildRMICDirective( element );
- }
- else
- {
- final String error =
- "Datatype not recognized.";
- throw new DecodingException( element, error );
- }
- }
- else
- {
- return new DataDirective( element );
- }
- }
-
- private RMICDirective buildRMICDirective( Element element ) throws
Exception
- {
- PatternDirective[] patterns = buildPatternDirectives( element );
- return new RMICDirective( patterns );
- }
-
- private PatternDirective[] buildPatternDirectives( Element element )
throws Exception
- {
- Element[] children = ElementHelper.getChildren( element );
- PatternDirective[] patterns = new PatternDirective[ children.length
];
- for( int i=0; i<children.length; i++ )
- {
- Element child = children[i];
- String tag = child.getTagName();
- String name = ElementHelper.getAttribute( child, "name" );
- if( "include".equals( tag ) )
- {
- patterns[i] = new IncludePatternDirective( name );
- }
- else
- {
- patterns[i] = new ExcludePatternDirective( name );
- }
- }
- return patterns;
- }
- */
-
private FilterDirective[] buildFilterDirectives( Element element )
throws Exception
{
if( null == element )
@@ -787,49 +709,6 @@
}
}

- /*
- private FiltersDirective buildFiltersDirective( Element element ) throws
Exception
- {
- if( null == element )
- {
- return new FiltersDirective( new FilterDirective[0] );
- }
- else
- {
- Element[] children = ElementHelper.getChildren( element );
- FilterDirective[] filters = new FilterDirective[ children.length
];
- for( int i=0; i<children.length; i++ )
- {
- Element child = children[i];
- String token = ElementHelper.getAttribute( child, "token" );
- if( "filter".equals( child.getTagName() ) )
- {
- String value = ElementHelper.getAttribute( child,
"value" );
- filters[i] = new SimpleFilterDirective( token, value );
- }
- else if( "feature".equals( child.getTagName() ) )
- {
- String id = ElementHelper.getAttribute( child, "id" );
- Feature feature = Feature.parse( id );
- String ref = ElementHelper.getAttribute( child, "ref" );
- String type = ElementHelper.getAttribute( child, "type"
);
- boolean alias = ElementHelper.getBooleanAttribute(
child, "alias" );
- filters[i] = new FeatureFilterDirective( token, ref,
feature, type, alias );
- }
- else
- {
- final String error =
- "Element name not recognized ["
- + child.getTagName()
- + "] (expecting 'filter').";
- throw new DecodingException( element, error );
- }
- }
- return new FiltersDirective( filters );
- }
- }
- */
-
private DataDirective[] buildDataTypes( Element element ) throws
Exception
{
if( null == element )
@@ -870,11 +749,6 @@
final Properties properties = getProperties( element );
return new TypeDirective( id, alias, properties );
}
- else if( "jar".equals( typeName ) )
- {
- final boolean alias = getAliasFlag( element );
- return new JarTypeDirective( element, alias );
- }
else
{
final String error =

Added: trunk/main/depot/tools/builder/src/main/net/dpml/tools/package.html
===================================================================
--- trunk/main/depot/tools/builder/src/main/net/dpml/tools/package.html
2006-05-29 15:53:56 UTC (rev 1474)
+++ trunk/main/depot/tools/builder/src/main/net/dpml/tools/package.html
2006-05-30 02:04:21 UTC (rev 1475)
@@ -0,0 +1,8 @@
+
+<body>
+
+<p>
+Primary interfaces defining a build context and processor.
+</p>
+
+</body>

Modified:
trunk/main/depot/tools/builder/src/main/net/dpml/tools/tasks/BuildTask.java
===================================================================
---
trunk/main/depot/tools/builder/src/main/net/dpml/tools/tasks/BuildTask.java
2006-05-29 15:53:56 UTC (rev 1474)
+++
trunk/main/depot/tools/builder/src/main/net/dpml/tools/tasks/BuildTask.java
2006-05-30 02:04:21 UTC (rev 1475)
@@ -23,7 +23,6 @@
import net.dpml.library.Resource;
import net.dpml.library.Type;
import net.dpml.library.info.Scope;
-import net.dpml.library.info.JarTypeDirective;

import net.dpml.tools.Context;

@@ -66,27 +65,6 @@
task.execute();
}

- // resolve rmic selection
-
- Resource resource = context.getResource();
- if( resource.isa( "jar" ) )
- {
- Type type = resource.getType( "jar" );
- if( type instanceof JarTypeDirective )
- {
- JarTypeDirective directive = (JarTypeDirective) type;
- String[] includes = directive.getRMICIncludes();
- String[] excludes = directive.getRMICExcludes();
- RMICTask rmicTask = new RMICTask( context );
- Project project = context.getProject();
- rmicTask.setProject( project );
- rmicTask.setIncludes( includes );
- rmicTask.setExcludes( excludes );
- rmicTask.init();
- rmicTask.execute();
- }
- }
-
// conditionaly compile test classes

File source = context.getTargetBuildTestDirectory();

Modified: trunk/main/lang/module/etc/module.xsd
===================================================================
--- trunk/main/lang/module/etc/module.xsd 2006-05-29 15:53:56 UTC (rev
1474)
+++ trunk/main/lang/module/etc/module.xsd 2006-05-30 02:04:21 UTC (rev
1475)
@@ -15,15 +15,7 @@
<element name="resource" type="this:ResourceType"/>
<element name="property" type="this:PropertyType"/>
<element name="type" type="common:AbstractType"
substitutionGroup="common:type"/>
-
- <element name="data" type="this:InstructionSetType"/>
-
- <!--<element name="abstract-filter" type="this:AbstractFilter"/>
- <element name="filters" type="this:FiltersType"
substitutionGroup="common:data"/>
- <element name="filter" type="this:Filter"
substitutionGroup="this:abstract-filter"/>
- <element name="feature" type="this:Feature"
substitutionGroup="this:abstract-filter"/>-->
- <!--<element name="rmic" type="this:RMICType"
substitutionGroup="common:data"/>-->
-
+
<complexType name="LibraryType">
<all>
<element name="imports" type="this:ImportsType" minOccurs="0"
maxOccurs="1"/>
@@ -103,10 +95,6 @@
<complexType name="TypesType">
<choice minOccurs="0" maxOccurs="unbounded">
<element ref="common:type"/>
- <!--
- <element name="type" type="common:AbstractType"/>
- <element name="data" type="anyType"/>
- -->
</choice>
</complexType>

@@ -230,27 +218,16 @@
</restriction>
</simpleType>

- <!-- new stuff-->
-
- <complexType name="InstructionSetType">
- <sequence>
- <element name="data" type="this:DataType" minOccurs="0"
maxOccurs="unbounded"/>
- </sequence>
- </complexType>
-
- <complexType name="DataType" abstract="true">
- <attribute name="id" type="string" use="required"/>
- </complexType>
-
- <!-- existing process stuff-->
+ <!-- jar type -->

+ <!--
<complexType name="jar">
<complexContent>
<extension base="common:AbstractType">
- <sequence>
- <element name="src" type="this:PatternCollectionType"
minOccurs="0" maxOccurs="1"/>
- <element name="rmic" type="this:PatternCollectionType"
minOccurs="0" maxOccurs="1"/>
- </sequence>
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <element name="include" type="this:IncludePatternType"/>
+ <element name="exclude" type="this:ExcludePatternType"/>
+ </choice>
<attribute name="compress" type="boolean" default="true"/>
<attribute name="index" type="boolean" default="true"/>
</extension>
@@ -279,6 +256,7 @@
</extension>
</simpleContent>
</complexType>
-
+ -->
+
</schema>


Modified: trunk/main/metro/module.xml
===================================================================
--- trunk/main/metro/module.xml 2006-05-29 15:53:56 UTC (rev 1474)
+++ trunk/main/metro/module.xml 2006-05-30 02:04:21 UTC (rev 1475)
@@ -12,11 +12,7 @@

<project name="dpml-state-impl" basedir="state/impl">
<types>
- <type id="jar" xsi:type="jar">
- <rmic>
- <include name="**/DefaultStateListener.class"/>
- </rmic>
- </type>
+ <type id="jar"/>
</types>
<dependencies>
<runtime>
@@ -112,17 +108,7 @@
</description>
</info>
<types>
- <type id="jar" xsi:type="jar">
- <rmic>
- <include name="**/DefaultComponentModel.class"/>
- <include name="**/DefaultContextModel.class"/>
- <include name="**/DefaultComponentHandler.class"/>
- <include name="**/DefaultProvider.class"/>
- <include name="**/DefaultComponentHandler.class"/>
- <include name="**/CompositionHandler.class"/>
- <include name="**/ValueHandler.class"/>
- </rmic>
- </type>
+ <type id="jar"/>
<type xsi:type="part:plugin" alias="true"
class="net.dpml.metro.runtime.CompositionController">
<part:param class="net.dpml.component.InitialContext"/>
</type>
@@ -181,11 +167,7 @@
<property name="project.javadoc.exclude" value="true"/>
</properties>
<types>
- <type id="jar" xsi:type="jar">
- <rmic>
- <include name="**/ManagedComponent#DefaultMonitor.class"/>
- </rmic>
- </type>
+ <type id="jar"/>
</types>
<dependencies>
<runtime>

Added: trunk/main/metro/runtime/build.xml
===================================================================
--- trunk/main/metro/runtime/build.xml 2006-05-29 15:53:56 UTC (rev 1474)
+++ trunk/main/metro/runtime/build.xml 2006-05-30 02:04:21 UTC (rev 1475)
@@ -0,0 +1,38 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+ Copyright 2004 Stephen J McConnell
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied.
+
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+
+<project name="dpml-state-impl"
+ xmlns:transit="antlib:net.dpml.transit"
+ default="install">
+
+ <transit:import uri="local:template:dpml/tools/standard"/>
+
+ <target name="build" depends="standard.build">
+ <rmic base="${project.target.classes.main.dir}"
classpathref="project.compile.path">
+ <include name="**/DefaultComponentModel.class"/>
+ <include name="**/DefaultContextModel.class"/>
+ <include name="**/DefaultComponentHandler.class"/>
+ <include name="**/DefaultProvider.class"/>
+ <include name="**/DefaultComponentHandler.class"/>
+ <include name="**/CompositionHandler.class"/>
+ <include name="**/ValueHandler.class"/>
+ </rmic>
+ </target>
+
+</project>

Added: trunk/main/metro/state/impl/build.xml
===================================================================
--- trunk/main/metro/state/impl/build.xml 2006-05-29 15:53:56 UTC (rev
1474)
+++ trunk/main/metro/state/impl/build.xml 2006-05-30 02:04:21 UTC (rev
1475)
@@ -0,0 +1,33 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+ Copyright 2004 Stephen J McConnell
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied.
+
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+
+<project name="dpml-state-impl"
+ xmlns:transit="antlib:net.dpml.transit"
+ default="install">
+
+ <transit:import uri="local:template:dpml/tools/standard"/>
+
+ <target name="build" depends="standard.build">
+ <rmic base="${project.target.classes.main.dir}"
+ classpathref="project.compile.path">
+ <include name="**/DefaultStateListener.class"/>
+ </rmic>
+ </target>
+
+</project>

Modified: trunk/main/metro/test/build.xml
===================================================================
--- trunk/main/metro/test/build.xml 2006-05-29 15:53:56 UTC (rev 1474)
+++ trunk/main/metro/test/build.xml 2006-05-30 02:04:21 UTC (rev 1475)
@@ -26,6 +26,11 @@

<target name="build" depends="standard.build">

+ <rmic base="${project.target.classes.main.dir}"
+ classpathref="project.compile.path">
+ <include name="**/ManagedComponent#DefaultMonitor.class"/>
+ </rmic>
+
<x:plugin uri="link:part:dpml/metro/dpml-metro-tools"/>

<!-- create the test component types -->

Added: trunk/main/planet/process/module.xml
===================================================================
--- trunk/main/planet/process/module.xml 2006-05-29 15:53:56 UTC (rev
1474)
+++ trunk/main/planet/process/module.xml 2006-05-30 02:04:21 UTC (rev
1475)
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<module name="process"
+ xmlns="artifact:xsd:dpml/lang/dpml-module#1.0"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; >
+
+ <project name="dpml-process-info" basedir="info">
+ <types>
+ <type id="xsd"/>
+ <type id="jar"/>
+ </types>
+ <dependencies>
+ <runtime>
+ <include ref="dpml/transit/dpml-transit-main"/>
+ </runtime>
+ <test>
+ <include ref="ant/ant-junit"/>
+ </test>
+ </dependencies>
+ <filters>
+ <feature token="PROJECT-XSD-URI" id="uri" type="xsd"/>
+ <feature token="PART-XSD-URI" id="uri" type="xsd"
ref="dpml/lang/dpml-part"/>
+ <feature token="COMMON-XSD-URI" id="uri" type="xsd"
ref="dpml/lang/dpml-common"/>
+ </filters>
+ </project>
+
+</module>

Modified: trunk/main/station/module.xml
===================================================================
--- trunk/main/station/module.xml 2006-05-29 15:53:56 UTC (rev 1474)
+++ trunk/main/station/module.xml 2006-05-30 02:04:21 UTC (rev 1475)
@@ -86,13 +86,7 @@
<property name="project.test.fork" value="true"/>
</properties>
<types>
- <type id="jar" xsi:type="jar">
- <rmic>
- <include name="**/RemoteApplicationRegistry.class"/>
- <include name="**/RemoteApplication.class"/>
- <include name="**/RemoteStation.class"/>
- </rmic>
- </type>
+ <type id="jar"/>
<type xsi:type="part:plugin"
class="net.dpml.station.server.StationServerPlugin" alias="true"/>
</types>
<dependencies>

Modified: trunk/main/station/server/build.xml
===================================================================
--- trunk/main/station/server/build.xml 2006-05-29 15:53:56 UTC (rev 1474)
+++ trunk/main/station/server/build.xml 2006-05-30 02:04:21 UTC (rev 1475)
@@ -8,6 +8,14 @@

<available property="dpml.exe.available"
file="${dpml.system}/bin/server/dpml.exe"/>

+ <target name="build" depends="standard.build">
+ <rmic base="${project.target.classes.main.dir}"
classpathref="project.compile.path">
+ <include name="**/RemoteApplicationRegistry.class"/>
+ <include name="**/RemoteApplication.class"/>
+ <include name="**/RemoteStation.class"/>
+ </rmic>
+ </target>
+
<target name="install" depends="bin,standard.install">
<copy todir="${dpml.system}" preservelastmodified="true"
overwrite="true">
<fileset dir="target">

Modified: trunk/main/transit/module.xml
===================================================================
--- trunk/main/transit/module.xml 2006-05-29 15:53:56 UTC (rev 1474)
+++ trunk/main/transit/module.xml 2006-05-30 02:04:21 UTC (rev 1475)
@@ -11,7 +11,8 @@
<project name="dpml-transit-console" basedir="console">
<types>
<type id="jar"/>
- <type xsi:type="part:plugin"
class="net.dpml.transit.console.TransitConsoleHandler" alias="true"/>
+ <type xsi:type="part:plugin"
+ class="net.dpml.transit.console.TransitConsoleHandler" alias="true"/>
</types>
<dependencies>
<runtime>




  • r1475 - in trunk/main: depot/library/src/main/net/dpml/library/info depot/tools/builder/src/main/net/dpml/tools depot/tools/builder/src/main/net/dpml/tools/tasks lang/module/etc metro metro/runtime metro/state/impl metro/test planet/process station station/server transit, mcconnell at BerliOS, 05/29/2006

Archive powered by MHonArc 2.6.24.

Top of Page