org.scale7.cassandra.pelops
Interface IConnection

All Known Subinterfaces:
IThriftPool.IPooledConnection
All Known Implementing Classes:
CachePerNodePool.PooledConnection, CommonsBackedPool.PooledConnection, Connection, DebuggingPool.PooledConnection

public interface IConnection


Nested Class Summary
static class IConnection.Config
           
 
Method Summary
 void close()
          Close the connection.
 org.apache.cassandra.thrift.Cassandra.Client getAPI()
          Get a reference to the Cassandra Thrift API
 Cluster.Node getNode()
          Get a node this instance is connected to.
 boolean isOpen()
          Used to determine if the connection is open.
 boolean open()
          Opens a connection.
 

Method Detail

getAPI

org.apache.cassandra.thrift.Cassandra.Client getAPI()
Get a reference to the Cassandra Thrift API

Returns:
The raw Thrift interface

getNode

Cluster.Node getNode()
Get a node this instance is connected to.

Returns:
the node

isOpen

boolean isOpen()
Used to determine if the connection is open.

Returns:
true if the connection is open, otherwise false

open

boolean open()
Opens a connection.

Returns:
true if the connection was opened, otherwise false

close

void close()
Close the connection.



Copyright © 2011. All Rights Reserved.