org.objectweb.cjdbc.console.text
Class ConsoleLauncher

java.lang.Object
  extended byorg.objectweb.cjdbc.console.text.ConsoleLauncher

public class ConsoleLauncher
extends java.lang.Object

This class defines a ConsoleLauncher

Version:
1.0
Author:
Nicolas Modrzyk , Mathieu Peltier

Constructor Summary
ConsoleLauncher()
           
 
Method Summary
private static org.apache.commons.cli.Options createOptions()
          Creates Options object that contains all available options that can be used launching C-JDBC console.
static void main(java.lang.String[] args)
          Launchs the C-JDBC console.
private static void printUsage(org.apache.commons.cli.Options options)
          Displays usage message.
static void startGuiConsole()
          Starts the gui
static void startTextConsole(org.apache.commons.cli.CommandLine commandLine)
          Starts the text console with the given commandline
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ConsoleLauncher

public ConsoleLauncher()
Method Detail

main

public static void main(java.lang.String[] args)
                 throws java.lang.Exception
Launchs the C-JDBC console. The available options are:
  • -d or --debug: show stack trace when error occurs.
  • -f or --file: use a given file as the source of commands instead of reading commands interactively.
  • -h or --help: displays usage information.
  • -i or --ip: IP address of the host name where the JMX Server hosting the controller is running (the default is '0.0.0.0').
  • -n or --nocolor: do not print colors in interactive mode for supported systems.
  • -p or --port: JMX/RMI Port number of (the default is JmxConstants.DEFAULT_JMX_RMI_PORT).
  • -s or --secret: password for JMX connection.
  • -u or --username: username for JMX connection.
  • -v or --version: displays version information.
  • Parameters:
    args - command line arguments (see above)
    Throws:
    java.lang.Exception - if fails

    startGuiConsole

    public static void startGuiConsole()
                                throws java.lang.Exception
    Starts the gui

    Throws:
    java.lang.Exception - if cannot load gui(probably no graphics)

    startTextConsole

    public static void startTextConsole(org.apache.commons.cli.CommandLine commandLine)
                                 throws java.lang.Exception
    Starts the text console with the given commandline

    Parameters:
    commandLine - parameters for the text console
    Throws:
    java.lang.Exception - if fails

    createOptions

    private static org.apache.commons.cli.Options createOptions()
    Creates Options object that contains all available options that can be used launching C-JDBC console.

    Returns:
    an Options instance

    printUsage

    private static void printUsage(org.apache.commons.cli.Options options)
    Displays usage message.

    Parameters:
    options - available command line options


    Copyright © 2002, 2005 - ObjectWeb Consortium - All Rights Reserved.