File Source: Window.java

         /* 
    P/P   *  Method: com.dmdirc.ui.interfaces.Window__static_init
          */
     1  /*
     2   * Copyright (c) 2006-2009 Chris Smith, Shane Mc Cormack, Gregory Holmes
     3   *
     4   * Permission is hereby granted, free of charge, to any person obtaining a copy
     5   * of this software and associated documentation files (the "Software"), to deal
     6   * in the Software without restriction, including without limitation the rights
     7   * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
     8   * copies of the Software, and to permit persons to whom the Software is
     9   * furnished to do so, subject to the following conditions:
    10   *
    11   * The above copyright notice and this permission notice shall be included in
    12   * all copies or substantial portions of the Software.
    13   *
    14   * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
    15   * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
    16   * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
    17   * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
    18   * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
    19   * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
    20   * SOFTWARE.
    21   */
    22  
    23  package com.dmdirc.ui.interfaces;
    24  
    25  import com.dmdirc.FrameContainer;
    26  import com.dmdirc.util.StringTranscoder;
    27  import com.dmdirc.config.ConfigManager;
    28  
    29  /**
    30   * The Window interface specifies common methods that should be implemented
    31   * by all windows. It is assumed that all windows have a main text area.
    32   */
    33  public interface Window {
    34      
    35      /**
    36       * Formats the arguments using the Formatter, then adds the result to the
    37       * main text area.
    38       *
    39       * @param messageType The type of this message
    40       * @param args The arguments for the message
    41       */
    42      void addLine(String messageType, Object... args);
    43      
    44      /**
    45       * Formats the arguments using the Formatter, then adds the result to the
    46       * main text area.
    47       *
    48       * @param messageType The type of this message
    49       * @param args The arguments for the message
    50       */
    51      void addLine(StringBuffer messageType, Object... args);
    52      
    53      /**
    54       * Adds the specified raw line to the window, without using a formatter.
    55       * 
    56       * @param line The line to be added
    57       * @param timestamp Whether or not to display the timestamp for this line
    58       */
    59      void addLine(final String line, final boolean timestamp);
    60      
    61      /**
    62       * Clears the main text area of the command window.
    63       */
    64      void clear();
    65      
    66      /**
    67       * Retrieves the config manager for this command window.
    68       *
    69       * @return This window's config manager
    70       */
    71      ConfigManager getConfigManager();
    72      
    73      /**
    74       * Retrieves the container that owns this command window.
    75       *
    76       * @return The container that owns this command window.
    77       */
    78      FrameContainer getContainer();
    79      
    80      /**
    81       * Determines if the current window is visible.
    82       *
    83       * @return boolean visibility
    84       */
    85      boolean isVisible();
    86      
    87      /**
    88       * Sets the visibility of this window.
    89       * 
    90       * @param isVisible Whether the window should be visible or not
    91       */
    92      void setVisible(boolean isVisible);
    93      
    94      /**
    95       * Retrives the current title of this window.
    96       * 
    97       * @return This window's title
    98       */
    99      String getTitle();
   100      
   101      /**
   102       * Determines if this frame is currently maximised.
   103       * 
   104       * @return true if the frame is maximised, false otherwise
   105       */
   106      boolean isMaximum();
   107      
   108      /**
   109       * Sets the title of this window.
   110       * 
   111       * @param title The new title to be used.
   112       */
   113      void setTitle(String title);
   114      
   115      /**
   116       * Opens this window.
   117       */
   118      void open();
   119      
   120      /**
   121       * Restores this window.
   122       * 
   123       * @since 0.6.3m1
   124       */
   125      void restore();
   126      
   127      
   128      /** 
   129       * Maximises this window.
   130       * 
   131       * @since 0.6.3m1
   132       */
   133      void maximise();
   134      
   135      /**
   136       * Toggles Maximise State.
   137       * 
   138       * @since 0.6.3m1
   139       */
   140      void toggleMaximise();
   141      
   142      /**
   143       * Minimises this window.
   144       */
   145      void minimise();
   146      
   147      /**
   148       * Returns the transcoder that is being used by the UI.
   149       * 
   150       * @return This window's transcoder
   151       */
   152      StringTranscoder getTranscoder();
   153      
   154      /** Closes this window. */
   155      void close();
   156  
   157      /**
   158       * Requests that this object's frame be activated.
   159       */
   160      public void activateFrame();
   161      
   162  }








SofCheck Inspector Build Version : 2.17854
Window.java 2009-Jun-25 01:54:24
Window.class 2009-Sep-02 17:04:12