Skip to Content.
Sympa Menu

notify-dpml - svn commit: r2946 - in development/main: metro/central/src/main/net/dpml/metro/central metro/composition/control/src/main/net/dpml/composition/control metro/composition/control/src/main/net/dpml/composition/runtime metro/part/src/main/net/dpml/part/control metro/part/src/main/net/dpml/part/manager transit transit/core/handler transit/core/handler/src/main/net/dpml/transit/artifact

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: r2946 - in development/main: metro/central/src/main/net/dpml/metro/central metro/composition/control/src/main/net/dpml/composition/control metro/composition/control/src/main/net/dpml/composition/runtime metro/part/src/main/net/dpml/part/control metro/part/src/main/net/dpml/part/manager transit transit/core/handler transit/core/handler/src/main/net/dpml/transit/artifact
  • Date: Fri, 01 Jul 2005 18:19:13 -0400

Author: mcconnell AT dpml.net
Date: Fri Jul 1 18:19:13 2005
New Revision: 2946

Added:

development/main/metro/part/src/main/net/dpml/part/control/ControllerRuntimeException.java
- copied, changed from r2942,
development/main/metro/part/src/main/net/dpml/part/control/ControlRuntimeException.java
Removed:
development/main/metro/part/src/main/net/dpml/part/control/Control.java

development/main/metro/part/src/main/net/dpml/part/control/ControlRuntimeException.java

development/main/metro/part/src/main/net/dpml/part/control/Identifiable.java

development/main/metro/part/src/main/net/dpml/part/control/InvalidQueryException.java

development/main/metro/part/src/main/net/dpml/part/control/NoSuchControlException.java
Modified:

development/main/metro/central/src/main/net/dpml/metro/central/MetroHelper.java

development/main/metro/central/src/main/net/dpml/metro/central/PartContentHandler.java

development/main/metro/composition/control/src/main/net/dpml/composition/control/CompositionClassLoader.java

development/main/metro/composition/control/src/main/net/dpml/composition/control/CompositionController.java

development/main/metro/composition/control/src/main/net/dpml/composition/control/CompositionControllerContext.java

development/main/metro/composition/control/src/main/net/dpml/composition/runtime/ComponentController.java

development/main/metro/composition/control/src/main/net/dpml/composition/runtime/ComponentHandler.java

development/main/metro/composition/control/src/main/net/dpml/composition/runtime/Manager.java

development/main/metro/composition/control/src/main/net/dpml/composition/runtime/PartsTable.java
development/main/metro/part/src/main/net/dpml/part/control/Controller.java
development/main/metro/part/src/main/net/dpml/part/control/PartHandler.java

development/main/metro/part/src/main/net/dpml/part/control/UnsupportedPartTypeException.java
development/main/metro/part/src/main/net/dpml/part/manager/Component.java
development/main/transit/core/handler/build.xml

development/main/transit/core/handler/src/main/net/dpml/transit/artifact/Artifact.java
development/main/transit/standard.xml
Log:
Tightening up the metro api.

