Skip to Content.
Sympa Menu

notify-dpml - svn commit: r2079 - in development/laboratory/plus: . standard/builder/src/main/net/dpml/metro/builder/impl standard/part/src/main/net/dpml/metro/catalog standard/part/src/main/net/dpml/metro/meta standard/part/src/main/net/dpml/metro/type test/example/impl test/example/part

notify-dpml AT lists.ibiblio.org

Subject: DPML Notify

List archive

Chronological Thread  
  • From: mcconnell AT dpml.net
  • To: notify-dpml AT lists.ibiblio.org
  • Subject: svn commit: r2079 - in development/laboratory/plus: . standard/builder/src/main/net/dpml/metro/builder/impl standard/part/src/main/net/dpml/metro/catalog standard/part/src/main/net/dpml/metro/meta standard/part/src/main/net/dpml/metro/type test/example/impl test/example/part
  • Date: Tue, 15 Mar 2005 04:04:17 -0500

Author: mcconnell AT dpml.net
Date: Tue Mar 15 04:04:17 2005
New Revision: 2079

Added:

development/laboratory/plus/standard/builder/src/main/net/dpml/metro/builder/impl/CatalogTask.java
- copied, changed from r2078,
development/laboratory/plus/standard/builder/src/main/net/dpml/metro/builder/impl/RegistryTask.java

development/laboratory/plus/standard/part/src/main/net/dpml/metro/catalog/Catalog.java
- copied, changed from r2078,
development/laboratory/plus/standard/part/src/main/net/dpml/metro/catalog/Registry.java

development/laboratory/plus/standard/part/src/main/net/dpml/metro/catalog/CatalogNotFoundException.java
- copied, changed from r2078,
development/laboratory/plus/standard/part/src/main/net/dpml/metro/catalog/RegistryNotFoundException.java

development/laboratory/plus/standard/part/src/main/net/dpml/metro/catalog/CatalogRuntimeException.java
- copied, changed from r2078,
development/laboratory/plus/standard/part/src/main/net/dpml/metro/catalog/RegistryRuntimeException.java
development/laboratory/plus/standard/part/src/main/net/dpml/metro/type/
- copied from r2077,
development/laboratory/plus/standard/part/src/main/net/dpml/metro/meta/
Removed:

development/laboratory/plus/standard/builder/src/main/net/dpml/metro/builder/impl/RegistryTask.java

development/laboratory/plus/standard/part/src/main/net/dpml/metro/catalog/Registry.java

development/laboratory/plus/standard/part/src/main/net/dpml/metro/catalog/RegistryNotFoundException.java

development/laboratory/plus/standard/part/src/main/net/dpml/metro/catalog/RegistryRuntimeException.java
development/laboratory/plus/standard/part/src/main/net/dpml/metro/meta/
Modified:
development/laboratory/plus/build.xml
development/laboratory/plus/index.xml

development/laboratory/plus/standard/builder/src/main/net/dpml/metro/builder/impl/ComponentModelBuilderTask.java

development/laboratory/plus/standard/builder/src/main/net/dpml/metro/builder/impl/ComponentTypeBuilderTask.java

development/laboratory/plus/standard/builder/src/main/net/dpml/metro/builder/impl/TypeBuilder.java

development/laboratory/plus/standard/builder/src/main/net/dpml/metro/builder/impl/antlib.xml

development/laboratory/plus/standard/part/src/main/net/dpml/metro/catalog/ComponentTypeHandler.java

development/laboratory/plus/standard/part/src/main/net/dpml/metro/catalog/TypeEntry.java

development/laboratory/plus/standard/part/src/main/net/dpml/metro/catalog/TypeHandler.java

development/laboratory/plus/standard/part/src/main/net/dpml/metro/catalog/TypeReference.java

development/laboratory/plus/standard/part/src/main/net/dpml/metro/type/DependencyDescriptor.java

development/laboratory/plus/standard/part/src/main/net/dpml/metro/type/InfoDescriptor.java

development/laboratory/plus/standard/part/src/main/net/dpml/metro/type/PartDescriptor.java

