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-excalibur/src/scratchpad/org/apache/avalon/excalibur/event Command.java Message.java
Date Wed, 19 Dec 2001 18:13:49 GMT
bloritsch    01/12/19 10:13:49

  Added:       src/scratchpad/org/apache/avalon/excalibur/event
                        Command.java Message.java
  Log:
  add new QueueElement types
  
  Revision  Changes    Path
  1.1                  jakarta-avalon-excalibur/src/scratchpad/org/apache/avalon/excalibur/event/Command.java
  
  Index: Command.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.excalibur.event;
  
  import org.apache.avalon.framework.activity.Executable;
  
  /**
   * A Signal is a specific type of QueueElement that denotes a Control code for
   * the Queue system.
   *
   * @author <a href="mailto:bloritsch@apache.org">Berin Loritsch</a>
   */
  public interface Command extends Signal, Executable
  {
      /**
       * Test whether this command is repeatable.  If so, it will be placed back
       * on the CommandQueue to be issued again when it is time.
       */
      boolean isRepeatable();
  
      /**
       * Gets the repeat interval so that the CommandQueue keeps it for the specified
       * amount of time before enqueuing it.  If the Command is not repeatable,
       * then the repeat interval is -1.
       */
      long getRepeatInterval();
  }
  
  
  1.1                  jakarta-avalon-excalibur/src/scratchpad/org/apache/avalon/excalibur/event/Message.java
  
  Index: Message.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.excalibur.event;
  
  /**
   * A Source implements the side of an event queue where QueueElements are
   * dequeued operations only.
   *
   * @author <a href="mailto:bloritsch@apache.org">Berin Loritsch</a>
   */
  public interface Message extends QueueElement
  {
      /**
       * Get the attachment associated with this Message.  If there is no
       * attachment, this method will return null.
       */
      Object getAttachment();
  
      /**
       * Attach an Object to the message.
       */
      void attach( Object attachment );
  
      /**
       * Clear the attachment.
       */
      void clear();
  }
  
  

--
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