Modified:
development/main/metro/central/src/main/net/dpml/metro/central/MetroHelper.java
==============================================================================
---
development/main/metro/central/src/main/net/dpml/metro/central/MetroHelper.java
(original)
+++
development/main/metro/central/src/main/net/dpml/metro/central/MetroHelper.java
Fri Jul 1 18:19:13 2005
@@ -107,7 +107,7 @@
{
try
{
- File base = m_controller.getWorkingDirectory();
+ File base =
m_controller.getControllerContext().getWorkingDirectory();
File target = new File( base, path );
return target.toURI();
}

Modified:
development/main/metro/central/src/main/net/dpml/metro/central/PartContentHandler.java
==============================================================================
---
development/main/metro/central/src/main/net/dpml/metro/central/PartContentHandler.java
(original)
+++
development/main/metro/central/src/main/net/dpml/metro/central/PartContentHandler.java
Fri Jul 1 18:19:13 2005
@@ -36,8 +36,6 @@
import net.dpml.transit.repository.Repository;

import net.dpml.part.control.Controller;
-import net.dpml.part.control.ControlException;
-import net.dpml.part.control.ControlRuntimeException;
import net.dpml.part.control.ControllerContext;

import net.dpml.part.part.Part;

Modified:
development/main/metro/composition/control/src/main/net/dpml/composition/control/CompositionClassLoader.java
==============================================================================
---
development/main/metro/composition/control/src/main/net/dpml/composition/control/CompositionClassLoader.java
(original)
+++
development/main/metro/composition/control/src/main/net/dpml/composition/control/CompositionClassLoader.java
Fri Jul 1 18:19:13 2005
@@ -21,11 +21,14 @@
import java.net.URI;
import java.net.URL;
import java.net.URLClassLoader;
+import java.net.MalformedURLException ;

import net.dpml.logging.Logger;

-import net.dpml.part.control.ControlRuntimeException;
+import net.dpml.part.control.ControllerRuntimeException;

+import net.dpml.transit.artifact.Artifact;
+import net.dpml.transit.artifact.UnsupportedSchemeException;
import net.dpml.transit.repository.StandardClassLoader;

/**
@@ -179,28 +182,28 @@
{
try
{
- if( "artifact".equals( uri.getScheme() ) )
- {
- String spec = uri.toString();
- return new URL( null, spec, new
net.dpml.transit.artifact.Handler() );
- }
- //else if( "link".equals( uri.getScheme() ) )
- //{
- // String spec = uri.toString();
- // return new URL( null, spec, new
net.dpml.transit.link.Handler() );
- //}
- else
- {
- return uri.toURL();
- }
+ return doUriToURL( uri );
}
- catch( Exception e )
+ catch( MalformedURLException e )
{
final String error =
"Internal error occured while attempting to transform the uri
["
+ uri
+ "] to a url.";
- throw new ControlRuntimeException(
CompositionController.CONTROLLER_URI, error, e );
+ throw new ControllerRuntimeException(
CompositionController.CONTROLLER_URI, error, e );
+ }
+ }
+
+ private static URL doUriToURL( URI uri ) throws MalformedURLException
+ {
+ try
+ {
+ Artifact artifact = Artifact.createArtifact( uri );
+ return artifact.toURL();
+ }
+ catch( UnsupportedSchemeException e )
+ {
+ return uri.toURL();
}
}
}

Modified:
development/main/metro/composition/control/src/main/net/dpml/composition/control/CompositionController.java
==============================================================================
---
development/main/metro/composition/control/src/main/net/dpml/composition/control/CompositionController.java
(original)
+++
development/main/metro/composition/control/src/main/net/dpml/composition/control/CompositionController.java
Fri Jul 1 18:19:13 2005
@@ -45,12 +45,13 @@
import net.dpml.part.control.ControllerContext;
import net.dpml.part.control.HandlerNotFoundException;
import net.dpml.part.control.ControlException;
-import net.dpml.part.control.ControlRuntimeException;
+import net.dpml.part.control.ControllerRuntimeException;
import net.dpml.part.control.Controller;
import net.dpml.part.control.DelegationException;
import net.dpml.part.control.Disposable;
import net.dpml.part.control.LifecycleException;
import net.dpml.part.control.PartNotFoundException;
+import net.dpml.part.control.UnsupportedPartTypeException;
import net.dpml.part.manager.Component;
import net.dpml.part.manager.ComponentException;
import net.dpml.part.manager.Container;
@@ -112,6 +113,18 @@
//m_lifestyleHandler = new LifestyleHandler( m_logger,
m_componentController );
}

+ /**
+ * Return the controllers runtime context. The runtime context holds
infromation
+ * about the working and temporary directories and a uri identifying the
execution
+ * domain.
+ *
+ * @return the runtime context
+ */
+ public ControllerContext getControllerContext()
+ {
+ return m_context;
+ }
+
Logger getLogger()
{
return m_logger;
@@ -172,11 +185,11 @@
}
else if( "work.dir".equals( key ) )
{
- return getWorkingDirectory();
+ return m_context.getWorkingDirectory();
}
else if( "temp.dir".equals( key ) )
{
- return getTempDirectory();
+ return m_context.getTempDirectory();
}
else
{
@@ -216,20 +229,20 @@
}
}