development/laboratory/plus/standard/part/src/main/net/dpml/metro/type/Type.java
development/laboratory/plus/test/example/impl/build.xml
development/laboratory/plus/test/example/part/build.xml
Log:
registry --> catalog

Modified: development/laboratory/plus/build.xml
==============================================================================
--- development/laboratory/plus/build.xml (original)
+++ development/laboratory/plus/build.xml Tue Mar 15 04:04:17 2005
@@ -6,7 +6,7 @@
<transit:import uri="artifact:template:dpml/magic/reactor"/>

<target name="patch">
- <replace token="net.dpml.metro.meta" value="net.dpml.metro.type"
includes="**/*.java" dir="."/>
+ <replace token="RegistryNotFound" value="CatalogNotFound"
includes="**/*.java" dir="."/>
</target>

</project>

Modified: development/laboratory/plus/index.xml
==============================================================================
--- development/laboratory/plus/index.xml (original)
+++ development/laboratory/plus/index.xml Tue Mar 15 04:04:17 2005
@@ -154,7 +154,7 @@
<status>SNAPSHOT</status>
<types>
<type>jar</type>
- <type>registry</type>
+ <type>catalog</type>
</types>
</info>
<dependencies>

Copied:
development/laboratory/plus/standard/builder/src/main/net/dpml/metro/builder/impl/CatalogTask.java
(from r2078,
development/laboratory/plus/standard/builder/src/main/net/dpml/metro/builder/impl/RegistryTask.java)
==============================================================================
---
development/laboratory/plus/standard/builder/src/main/net/dpml/metro/builder/impl/RegistryTask.java
(original)
+++
development/laboratory/plus/standard/builder/src/main/net/dpml/metro/builder/impl/CatalogTask.java
Tue Mar 15 04:04:17 2005
@@ -34,9 +34,9 @@
import java.util.LinkedList;
import java.util.ArrayList;

-import net.dpml.metro.meta.Type;
+import net.dpml.metro.type.Type;

-import net.dpml.metro.catalog.Registry;
+import net.dpml.metro.catalog.Catalog;
import net.dpml.metro.catalog.TypeEntry;

import net.dpml.metro.builder.impl.TypeBuilder;
@@ -58,18 +58,17 @@
import org.apache.tools.ant.DynamicElementNS;

/**
- * Task that handles the construction of registry of type entries.
+ * Task that handles the construction of catalogof type entries.
*
* @author <a href="mailto:dev-dpml AT lists.ibiblio.org";>The Digital Product
Meta Library</a>
* @version $Revision: 1.2 $ $Date: 2004/03/17 10:30:09 $
*/
-public class RegistryTask extends ProjectTask implements DynamicElementNS
+public class CatalogTask extends ProjectTask implements DynamicElementNS
{
private List m_builders = new LinkedList();

public TypeBuilder createType()
{
- System.out.println( "# new registry entry" );
Project project = getProject();
ComponentTypeBuilderTask builder = new ComponentTypeBuilderTask();
builder.setTaskName( "type" );
@@ -162,16 +161,16 @@
File classes = getContext().getClassesDirectory();
path.createPathElement().setLocation( classes );
ClassLoader classloader = new AntClassLoader( project, path );
- Registry registry = buildRegistry( classloader );
+ Catalog catalog = buildCatalog( classloader );
File file = getOutputFile();
try
{
- SerializableObjectHelper.write( registry, file );
+ SerializableObjectHelper.write( catalog, file );
}
catch( IOException ioe )
{
final String error =
- "Internal error while attempting to write registry to ["
+ "Internal error while attempting to write catalog to the file
["
+ file
+ "]";
throw new BuildException( error, ioe, getLocation() );
@@ -180,8 +179,8 @@

private File getOutputFile()
{
- File dir = getContext().getDeliverablesDirectory( "registry" );
- String filename = getDefinition().getFilename( "registry" );
+ File dir = getContext().getDeliverablesDirectory(
Catalog.ARTIFACT_TYPE );
+ String filename = getDefinition().getFilename( Catalog.ARTIFACT_TYPE
);
File file = new File( dir, filename );
File parent = file.getParentFile();
if( !parent.exists() )
@@ -191,7 +190,7 @@
return file;
}

- private Registry buildRegistry( ClassLoader classloader )
+ private Catalog buildCatalog( ClassLoader classloader )
{
TypeEntry[] entries = buildTypeEntries( classloader );

@@ -199,13 +198,12 @@
URI[] spi = filter( api, createURISequence( ResourceRef.SPI ) );
URI[] impl = filter( combine( api, spi ), createURISequence(
ResourceRef.IMPL ) );

- URI uri = getDefinition().getArtifactURI( "registry" );
- return new Registry( uri, api, spi, impl, entries );
+ URI uri = getDefinition().getArtifactURI( Catalog.ARTIFACT_TYPE );
+ return new Catalog( uri, api, spi, impl, entries );
}

private TypeEntry[] buildTypeEntries( ClassLoader classloader )
{
- System.out.println( "# building registry entries" );
TypeBuilder[] builders = (TypeBuilder[]) m_builders.toArray( new
TypeBuilder[0] );
TypeEntry[] entries = new TypeEntry[ builders.length ];
for( int i=0; i<builders.length; i++ )

Modified:
development/laboratory/plus/standard/builder/src/main/net/dpml/metro/builder/impl/ComponentModelBuilderTask.java
==============================================================================
---
development/laboratory/plus/standard/builder/src/main/net/dpml/metro/builder/impl/ComponentModelBuilderTask.java
(original)
+++
development/laboratory/plus/standard/builder/src/main/net/dpml/metro/builder/impl/ComponentModelBuilderTask.java
Tue Mar 15 04:04:17 2005
@@ -44,15 +44,15 @@

import net.dpml.metro.control.BadStrategyException;

-import net.dpml.metro.meta.ComponentPart;
-import net.dpml.metro.meta.PartDescriptor;
-import net.dpml.metro.meta.Type;
+import net.dpml.metro.type.ComponentPart;
+import net.dpml.metro.type.PartDescriptor;
+import net.dpml.metro.type.Type;

-import net.dpml.metro.catalog.Registry;
+import net.dpml.metro.catalog.Catalog;
import net.dpml.metro.catalog.TypeReference;
import net.dpml.metro.catalog.TypeHandler;
import net.dpml.metro.catalog.TypeNotFoundException;
-import net.dpml.metro.catalog.RegistryNotFoundException;
+import net.dpml.metro.catalog.CatalogNotFoundException;
import net.dpml.metro.catalog.ComponentTypeHandler;

import net.dpml.magic.tasks.ProjectTask;
@@ -155,7 +155,7 @@
* @exception Exception if a construction error occurs
*/
public Part buildPart( ClassLoader classloader, PartDescriptor
descriptor )
- throws IntrospectionException, IOException, ClassNotFoundException,
RegistryNotFoundException,
+ throws IntrospectionException, IOException, ClassNotFoundException,
CatalogNotFoundException,
BadStrategyException, TypeNotFoundException
{
if( null != descriptor )
@@ -188,7 +188,7 @@
*/
private Type resolveType( ClassLoader classloader )
throws IntrospectionException, IOException,
ClassNotFoundException,
- RegistryNotFoundException, BadStrategyException,
TypeNotFoundException
+ CatalogNotFoundException, BadStrategyException,
TypeNotFoundException
{
if( null == m_registry )
{

Modified:
development/laboratory/plus/standard/builder/src/main/net/dpml/metro/builder/impl/ComponentTypeBuilderTask.java
==============================================================================
---
development/laboratory/plus/standard/builder/src/main/net/dpml/metro/builder/impl/ComponentTypeBuilderTask.java
(original)
+++
development/laboratory/plus/standard/builder/src/main/net/dpml/metro/builder/impl/ComponentTypeBuilderTask.java
Tue Mar 15 04:04:17 2005
@@ -29,10 +29,10 @@
import java.lang.reflect.Method;
import java.net.URI;

-import net.dpml.metro.meta.Type;
-import net.dpml.metro.meta.DependencyDescriptor;
-import net.dpml.metro.meta.PartDescriptor;
-import net.dpml.metro.meta.InfoDescriptor;
+import net.dpml.metro.type.Type;
+import net.dpml.metro.type.DependencyDescriptor;
+import net.dpml.metro.type.PartDescriptor;
+import net.dpml.metro.type.InfoDescriptor;

import net.dpml.metro.part.Part;
import net.dpml.metro.part.Descriptor;
@@ -41,7 +41,7 @@
import net.dpml.metro.builder.PartBuilder;
import net.dpml.metro.builder.IntrospectionException;

-import net.dpml.metro.catalog.RegistryNotFoundException;
+import net.dpml.metro.catalog.CatalogNotFoundException;
import net.dpml.metro.catalog.TypeNotFoundException;

import net.dpml.metro.control.BadStrategyException;
@@ -129,7 +129,7 @@
//---------------------------------------------------------------

public Type buildType( ClassLoader classloader )
- throws IntrospectionException, IOException, ClassNotFoundException,
RegistryNotFoundException,
+ throws IntrospectionException, IOException, ClassNotFoundException,
CatalogNotFoundException,
BadStrategyException, TypeNotFoundException
{
Class subject = loadSubjectClass( classloader );
@@ -239,7 +239,7 @@
}

private PartDescriptor[] createPartDescriptors( Class subject )
- throws IntrospectionException, IOException, ClassNotFoundException,
RegistryNotFoundException,
+ throws IntrospectionException, IOException, ClassNotFoundException,
CatalogNotFoundException,
BadStrategyException, TypeNotFoundException
{
String classname = subject.getName();
@@ -274,7 +274,7 @@

private void writeEmbeddedPart(
ClassLoader classloader, PartDescriptor descriptor, Method method,
PartBuilder builder )
- throws IntrospectionException, IOException, ClassNotFoundException,
RegistryNotFoundException,
+ throws IntrospectionException, IOException, ClassNotFoundException,
CatalogNotFoundException,
BadStrategyException, TypeNotFoundException
{
Part part = constructPart( classloader, descriptor, builder );
@@ -286,7 +286,7 @@
}

private Part constructPart( ClassLoader classloader, PartDescriptor
descriptor, PartBuilder builder )
- throws IntrospectionException, IOException, ClassNotFoundException,
RegistryNotFoundException,
+ throws IntrospectionException, IOException, ClassNotFoundException,
CatalogNotFoundException,
BadStrategyException, TypeNotFoundException
{
if( builder instanceof ComponentModelBuilderTask )

Modified:
development/laboratory/plus/standard/builder/src/main/net/dpml/metro/builder/impl/TypeBuilder.java
==============================================================================
---
development/laboratory/plus/standard/builder/src/main/net/dpml/metro/builder/impl/TypeBuilder.java
(original)
+++
development/laboratory/plus/standard/builder/src/main/net/dpml/metro/builder/impl/TypeBuilder.java
Tue Mar 15 04:04:17 2005
@@ -26,9 +26,9 @@

import net.dpml.metro.control.BadStrategyException;

-import net.dpml.metro.meta.Type;
+import net.dpml.metro.type.Type;
import net.dpml.metro.catalog.TypeNotFoundException;
-import net.dpml.metro.catalog.RegistryNotFoundException;
+import net.dpml.metro.catalog.CatalogNotFoundException;

/**
* The contract for builders that create component part.
@@ -52,6 +52,6 @@
*/
Type buildType( ClassLoader classloader )
throws IntrospectionException, IOException, ClassNotFoundException,
- RegistryNotFoundException, BadStrategyException,
TypeNotFoundException;
+ CatalogNotFoundException, BadStrategyException,
TypeNotFoundException;

}

Modified:
development/laboratory/plus/standard/builder/src/main/net/dpml/metro/builder/impl/antlib.xml
==============================================================================
---
development/laboratory/plus/standard/builder/src/main/net/dpml/metro/builder/impl/antlib.xml
(original)
+++
development/laboratory/plus/standard/builder/src/main/net/dpml/metro/builder/impl/antlib.xml
Tue Mar 15 04:04:17 2005
@@ -1,7 +1,7 @@
<?xml version="1.0"?>

<antlib>
- <taskdef name="registry"
classname="net.dpml.metro.builder.impl.RegistryTask"/>
+ <taskdef name="catalog"
classname="net.dpml.metro.builder.impl.CatalogTask"/>
<taskdef name="type"
classname="net.dpml.metro.builder.impl.ComponentTypeBuilderTask"/>
<taskdef name="component"
classname="net.dpml.metro.builder.impl.ComponentModelBuilderTask"/>
</antlib>

Copied:
development/laboratory/plus/standard/part/src/main/net/dpml/metro/catalog/Catalog.java
(from r2078,
development/laboratory/plus/standard/part/src/main/net/dpml/metro/catalog/Registry.java)
==============================================================================
---
development/laboratory/plus/standard/part/src/main/net/dpml/metro/catalog/Registry.java
(original)
+++
development/laboratory/plus/standard/part/src/main/net/dpml/metro/catalog/Catalog.java
Tue Mar 15 04:04:17 2005
@@ -30,42 +30,43 @@

import net.dpml.metro.part.Descriptor;

-import net.dpml.metro.meta.Type;
+import net.dpml.metro.type.Type;

import net.dpml.metro.control.BadStrategyException;

/**
- * A registry is a container of serialized component type holders keyed by
classname.
+ * A catalog is a container of serialized component type holders keyed by
classname.
*
* @author <a href="mailto:dev-dpml AT lists.ibiblio.org";>The Digital Product
Meta Library</a>
* @version $Revision: 1.2 $ $Date: 2004/03/17 10:30:09 $
*/
-public class Registry extends Descriptor
+public class Catalog extends Descriptor
{
- public static Registry loadRegistry( URL url ) throws
RegistryNotFoundException
+ public static final String ARTIFACT_TYPE = "catalog";
+
+ public static Catalog loadCatalog( URL url ) throws
CatalogNotFoundException
{
- System.out.println( "## loading registry: " + url );
try
{
InputStream input = url.openStream();
if( null == input )
{
- throw new RegistryNotFoundException( url );
+ throw new CatalogNotFoundException( url );
}
ObjectInputStream stream = new ObjectInputStream( input );
- return (Registry) stream.readObject();
+ return (Catalog) stream.readObject();
}
- catch( RegistryNotFoundException rnfe )
+ catch( CatalogNotFoundException rnfe )
{
throw rnfe;
}
catch( Throwable e )
{
final String error =
- "Internal error while attempting to load registry ["
+ "Internal error while attempting to load catalog ["
+ url
+ "].";
- throw new RegistryRuntimeException( error, e );
+ throw new CatalogRuntimeException( error, e );
}
}

@@ -78,12 +79,12 @@
private final TypeEntry[] m_entries;
private final String[] m_classnames;

- public Registry( URI uri, URI[] api, URI[] spi, URI[] impl, TypeEntry[]
entries )
+ public Catalog( URI uri, URI[] api, URI[] spi, URI[] impl, TypeEntry[]
entries )
{
this( uri, api, spi, impl, entries, null );
}

- public Registry( URI uri, URI[] api, URI[] spi, URI[] impl, TypeEntry[]
entries, Properties properties )
+ public Catalog( URI uri, URI[] api, URI[] spi, URI[] impl, TypeEntry[]
entries, Properties properties )
{
super( properties );
if( null == uri )
@@ -197,22 +198,22 @@
{
return false;
}
- else if( other instanceof Registry )
+ else if( other instanceof Catalog )
{
- Registry registry = (Registry) other;
- if( false == equals( getApiStack(), registry.getApiStack() ) )
+ Catalog catalog = (Catalog) other;
+ if( false == equals( getApiStack(), catalog.getApiStack() ) )
{
return false;
}
- else if( false == equals( getSpiStack(), registry.getSpiStack()
) )
+ else if( false == equals( getSpiStack(), catalog.getSpiStack() )
)
{
return false;
}
- else if( false == equals( getImplementationStack(),
registry.getImplementationStack() ) )
+ else if( false == equals( getImplementationStack(),
catalog.getImplementationStack() ) )
{
return false;
}
- else if( false == equals( getEntries(), registry.getEntries() ) )
+ else if( false == equals( getEntries(), catalog.getEntries() ) )
{
return false;
}

Copied:
development/laboratory/plus/standard/part/src/main/net/dpml/metro/catalog/CatalogNotFoundException.java
(from r2078,
development/laboratory/plus/standard/part/src/main/net/dpml/metro/catalog/RegistryNotFoundException.java)
==============================================================================
---
development/laboratory/plus/standard/part/src/main/net/dpml/metro/catalog/RegistryNotFoundException.java
(original)
+++
development/laboratory/plus/standard/part/src/main/net/dpml/metro/catalog/CatalogNotFoundException.java
Tue Mar 15 04:04:17 2005
@@ -26,11 +26,11 @@
* @author <a href="mailto:dev-dpml AT lists.ibiblio.org";>The Digital Product
Meta Library</a>
* @version $Revision: 1.2 $ $Date: 2004/03/17 10:30:09 $
*/
-public class RegistryNotFoundException extends Exception
+public class CatalogNotFoundException extends Exception
{
private URL m_url;

- public RegistryNotFoundException( URL url )
+ public CatalogNotFoundException( URL url )
{
super( url.toString() );
m_url = url;

Copied:
development/laboratory/plus/standard/part/src/main/net/dpml/metro/catalog/CatalogRuntimeException.java
(from r2078,
development/laboratory/plus/standard/part/src/main/net/dpml/metro/catalog/RegistryRuntimeException.java)
==============================================================================
---
development/laboratory/plus/standard/part/src/main/net/dpml/metro/catalog/RegistryRuntimeException.java
(original)
+++
development/laboratory/plus/standard/part/src/main/net/dpml/metro/catalog/CatalogRuntimeException.java
Tue Mar 15 04:04:17 2005
@@ -19,14 +19,14 @@
package net.dpml.metro.catalog;

/**
- * Unexpected runtime exception indicating an interanl registry error.
+ * Unexpected runtime exception indicating an interanl catalog error.
*
* @author <a href="mailto:dev-dpml AT lists.ibiblio.org";>The Digital Product
Meta Library</a>
* @version $Revision: 1.2 $ $Date: 2004/03/17 10:30:09 $
*/
-public class RegistryRuntimeException extends RuntimeException
+public class CatalogRuntimeException extends RuntimeException
{
- public RegistryRuntimeException( String message, Throwable cause )
+ public CatalogRuntimeException( String message, Throwable cause )
{
super( message, cause );
}

Modified:
development/laboratory/plus/standard/part/src/main/net/dpml/metro/catalog/ComponentTypeHandler.java
==============================================================================
---
development/laboratory/plus/standard/part/src/main/net/dpml/metro/catalog/ComponentTypeHandler.java
(original)
+++
development/laboratory/plus/standard/part/src/main/net/dpml/metro/catalog/ComponentTypeHandler.java
Tue Mar 15 04:04:17 2005
@@ -26,14 +26,7 @@
import java.net.URI;
import java.net.URL;

-import net.dpml.metro.meta.Type;
-
-import net.dpml.metro.catalog.TypeHandler;
-import net.dpml.metro.catalog.TypeHandlerRuntimeException;
-import net.dpml.metro.catalog.TypeReference;
-import net.dpml.metro.catalog.Registry;
-import net.dpml.metro.catalog.RegistryNotFoundException;
-import net.dpml.metro.catalog.TypeNotFoundException;
+import net.dpml.metro.type.Type;

import net.dpml.metro.control.BadStrategyException;

@@ -53,13 +46,13 @@
}

public Type loadType( TypeReference reference )
- throws RegistryNotFoundException, BadStrategyException,
TypeNotFoundException, IOException
+ throws CatalogNotFoundException, BadStrategyException,
TypeNotFoundException, IOException
{
- URI uri = reference.getRegistryURI();
+ URI uri = reference.getCatalogURI();
URL url = resolveURL( uri );
- Registry registry = Registry.loadRegistry( url );
+ Catalog catalog = Catalog.loadCatalog( url );
String classname = reference.getClassname();
- return registry.getType( this, classname );
+ return catalog.getType( this, classname );
}

public Type loadType( URI strategy, byte[] bytes ) throws
BadStrategyException, IOException

Modified:
development/laboratory/plus/standard/part/src/main/net/dpml/metro/catalog/TypeEntry.java
==============================================================================
---
development/laboratory/plus/standard/part/src/main/net/dpml/metro/catalog/TypeEntry.java
(original)
+++
development/laboratory/plus/standard/part/src/main/net/dpml/metro/catalog/TypeEntry.java
Tue Mar 15 04:04:17 2005
@@ -23,7 +23,7 @@
import java.io.IOException;
import java.net.URI;

-import net.dpml.metro.meta.Type;
+import net.dpml.metro.type.Type;

import net.dpml.metro.part.Holder;


Modified:
development/laboratory/plus/standard/part/src/main/net/dpml/metro/catalog/TypeHandler.java
==============================================================================
---
development/laboratory/plus/standard/part/src/main/net/dpml/metro/catalog/TypeHandler.java
(original)
+++
development/laboratory/plus/standard/part/src/main/net/dpml/metro/catalog/TypeHandler.java
Tue Mar 15 04:04:17 2005
@@ -22,7 +22,7 @@
import java.io.IOException;
import java.net.URI;

-import net.dpml.metro.meta.Type;
+import net.dpml.metro.type.Type;
import net.dpml.metro.control.BadStrategyException;

/**
@@ -36,7 +36,7 @@
URI getURI();

Type loadType( TypeReference reference )
- throws RegistryNotFoundException, BadStrategyException,
TypeNotFoundException, IOException;
+ throws CatalogNotFoundException, BadStrategyException,
TypeNotFoundException, IOException;

Type loadType( URI strategy, byte[] bytes ) throws BadStrategyException,
IOException;
}

Modified:
development/laboratory/plus/standard/part/src/main/net/dpml/metro/catalog/TypeReference.java
==============================================================================
---
development/laboratory/plus/standard/part/src/main/net/dpml/metro/catalog/TypeReference.java
(original)
+++
development/laboratory/plus/standard/part/src/main/net/dpml/metro/catalog/TypeReference.java
Tue Mar 15 04:04:17 2005
@@ -24,26 +24,26 @@
import net.dpml.metro.part.Descriptor;

/**
- * A type reference is a reference to registry entry. The reference
contains
- * the uri of the registry and the classname key of an entry in the registry.
+ * A type reference is a reference to catalog entry. The reference contains
+ * the uri of the catalog and the classname key of an entry in the catalog.
*
* @author <a href="mailto:dev-dpml AT lists.ibiblio.org";>The Digital Product
Meta Library</a>
* @version $Revision: 1.2 $ $Date: 2004/03/17 10:30:09 $
*/
public class TypeReference extends Descriptor
{
- private final URI m_registry;
+ private final URI m_catalog;
private final String m_classname;

- public TypeReference( URI registry, String classname )
+ public TypeReference( URI catalog, String classname )
{
- this( registry, classname, null );
+ this( catalog, classname, null );
}

- public TypeReference( URI registry, String classname, Properties
properties )
+ public TypeReference( URI catalog, String classname, Properties
properties )
{
super( properties );
- m_registry = registry;
+ m_catalog = catalog;
m_classname = classname;
}

@@ -52,16 +52,16 @@
return m_classname;
}

- public URI getRegistryURI()
+ public URI getCatalogURI()
{
- return m_registry;
+ return m_catalog;
}

public int hashCode()
{
int hash = super.hashCode();
hash ^= m_classname.hashCode();
- hash ^= m_registry.hashCode();
+ hash ^= m_catalog.hashCode();
return hash;
}

@@ -82,7 +82,7 @@
{
return false;
}
- else if( getRegistryURI().equals( reference.getRegistryURI() )
== false )
+ else if( getCatalogURI().equals( reference.getCatalogURI() ) ==
false )
{
return false;
}
@@ -99,7 +99,7 @@

public String toString()
{
- return "[reference " + m_registry + " class:" + m_classname + "]";
+ return "[reference " + m_catalog + " class:" + m_classname + "]";
}

}

Modified:
development/laboratory/plus/standard/part/src/main/net/dpml/metro/type/DependencyDescriptor.java
==============================================================================
---
development/laboratory/plus/standard/part/src/main/net/dpml/metro/meta/DependencyDescriptor.java
(original)
+++
development/laboratory/plus/standard/part/src/main/net/dpml/metro/type/DependencyDescriptor.java
Tue Mar 15 04:04:17 2005
@@ -16,7 +16,7 @@
* limitations under the License.
*/

-package net.dpml.metro.meta;
+package net.dpml.metro.type;

import java.util.Properties;


Modified:
development/laboratory/plus/standard/part/src/main/net/dpml/metro/type/InfoDescriptor.java
==============================================================================
---
development/laboratory/plus/standard/part/src/main/net/dpml/metro/meta/InfoDescriptor.java
(original)
+++
development/laboratory/plus/standard/part/src/main/net/dpml/metro/type/InfoDescriptor.java
Tue Mar 15 04:04:17 2005
@@ -16,7 +16,7 @@
* limitations under the License.
*/

-package net.dpml.metro.meta;
+package net.dpml.metro.type;

import java.util.Properties;


Modified:
development/laboratory/plus/standard/part/src/main/net/dpml/metro/type/PartDescriptor.java
==============================================================================
---
development/laboratory/plus/standard/part/src/main/net/dpml/metro/meta/PartDescriptor.java
(original)
+++
development/laboratory/plus/standard/part/src/main/net/dpml/metro/type/PartDescriptor.java
Tue Mar 15 04:04:17 2005
@@ -16,7 +16,7 @@
* limitations under the License.
*/

-package net.dpml.metro.meta;
+package net.dpml.metro.type;

import java.net.URI;
import java.util.Properties;

Modified:
development/laboratory/plus/standard/part/src/main/net/dpml/metro/type/Type.java
==============================================================================
---
development/laboratory/plus/standard/part/src/main/net/dpml/metro/meta/Type.java
(original)
+++
development/laboratory/plus/standard/part/src/main/net/dpml/metro/type/Type.java
Tue Mar 15 04:04:17 2005
@@ -16,7 +16,7 @@
* limitations under the License.
*/

-package net.dpml.metro.meta;
+package net.dpml.metro.type;

import java.io.Serializable;
import java.util.Properties;

Modified: development/laboratory/plus/test/example/impl/build.xml
==============================================================================
--- development/laboratory/plus/test/example/impl/build.xml (original)
+++ development/laboratory/plus/test/example/impl/build.xml Tue Mar 15
04:04:17 2005
@@ -9,7 +9,7 @@
<transit:import uri="artifact:template:dpml/magic/standard"/>

<target name="package" depends="standard.package">
- <x:property feature="uri" type="registry" name="registry.uri"/>
+
<x:property key="dpml-metro-control-impl" feature="plugin"
name="debugger.uri"/>

<registry xmlns="plugin:dpml/metro/dpml-metro-builder-impl">

Modified: development/laboratory/plus/test/example/part/build.xml
==============================================================================
--- development/laboratory/plus/test/example/part/build.xml (original)
+++ development/laboratory/plus/test/example/part/build.xml Tue Mar 15
04:04:17 2005
@@ -7,11 +7,14 @@
xmlns:x="plugin:dpml/magic/dpml-magic-core">

<transit:import uri="artifact:template:dpml/magic/standard"/>
+
+ <target name="init" depends="standard.init">
+ <x:property key="dpml-test-hello-impl" feature="uri" type="catalog"
name="catalog.uri"/>
+ </target>

<target name="package" depends="standard.package">
- <x:property key="dpml-test-hello-impl" feature="uri" type="registry"
name="registry.uri"/>
<component xmlns="plugin:dpml/metro/dpml-metro-builder-impl"
- class="net.dpml.test.hello.impl.HelloComponent"
uri="${registry.uri}"/>
+ class="net.dpml.test.hello.impl.HelloComponent" uri="${catalog.uri}"/>
</target>

</project>



  • svn commit: r2079 - in development/laboratory/plus: . standard/builder/src/main/net/dpml/metro/builder/impl standard/part/src/main/net/dpml/metro/catalog standard/part/src/main/net/dpml/metro/meta standard/part/src/main/net/dpml/metro/type test/example/impl test/example/part, mcconnell, 03/14/2005

Archive powered by MHonArc 2.6.24.

Top of Page