Ignore:
Timestamp:
09/26/11 22:55:19 (13 years ago)
Author:
sherbold
Message:

Major change to the Console provided by this library. The interface de.ugoe.cs.console.ConsoleObserver? is deprecated and split into the five interface IOutputListener, IErrorListener, ITraceListener, IExceptionListener, and ICommandListener.

The rational for this change is to provide the possibility to listen to only parts of what is send to the console to provide better capabilities for target-oriented handling of the different streams, e.g., for exception logging.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/JavaHelperLib/src/de/ugoe/cs/util/console/ConsoleObserver.java

    r186 r199  
    11package de.ugoe.cs.util.console; 
     2 
     3import de.ugoe.cs.util.console.listener.ICommandListener; 
     4import de.ugoe.cs.util.console.listener.IErrorListener; 
     5import de.ugoe.cs.util.console.listener.IExceptionListener; 
     6import de.ugoe.cs.util.console.listener.IOutputListener; 
     7import de.ugoe.cs.util.console.listener.ITraceListener; 
    28 
    39/** 
     
    713 *  
    814 * @author Steffen Herbold 
    9  * @version 1.0 
     15 * @version 2.0 
     16 * @deprecated Use listeners defined in the package de.ugoe.cs.console.listeners instead. 
    1017 */ 
    11 public interface ConsoleObserver { 
    12  
    13         /** 
    14          * <p> 
    15          * If a new message is send to the console, all observers are updated using 
    16          * this method. 
    17          * </p> 
    18          *  
    19          * @param newMessage 
    20          *            message that was send to the console. 
    21          */ 
    22         public void updateText(String newMessage); 
    23  
    24         /** 
    25          * <p> 
    26          * Send messages to the error stream of all observers. 
    27          * </p> 
    28          *  
    29          * @param errMessage 
    30          *            error message 
    31          */ 
    32         public void errStream(String errMessage); 
    33  
    34         /** 
    35          * <p> 
    36          * Send messages to the trace stream of all observers. 
    37          * </p> 
    38          *  
    39          * @param traceMesssage 
    40          *            error message 
    41          */ 
    42         public void trace(String traceMessage); 
    43  
    44         /** 
    45          * <p> 
    46          * Prints the stack trace of an exception. 
    47          * </p> 
    48          *  
    49          * @param e 
    50          *            exception whose stack trace is to be printed 
    51          */ 
    52         public void printStacktrace(Exception e); 
    53  
    54         /** 
    55          * <p> 
    56          * Receives the command strings of all executed commands. 
    57          * </p> 
    58          *  
    59          * @param command 
    60          *            string of the command. 
    61          */ 
    62         public void commandNotification(String command); 
     18public interface ConsoleObserver extends ITraceListener, IOutputListener, IErrorListener, ICommandListener, IExceptionListener { 
    6319 
    6420} 
Note: See TracChangeset for help on using the changeset viewer.