- public File getWorkingDirectory()
- {
- return m_context.getWorkingDirectory();
- }
+ //public File getWorkingDirectory()
+ //{
+ // return m_context.getWorkingDirectory();
+ //}

- public File getTempDirectory()
- {
- return m_context.getTempDirectory();
- }
+ //public File getTempDirectory()
+ //{
+ // return m_context.getTempDirectory();
+ //}

- public String getName()
- {
- return getPartition().toASCIIString();
- }
+ //public String getName()
+ //{
+ // return getPartition().toASCIIString();
+ //}

/**
* Construct a new top-level component.
@@ -262,10 +275,10 @@
* @param part the value directive
* @param id the value handler identifier
* @return the value handler component
+ * @exception UnsupportedPartTypeException if the part type is recognized
but not supported
*/
public Component newComponent( ClassLoader classloader, Component
parent, Part part, String name )
throws ComponentException, HandlerNotFoundException,
DelegationException
-
{
URI partition = getPartition( parent );
if( isRecognizedPart( part ) )
@@ -289,11 +302,12 @@
}
else
{
+ String classname = part.getClass().getName();
final String error =
"Unsupported part implementation class ["
- + part.getClass().getName()
+ + classname
+ "] passed to newComponent/4.";
- throw new UnsupportedOperationException( error );
+ throw new UnsupportedPartTypeException( CONTROLLER_URI,
classname, error );
}
}
else
@@ -502,7 +516,7 @@
+ "] and path ["
+ path
+ "].";
- throw new ControlRuntimeException( CONTROLLER_URI, error, e );
+ throw new ControllerRuntimeException( CONTROLLER_URI, error, e );
}
}

@@ -516,7 +530,7 @@
{
final String error =
"Invalid URI specification [" + spec + "].";
- throw new ControlRuntimeException( CONTROLLER_URI, error, e );
+ throw new ControllerRuntimeException( CONTROLLER_URI, error, e );
}
}

@@ -534,205 +548,4 @@
return null;
}
}
-
- //public Model getPart( CompositionModel model, String key )
- //{
- // return model.getPartsTable().getModel( key );
- //}
-
- //public Component getContextEntry( CompositionModel model, String key )
- //{
- // return model.getContextTable().getEntry( key );
- //}
-
- /**
- * Add a part to the collection of parts managed by this controller.
- *
- * @param uri a uri identifying the part to add
- * @return the model of the part
- */
- //public Model getModel( URI uri )
- // throws IOException, DelegationException, ModelException,
PartNotFoundException,
- // HandlerNotFoundException, DelegationException
- //{
- // return getModel( uri, null );
- //}
-
- /**
- * Return a model using a par turi and key.
- *
- * @param uri a uri identifying the part
- * @param key the key to assign to the model
- * @return the model of the part
- */
- //public Model getModel( URI uri, String key )
- // throws IOException, DelegationException, ModelException,
PartNotFoundException,
- // HandlerNotFoundException, DelegationException
- //{
- // m_logger.debug( "loading part " + uri );
- // Part part = loadPart( uri );
- // ClassLoader anchor =
net.dpml.part.part.Part.class.getClassLoader();
- // return getModel( anchor, part, key );
- //}
-
- /**
- * Return the model for a supplied part.
- *
- * @param classloader the parent classloader
- * @param part the part datastructure
- * @param key the key to assign to the model
- * @return the model
- */
- //public Model getModel( ClassLoader classloader, Part part, String key
)
- // throws ModelException, HandlerNotFoundException, DelegationException
- //{
- // if( isRecognizedPart( part ) )
- // {
- // return getModel( null, classloader, part, key );
- // }
- // else
- // {
- // Controller controller = getPartHandler( part );
- // return controller.getModel( classloader, part, key );
- // }
- //}
-
- /**
- * Return a nested model for a supplied part using enclosing model.
- *
- * @param model the enclosing model
- * @param classloader the parent classloader
- * @param part the part datastructure
- * @param key the key to assign to the model
- * @return the model
- */
- //public Model getModel( CompositionModel model, ClassLoader
classloader, Part part, String key )
- // throws ModelException
- //{
- // if( part instanceof ComponentProfile )
- // {
- // final ComponentProfile profile = (ComponentProfile) part;
- // getLogger().debug( "creating nested model using " + profile );
- // URI partition = getPartition( model );
- // ClassLoader parent = getClassLoader( partition, classloader,
profile );
- // try
- // {
- // if( null == model )
- // {
- // if( null == key )
- // {
- // return new CompositionModel( this, partition,
parent, profile );
- // }
- // else
- // {
- // return new CompositionModel( this, partition,
parent, profile, key );
- // }
- // }
- // else
- // {
- // return new CompositionModel( this, model, partition,
parent, profile, key );
- // }
- // }
- // catch( RemoteException e )
- // {
- // final String error =
- // "A remote exception occured while attempting to
construct a composition model.";
- // throw new ControlRuntimeException( CONTROLLER_URI, error,
e );
- // }
- // }
- // else if( part instanceof ValueDirective )
- // {
- // final ValueDirective directive = (ValueDirective) part;
- // getLogger().debug( "creating nested value model using " +
directive );
- // URI partition = getPartition( model );
- // URI uri = createURI( partition, key );
- // try
- // {
- // return new ValueModel(
- // key, partition, uri, classloader, directive, model );
- // }
- // catch( RemoteException e )
- // {
- // final String error =
- // "A remote exception occured while attempting to
construct a value model.";
- // throw new ControlRuntimeException( CONTROLLER_URI, error,
e );
- // }
- // }
- // else
- // {
- // final String error =
- // "The request to construct a model for the part type ["
- // + part.getClass().getName()
- // + "] is not supported.";
- // throw new UnsupportedOperationException( error );
- // }
- //}
-
- /**
- * Return a nested component for a supplied part.
- *
- * @param classloader the parent classloader
- * @param part the part datastructure
- * @param key the key to assign to the model
- * @return the model
- */
- //public Component getComponent( ClassLoader classloader, Part part,
String key )
- // throws ModelException, HandlerNotFoundException, DelegationException
- //{
- // return getComponent( null, classloader, part, key );
- //}
-
- /**
- * Return a nested component for a supplied part using enclosing model.
- *
- * @param model the enclosing model
- * @param classloader the parent classloader
- * @param part the part datastructure
- * @param key the key to assign to the model
- * @return the model
- */
- //public Component getComponent(
- // CompositionModel model, ClassLoader classloader, Part part, String
key )
- // throws ModelException, HandlerNotFoundException, DelegationException
- //{
- // if( isRecognizedPart( part ) )
- // {
- // Model componentModel = getModel( model, classloader, part, key
);
- // return getComponent( componentModel );
- // }
- // else
- // {
- // Controller controller = getPartHandler( part );
- // return controller.getComponent( classloader, part, key );
- // }
- //}
-
- /**
- * Return a default instance model.
- *
- * @param model the reference model
- * @return the model
- */
- //public Component getComponent( Model model )
- //{
- // if( model instanceof ValueModel )
- // {
- // ValueModel m = (ValueModel) model;
- // try
- // {
- // return new ValueHandler( this, m_logger, m,
m_valueController );
- // }
- // catch( Throwable e )
- // {
- // final String error =
- // "An unexpected exception occured while attempting to
resolve a component for a value model.";
- // throw new ControlRuntimeException( CONTROLLER_URI, error,
e );
- // }
- // }
- // else
- // {
- // return getComponentHandler( model, null );
- // }
- //}
-
}

Modified:
development/main/metro/composition/control/src/main/net/dpml/composition/control/CompositionControllerContext.java
==============================================================================
---
development/main/metro/composition/control/src/main/net/dpml/composition/control/CompositionControllerContext.java
(original)
+++
development/main/metro/composition/control/src/main/net/dpml/composition/control/CompositionControllerContext.java
Fri Jul 1 18:19:13 2005
@@ -36,7 +36,6 @@
import net.dpml.part.control.ControllerContext;
import net.dpml.part.control.ControllerContextListener;
import net.dpml.part.control.ControllerContextEvent;
-import net.dpml.part.control.ControlRuntimeException;

