Class MongoDatabaseInteraction
java.lang.Object
org.eclipse.persistence.internal.nosql.adapters.mongo.MongoDatabaseInteraction
- All Implemented Interfaces:
Interaction
Interaction to Mongo JCA adapter.
Executes the interaction spec to enqueue or dequeue a message.
- Since:
- EclipseLink 2.4
-
Field Summary
Modifier and TypeFieldDescriptionprotected MongoDatabaseConnection
Store the connection the interaction was created from. -
Constructor Summary
ConstructorDescriptionMongoDatabaseInteraction
(MongoDatabaseConnection connection) Default constructor. -
Method Summary
Modifier and TypeMethodDescriptioncom.mongodb.BasicDBObject
buildDBObject
(MongoRecord record) Build the Mongo DBObject from the Map record.org.bson.Document
buildDocument
(MongoRecord record) Build the Mongo Document from the Map record.buildRecordFromDBObject
(org.bson.Document object) Build the Map record from the Mongo Document.void
void
close()
execute
(InteractionSpec spec, Record record) Execute the interaction and return output record.boolean
execute
(InteractionSpec spec, Record input, Record output) Output records are not supported/required.
-
Field Details
-
connection
Store the connection the interaction was created from.
-
-
Constructor Details
-
MongoDatabaseInteraction
Default constructor.
-
-
Method Details
-
clearWarnings
public void clearWarnings()- Specified by:
clearWarnings
in interfaceInteraction
-
close
public void close()- Specified by:
close
in interfaceInteraction
-
execute
Output records are not supported/required.- Specified by:
execute
in interfaceInteraction
- Throws:
ResourceException
-
execute
Execute the interaction and return output record. The spec is either GET, PUT or DELETE interaction.- Specified by:
execute
in interfaceInteraction
- Throws:
ResourceException
-
buildDBObject
Build the Mongo DBObject from the Map record. -
buildDocument
Build the Mongo Document from the Map record. -
buildRecordFromDBObject
Build the Map record from the Mongo Document. -
getConnection
- Specified by:
getConnection
in interfaceInteraction
-
getWarnings
- Specified by:
getWarnings
in interfaceInteraction
-