avalon-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From blorit...@apache.org
Subject cvs commit: jakarta-avalon-cornerstone/src/java/org/apache/avalon/cornerstone/services/silk NoSuchSinkException.java SinkMap.java Stage.java NoSuchSourceException.java SourceMap.java
Date Mon, 04 Feb 2002 18:04:30 GMT
bloritsch    02/02/04 10:04:30

  Modified:    src/java/org/apache/avalon/cornerstone/services/silk
                        Stage.java
  Added:       src/java/org/apache/avalon/cornerstone/services/silk
                        NoSuchSinkException.java SinkMap.java
  Removed:     src/java/org/apache/avalon/cornerstone/services/silk
                        NoSuchSourceException.java SourceMap.java
  Log:
  Rename Source to Sink, make Stage an EventHandler
  
  Revision  Changes    Path
  1.2       +4 -3      jakarta-avalon-cornerstone/src/java/org/apache/avalon/cornerstone/services/silk/Stage.java
  
  Index: Stage.java
  ===================================================================
  RCS file: /home/cvs/jakarta-avalon-cornerstone/src/java/org/apache/avalon/cornerstone/services/silk/Stage.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- Stage.java	1 Feb 2002 20:06:24 -0000	1.1
  +++ Stage.java	4 Feb 2002 18:04:30 -0000	1.2
  @@ -8,6 +8,7 @@
   package org.apache.avalon.cornerstone.services.silk;
   
   import org.apache.avalon.framework.component.Component;
  +import org.apache.avalon.excalibur.event.EventHandler;
   
   /**
    * The Stage is a specialized type of Component.  It allows the system to be set
  @@ -33,10 +34,10 @@
    * </p>
    *
    * @author <a href="bloritsch@apache.org">Berin Loritsch</a>
  - * @version CVS $Revision: 1.1 $ $Date: 2002/02/01 20:06:24 $
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 18:04:30 $
    */
   
  -public interface Stage extends Component {
  +public interface Stage extends Component, EventHandler {
       /**
        * Sets the SourceMap for the Stage.  This allows the stage to specify
        * exactly what Source we are feeding with events.  The SourceMap is set
  @@ -44,5 +45,5 @@
        * be simple components, and the SourceMap is the last method to be called
        * during initialization.
        */
  -    void setSourceMap( SourceMap map );
  +    void setSinkMap( SinkMap map );
   }
  
  
  
  1.1                  jakarta-avalon-cornerstone/src/java/org/apache/avalon/cornerstone/services/silk/NoSuchSinkException.java
  
  Index: NoSuchSinkException.java
  ===================================================================
  /*
   * Copyright (C) The Apache Software Foundation, All rights reserved.
   *
   * This software is published under the terms of the Apache Software License
   * version 1.1, a copy of which has been included with this distribution in
   * the LICENSE.txt file.
   */
  package org.apache.avalon.cornerstone.services.silk;
  
  /**
   * The NoSuchSinkException is used by the SinkMap when a Sink that is
   * supposed to be associated with a name is not found.
   *
   * @author <a href="bloritsch@apache.org">Berin Loritsch</a>
   * @version CVS $Revision: 1.1 $ $Date: 2002/02/04 18:04:30 $
   */
  
  public class NoSuchSinkException extends Exception {
  
      public NoSuchSinkException()
      {
          super();
      }
  
      public NoSuchSinkException( String message )
      {
          super( message );
      }
  }
  
  
  1.1                  jakarta-avalon-cornerstone/src/java/org/apache/avalon/cornerstone/services/silk/SinkMap.java
  
  Index: SinkMap.java
  ===================================================================
  /*
   * Copyright (C) The Apache Software Foundation, All rights reserved.
   *
   * This software is published under the terms of the Apache Software License
   * version 1.1, a copy of which has been included with this distribution in
   * the LICENSE.txt file.
   */
  package org.apache.avalon.cornerstone.services.silk;
  
  import org.apache.avalon.excalibur.event.Sink;
  
  /**
   * The SinkMap is an abstraction to allow the container to centrally manage all
   * connections within its scope.  This allows the system to remain using Inversion
   * of Control, while allowing a system to be reassigned at any time.
   *
   * @author <a href="bloritsch@apache.org">Berin Loritsch</a>
   * @version CVS $Revision: 1.1 $ $Date: 2002/02/04 18:04:30 $
   */
  
  public interface SinkMap {
  
      /**
       * This gets the main Sink for the SinkMap.  A SinkMap must have at
       * least one Source.
       *
       * @return the main <code>Sink</code> for the SourceMap.
       */
      Sink getMainSink();
  
      /**
       * Get the named Source.  If the SourceMap does not contain a match for the
       * name, the method throws an exception.
       *
       * @param  name  The name of the desired source
       *
       * @return Sink the source associated with the name
       * @throws NoSuchSinkException if no source is associated with the name
       */
      Sink getSource( String name )
          throws NoSuchSinkException;
  
      /**
       * The SourceArray allows the Stage to get an array of all Sources attached
       * to the stage.
       *
       * @return an array of <code>Sink</code> objects.  There is at least one
       *         Sink in the array.
       */
      Sink[] getSinkArray();
  }
  
  

--
To unsubscribe, e-mail:   <mailto:avalon-cvs-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:avalon-cvs-help@jakarta.apache.org>


Mime
View raw message