import net.dpml.transit.model.DefaultModel;
import net.dpml.transit.model.ContentModel;

Modified:
development/main/metro/composition/control/src/main/net/dpml/composition/runtime/ComponentController.java
==============================================================================
---
development/main/metro/composition/control/src/main/net/dpml/composition/runtime/ComponentController.java
(original)
+++
development/main/metro/composition/control/src/main/net/dpml/composition/runtime/ComponentController.java
Fri Jul 1 18:19:13 2005
@@ -44,7 +44,7 @@
import net.dpml.composition.control.CompositionController;

import net.dpml.part.control.ControlException;
-import net.dpml.part.control.ControlRuntimeException;
+import net.dpml.part.control.ControllerRuntimeException;
import net.dpml.part.control.Disposable;
import net.dpml.part.manager.Component;
import net.dpml.part.manager.DuplicateKeyException;
@@ -271,7 +271,7 @@
"Unable to establish a component instance."
+ "\nComponent: " + component.getURI()
+ "\nClass: " + component.getDeploymentClass();
- throw new ControlRuntimeException( uri, error, e );
+ throw new ControllerRuntimeException( uri, error, e );
}
}
return instance;

Modified:
development/main/metro/composition/control/src/main/net/dpml/composition/runtime/ComponentHandler.java
==============================================================================
---
development/main/metro/composition/control/src/main/net/dpml/composition/runtime/ComponentHandler.java
(original)
+++
development/main/metro/composition/control/src/main/net/dpml/composition/runtime/ComponentHandler.java
Fri Jul 1 18:19:13 2005
@@ -57,7 +57,6 @@
import net.dpml.parameters.Parameterizable;
import net.dpml.parameters.impl.DefaultParameters;

-import net.dpml.part.control.Identifiable;
import net.dpml.part.control.LifecycleException;
import net.dpml.part.control.HandlerNotFoundException;
import net.dpml.part.control.DelegationException;

Modified:
development/main/metro/composition/control/src/main/net/dpml/composition/runtime/Manager.java
==============================================================================
---
development/main/metro/composition/control/src/main/net/dpml/composition/runtime/Manager.java
(original)
+++
development/main/metro/composition/control/src/main/net/dpml/composition/runtime/Manager.java
Fri Jul 1 18:19:13 2005
@@ -18,7 +18,8 @@

package net.dpml.composition.runtime;

