|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.mymed.controller.core.manager.connection.Connection
public class Connection
Class that represents a connection to a Cassandra instance in mymed
Constructor Summary | |
---|---|
Connection()
Create a new connection using as address the localhost address and the default value for the port (9160). |
|
Connection(java.lang.String address,
int port)
Create a new connection with the provided address and port |
Method Summary | |
---|---|
void |
close()
Close the connection to the database |
boolean |
equals(java.lang.Object object)
|
void |
flush()
Flush the connection, resetting its internal state |
java.lang.String |
getAddress()
Get the address in use with the connection |
org.apache.cassandra.thrift.Cassandra.Client |
getClient()
|
int |
getPort()
Get the port in use with the connection |
int |
hashCode()
|
boolean |
isOpen()
Check if the connection is open or not |
void |
open()
Open the connection to the database |
Methods inherited from class java.lang.Object |
---|
getClass, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Connection()
public Connection(java.lang.String address, int port)
address
- the IP address to be associated with this connectionport
- the port to use with this connection
java.lang.Exception
Method Detail |
---|
public org.apache.cassandra.thrift.Cassandra.Client getClient()
public java.lang.String getAddress()
IConnection
getAddress
in interface IConnection
public int getPort()
IConnection
getPort
in interface IConnection
public boolean isOpen()
IConnection
isOpen
in interface IConnection
public void open() throws InternalBackEndException
IConnection
open
in interface IConnection
InternalBackEndException
- when there is a problem opening the connectionpublic void close()
IConnection
close
in interface IConnection
public void flush()
IConnection
flush
in interface IConnection
public int hashCode()
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object object)
equals
in class java.lang.Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |