Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.cassandra.cli
Class CliMain

    java.lang.Object
      org.apache.cassandra.cli.CliMain

    public class CliMain

extends java.lang.Object

Cassandra Command Line Interface (CLI) Main

Field Summary
`static java.lang.String` | `HISTORYFILE`
`static CliSessionState` | `sessionState`

Constructor Summary
`CliMain()`

Method Summary
`static void` | `connect(java.lang.String server, int port)` Establish a thrift connection to cassandra instance
`static void` | `disconnect()` Disconnect thrift connection to cassandra instance
`static boolean` | `isConnected()` Checks whether the thrift client is connected.
`static void` | `main(java.lang.String[] args)`
`static void` | `processStatement(java.lang.String query)`
`static void` | `processStatementInteractive(java.lang.String query)`
`static void` | `updateCompletor(java.util.Set<java.lang.String> candidates)`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### HISTORYFILE

    public static final java.lang.String HISTORYFILE

See Also:
  Constant Field Values

### sessionState

    public static CliSessionState sessionState

Constructor Detail

### CliMain

    public CliMain()

Method Detail

### connect

    public static void connect(java.lang.String server,
                               int port)

  Establish a thrift connection to cassandra instance

  Parameters:
    `server` - - hostname or IP of the server
    `port` - - Thrift port number

### disconnect

    public static void disconnect()

  Disconnect thrift connection to cassandra instance

### isConnected

    public static boolean isConnected()

  Checks whether the thrift client is connected.

  Returns:
    boolean - true when connected, false otherwise

### updateCompletor

    public static void updateCompletor(java.util.Set<java.lang.String> candidates)

### processStatement

    public static void processStatement(java.lang.String query)
                                 throws java.nio.charset.CharacterCodingException,
                                        java.lang.ClassNotFoundException,
                                        org.apache.thrift.TException,
                                        TimedOutException,
                                        SchemaDisagreementException,
                                        NotFoundException,
                                        InvalidRequestException,
                                        java.lang.NoSuchFieldException,
                                        UnavailableException,
                                        java.lang.IllegalAccessException,
                                        java.lang.InstantiationException

  Throws:
    `java.nio.charset.CharacterCodingException`
    `java.lang.ClassNotFoundException`
    `org.apache.thrift.TException`
    `TimedOutException`
    `SchemaDisagreementException`
    `NotFoundException`
    `InvalidRequestException`
    `java.lang.NoSuchFieldException`
    `UnavailableException`
    `java.lang.IllegalAccessException`
    `java.lang.InstantiationException`

### processStatementInteractive

    public static void processStatementInteractive(java.lang.String query)

### main

    public static void main(java.lang.String[] args)
                     throws java.io.IOException

  Throws:
    `java.io.IOException`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2013 The Apache Software Foundation