Tamino API for .NET

TaminoConnection Class

Represents a connection to a Tamino database.

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

[Visual Basic]
Public Class TaminoConnection
[C#]
public class TaminoConnection

Remarks

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.

Example

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();
            

Requirements

Namespace: SoftwareAG.Tamino.Api Namespace

Assembly: TaminoAPI.dll

See Also

TaminoConnection Members | SoftwareAG.Tamino.Api Namespace