-import net.dpml.part.control.Control;
+import java.net.URI;
+
import net.dpml.part.manager.ResourceUnavailableException;
import net.dpml.part.manager.Component;
import net.dpml.part.state.State;
@@ -28,9 +29,15 @@
*
* @author <a href="mailto:dev-dpml AT lists.ibiblio.org";>The Digital Product
Meta Library</a>
*/
-public interface Manager extends Control
+public interface Manager
{
/**
+ * Return a uri identifiying this control.
+ * @return the uri
+ */
+ URI getURI();
+
+ /**
* Return an instance of the component type represented
* by the supplied model.
*

Modified:
development/main/metro/composition/control/src/main/net/dpml/composition/runtime/PartsTable.java
==============================================================================
---
development/main/metro/composition/control/src/main/net/dpml/composition/runtime/PartsTable.java
(original)
+++
development/main/metro/composition/control/src/main/net/dpml/composition/runtime/PartsTable.java
Fri Jul 1 18:19:13 2005
@@ -24,7 +24,6 @@

import net.dpml.part.control.DelegationException;
import net.dpml.part.control.HandlerNotFoundException;
-import net.dpml.part.control.ControlRuntimeException;
import net.dpml.part.manager.DuplicateKeyException;
import net.dpml.part.manager.Component;
import net.dpml.part.manager.ComponentException;

Modified:
development/main/metro/part/src/main/net/dpml/part/control/Controller.java
==============================================================================
---
development/main/metro/part/src/main/net/dpml/part/control/Controller.java
(original)
+++
development/main/metro/part/src/main/net/dpml/part/control/Controller.java
Fri Jul 1 18:19:13 2005
@@ -29,117 +29,58 @@
import net.dpml.part.part.Part;

/**
- * The Controller interface defines the a contract for a object that is
capable of
- * operation management of a set of arbitary models together with part
handling for
- * a particular part strategy.
+ * The Controller interface defines the a contract for an object that
provides general
+ * component and part handling management services.
*
* @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 interface Controller extends Control
+public interface Controller
{
- File getWorkingDirectory();
-
- File getTempDirectory();
+ /**
+ * Returns the identity of the object implementing this interface.
+ * @return a uri identifying the object
+ */
+ URI getURI();

/**
- * Return a resource relative to the supplied urn. Standard
- * urn values are listed in the following table.
- *
- * <ol>
- * <li>system:domain.uri</li>
- * <li>system:work.dir</li>
- * <li>system:temp.dir</li>
- * <li>component:name</li>
- * <li>component:urn</li>
- * <li>component:partition</li>
- * </ol>
- *
- * An implementation may choose to provide support for additional urns
beyond those
- * listed in the above table.
- *
- * @param component the component from which any relative urn values are
to be resolved
- * @param urn the uniform resource identifier identifying the requested
resource
- * @return the resource matching the supplied urn
- * @exception IllegalStateException if the supplied urn is not valid
+ * Return the controllers runtime context. The runtime context holds
infromation
+ * about the working and temporary directories and a uri identifying the
execution
+ * domain.
+ *
+ * @return the runtime context
*/
- Object getResource( Component component, URI urn );
+ ControllerContext getControllerContext();

/**
* Construct a new top-level component.
*
- * @param uri a uri identifying a part
- * @return the model of the part
+ * @param uri a uri identifying a part from which the compoent will be
created.
+ * @return the new component
+ * @exception ComponentException is an error occurs during component
establishment
+ * @exception IOException if an error occurs while attempting to resolve
the component part uri
+ * @exception PartNotFoundException if the uri could not be resolved to a
physical resource
+ * @exception HandlerNotFoundException if the part references a handler
but the handler could not be found
+ * @exception DelegationException if an error occurs following handover
of control to a foreign controller
*/
Component newComponent( URI uri ) throws
ComponentException, IOException, PartNotFoundException,
HandlerNotFoundException,
DelegationException;

/**
- * Construct a new component under a supplied classloader and part.
+ * Construct a new component under a supplied classloader using the
supplied part as the
+ * defintion of the component type and deployment criteria.
*
- * @param parent the parent classloader
- * @param the enclosing component
- * @param part component definition
+ * @param classloder the classloader to use as the root classloader for
component construction
+ * @param parent the enclosing parent component (may be null)
+ * @param part component definition including type and deployment data
* @param name the name to assign to the new component
* @return a new component
+ * @exception ComponentException is an error occurs during component
establishment
+ * @exception HandlerNotFoundException if the part references a handler
but the handler could not be found
+ * @exception DelegationException if an error occurs following handover
of control to a foreign controller
*/
- Component newComponent( ClassLoader parent, Component component, Part
part, String name )
+ Component newComponent( ClassLoader classloader, Component parent, Part
part, String name )
throws ComponentException, HandlerNotFoundException,
DelegationException;

-
-
//===================================================================================
-
- /**
- * Return a model using a part uri and key.
- *
- * @param uri a uri identifying the part
- * @param key the key to assign to the model
- * @return the model of the part
- */
- //Model getModel( URI uri, String key )
- // throws IOException, DelegationException, ComponentException,
PartNotFoundException,
- // HandlerNotFoundException;
-
- /**
- * Return a new model for a supplied part.
- *
- * @param parent the parent classloader
- * @param part the part datastructure
- * @param name the name to assign to the model
- * @return the model
- */
- //Model getModel( ClassLoader parent, Part part, String name )
- // throws ComponentException, HandlerNotFoundException,
DelegationException;
-
- /**
- * Return a default service provider component.
- *
- * @param model the reference model
- * @return the service provider
- */
- //Component getComponent( Model model )
- // throws ComponentException;
-
- /**
- * Return an identified service provider component.
- *
- * @param model the reference model
- * @param identity the privider identity
- * @return the service provider
- */
- //Component getComponent( Model model, Object identity )
- // throws ComponentException;
-
- /**
- * Return a component for a supplied part.
- *
- * @param parent the parent classloader
- * @param part the part datastructure
- * @param name the name to assign to the provider model
- * @return the default provider
- */
- //Component getComponent( ClassLoader parent, Part part, String name )
- // throws ComponentException, HandlerNotFoundException,
DelegationException;
-
}

