Class MongoCommand<T extends MongoCommand>
- java.lang.Object
-
- de.caluga.morphium.driver.commands.MongoCommand<T>
-
- Direct Known Subclasses:
AdminMongoCommand,CollStatsCommand,CountMongoCommand,CreateCommand,CurrentOpCommand,DbStatsCommand,DistinctMongoCommand,DropDatabaseMongoCommand,GenericCommand,GetMoreMongoCommand,HelloCommand,ListDatabasesCommand,ListIndexesCommand,ReadMongoCommand,ReplicastStatusCommand,SaslAuthCommand,WatchCommand,WriteMongoCommand
public abstract class MongoCommand<T extends MongoCommand> extends Object
-
-
Constructor Summary
Constructors Constructor Description MongoCommand(MongoConnection c)
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description Map<String,Object>asMap()voidclear()intexecuteAsync()TfromMap(Map<String,Object> m)StringgetColl()abstract StringgetCommandName()StringgetComment()MongoConnectiongetConnection()StringgetDb()Map<String,Object>getMetaData()will be set by the driver, containing information about total runtime (duration) host used (server) and other meta information about the execution of this commandvoidreleaseConnection()TsetColl(String coll)TsetComment(String c)MongoCommand<T>setConnection(MongoConnection connection)TsetDb(String db)MongoCommand<T>setMetaData(String key, Object value)MongoCommand<T>setMetaData(Map<String,Object> metaData)
-
-
-
Constructor Detail
-
MongoCommand
public MongoCommand(MongoConnection c)
-
-
Method Detail
-
releaseConnection
public void releaseConnection()
-
getConnection
public MongoConnection getConnection()
-
setConnection
public MongoCommand<T> setConnection(MongoConnection connection)
-
getDb
public String getDb()
-
getMetaData
public Map<String,Object> getMetaData()
will be set by the driver, containing information about total runtime (duration) host used (server) and other meta information about the execution of this command- Returns:
-
setMetaData
public MongoCommand<T> setMetaData(Map<String,Object> metaData)
-
setMetaData
public MongoCommand<T> setMetaData(String key, Object value)
-
getColl
public String getColl()
-
getComment
public String getComment()
-
clear
public void clear()
-
getCommandName
public abstract String getCommandName()
-
executeAsync
public int executeAsync() throws MorphiumDriverException- Throws:
MorphiumDriverException
-
-