public interface Client
Modifier and Type | Method and Description |
---|---|
void |
close()
Closes the client.
|
ClusterType |
getClusterType()
Returns the type of cluster the client is connected to.
|
MongoDbConfiguration |
getConfig()
Returns the configuration being used by the logical MongoDB connection.
|
Durability |
getDefaultDurability()
Returns the
Durability from the MongoDbConfiguration . |
ReadPreference |
getDefaultReadPreference()
Returns the
ReadPreference from the MongoDbConfiguration . |
String |
send(Message message,
Callback<Reply> replyCallback)
Sends a message on the connection.
|
String |
send(Message message1,
Message message2,
Callback<Reply> replyCallback)
Sends a message on the connection.
|
void close()
ClusterType getClusterType()
MongoDbConfiguration getConfig()
Durability getDefaultDurability()
Durability
from the MongoDbConfiguration
.MongoDbConfiguration
.ReadPreference getDefaultReadPreference()
ReadPreference
from the MongoDbConfiguration
.MongoDbConfiguration
.String send(Message message, Callback<Reply> replyCallback) throws MongoDbException
message
- The message to send on the connection.replyCallback
- The callback to notify of responses to the messages. May be
null
.MongoDbException
- On an error sending the message.String send(Message message1, Message message2, Callback<Reply> replyCallback) throws MongoDbException
message1
- The first message to send on the connection.message2
- The second message to send on the connection.replyCallback
- The callback to notify of responses to the message2
.
May be null
.MongoDbException
- On an error sending the message.Copyright © 2011-2012 Allanbank Consulting, Inc.. All Rights Reserved.