Copied:
development/main/metro/part/src/main/net/dpml/part/control/ControllerRuntimeException.java
(from r2942,
development/main/metro/part/src/main/net/dpml/part/control/ControlRuntimeException.java)
==============================================================================
---
development/main/metro/part/src/main/net/dpml/part/control/ControlRuntimeException.java
(original)
+++
development/main/metro/part/src/main/net/dpml/part/control/ControllerRuntimeException.java
Fri Jul 1 18:19:13 2005
@@ -28,39 +28,39 @@
* @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 ControlRuntimeException extends RuntimeException
+public class ControllerRuntimeException extends RuntimeException
{
private final URI m_uri;

/**
- * Creation of a new ControlRuntimeException.
+ * Creation of a new ControllerRuntimeException.
*
* @param controller the uri identifying the controller iniating the
exception
*/
- public ControlRuntimeException( URI controller )
+ public ControllerRuntimeException( URI controller )
{
this( controller, null );
}

/**
- * Creation of a new ControlRuntimeException.
+ * Creation of a new ControllerRuntimeException.
*
* @param controller the uri identifying the controller iniating the
exception
* @param message the description of the exception
*/
- public ControlRuntimeException( URI controller, String message )
+ public ControllerRuntimeException( URI controller, String message )
{
this( controller, message, null );
}

/**
- * Creation of a new ControlRuntimeException.
+ * Creation of a new ControllerRuntimeException.
*
* @param controller the uri identifying the controller iniating the
exception
* @param message the description of the exception
* @param cause the causal exception
*/
- public ControlRuntimeException( URI controller, String message,
Throwable cause )
+ public ControllerRuntimeException( URI controller, String message,
Throwable cause )
{
super( message, cause );
m_uri = controller;

Modified:
development/main/metro/part/src/main/net/dpml/part/control/PartHandler.java
==============================================================================
---
development/main/metro/part/src/main/net/dpml/part/control/PartHandler.java
(original)
+++
development/main/metro/part/src/main/net/dpml/part/control/PartHandler.java
Fri Jul 1 18:19:13 2005
@@ -43,7 +43,7 @@
* Load the model controller.
* @return the controller
*/
- Controller getController() throws RemoteException;
+ //Controller getController() throws RemoteException;

/**
* Load a part handler giiven a handler uri.

Modified:
development/main/metro/part/src/main/net/dpml/part/control/UnsupportedPartTypeException.java
==============================================================================
---
development/main/metro/part/src/main/net/dpml/part/control/UnsupportedPartTypeException.java
(original)
+++
development/main/metro/part/src/main/net/dpml/part/control/UnsupportedPartTypeException.java
Fri Jul 1 18:19:13 2005
@@ -18,7 +18,7 @@

package net.dpml.part.control;

-import net.dpml.part.part.Part;
+import java.net.URI;

/**
* Exception thrown when an strategy handler attempts to handle an
@@ -27,18 +27,13 @@
* @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 UnsupportedPartTypeException extends RuntimeException
+public class UnsupportedPartTypeException extends ControllerRuntimeException
{
private String m_type;

- public UnsupportedPartTypeException( Part part )
+ public UnsupportedPartTypeException( URI uri, String classname, String
message )
{
- this( part.getClass().getName() );
- }
-
- public UnsupportedPartTypeException( String classname )
- {
- super( classname );
+ super( uri, message );
m_type = classname;
}

@@ -46,7 +41,6 @@
{
return m_type;
}
-
}



Modified:
development/main/metro/part/src/main/net/dpml/part/manager/Component.java
==============================================================================
--- development/main/metro/part/src/main/net/dpml/part/manager/Component.java
(original)
+++ development/main/metro/part/src/main/net/dpml/part/manager/Component.java
Fri Jul 1 18:19:13 2005
@@ -24,7 +24,6 @@
import net.dpml.part.state.State;
import net.dpml.part.state.StateEvent;
import net.dpml.part.state.StateListener;
-import net.dpml.part.control.Identifiable;

/**
* The Component interface is implemented by objects that handle the runtime

Modified: development/main/transit/core/handler/build.xml
==============================================================================
--- development/main/transit/core/handler/build.xml (original)
+++ development/main/transit/core/handler/build.xml Fri Jul 1 18:19:13
2005
@@ -74,7 +74,8 @@
<mkdir dir="${target.deliverables.jars.dir}"/>
<jar destfile="${target.deliverables.jars.dir}/${project.filename}"
basedir="${target.classes.dir}"
- includes="**/*.*" excludes="**/*.html">
+ includes="**/*.*" excludes="**/*.html,**/*.png"
+ index="true">
</jar>
<checksum fileext=".md5"
file="${target.deliverables.jars.dir}/${project.filename}"/>
<delete file="${target.deliverables.jars.dir}/${project.filename}.asc"/>

Modified:
development/main/transit/core/handler/src/main/net/dpml/transit/artifact/Artifact.java
==============================================================================
---
development/main/transit/core/handler/src/main/net/dpml/transit/artifact/Artifact.java
(original)
+++
development/main/transit/core/handler/src/main/net/dpml/transit/artifact/Artifact.java
Fri Jul 1 18:19:13 2005
@@ -72,11 +72,11 @@
* @param uri the artifact uri
* @return the new artifact
* @exception java.net.URISyntaxException if the supplied uri is not
valid.
- * @throws IllegalArgumentException if the URI does not have "artifact"
+ * @throws UnsupportedSchemeException if the URI does not have "artifact"
* or "link" as its <strong>scheme</strong>.
*/
public static final Artifact createArtifact( String uri )
- throws URISyntaxException, IllegalArgumentException
+ throws URISyntaxException, UnsupportedSchemeException
{
if( null == uri )
{
@@ -117,11 +117,11 @@
*
* @param uri the artifact uri
* @return the new artifact
- * @throws IllegalArgumentException if the URI does not have "artifact"
+ * @throws UnsupportedSchemeException if the URI does not have "artifact"
* or "link" as its <strong>scheme</strong>.
*/
public static final Artifact createArtifact( URI uri )
- throws IllegalArgumentException
+ throws UnsupportedSchemeException
{
if( null == uri )
{

Modified: development/main/transit/standard.xml
==============================================================================
--- development/main/transit/standard.xml (original)
+++ development/main/transit/standard.xml Fri Jul 1 18:19:13 2005
@@ -384,7 +384,8 @@
<mkdir dir="${target.deliverables.jars.dir}"/>
<jar destfile="${target.deliverables.jars.dir}/${project.filename}"
basedir="${target.classes.dir}"
- includes="**/*.class,**/*.xml,**/*.properties">
+ includes="**/*.class,**/*.xml,**/*.properties"
+ excludes="**/*.html,**/*.gif,**/*.png">
<manifest>
<attribute name="Created-By" value="The Digital Product Meta
Library."/>
<attribute name="Built-By" value="${user.name}"/>



  • svn commit: r2946 - in development/main: metro/central/src/main/net/dpml/metro/central metro/composition/control/src/main/net/dpml/composition/control metro/composition/control/src/main/net/dpml/composition/runtime metro/part/src/main/net/dpml/part/control metro/part/src/main/net/dpml/part/manager transit transit/core/handler transit/core/handler/src/main/net/dpml/transit/artifact, mcconnell, 07/01/2005

Archive powered by MHonArc 2.6.24.

Top of Page