A connection is needed to be able to create TaminoCommands so that one can perform operations on the Tamino database.
For a list of all members of this type, see TaminoConnection Members.
System.Object
TaminoConnection
See CreateCommand for information about creating commands. See CreateSchemaCommand for information about creating schema commands.
A connection must be opened before it can be used (only the Diagnose method does not require the connection to be in the open state). A connection can be reused, using matching Open and Close methods.
The connection MUST be closed when finished with, in order to prevent resource leakage.
The following demonstrates a simple insert request.
// create connection TaminoConnection connection = new TaminoConnection("http://localhost/tamino/mydb"); // open connection connection.Open(TaminoConnectionMode.AutoCommit); // create command TaminoCommand command = connection.CreateCommand("mycollection"); // do simple insert TaminoResponse response = command.Insert(new TaminoDocument(xmlDoc)); Trace.Assert(response.ReturnValue == "0", response.ErrorText); // close connection connection.Close();
Namespace: SoftwareAG.Tamino.Api Namespace
Assembly: TaminoAPI.dll
TaminoConnection Members | SoftwareAG.Tamino.Api Namespace