Product Documentation

c-treeDB API for C# - Developers Guide

Previous Topic

Next Topic

Scalar Types

c-treeDB .NET takes advantage of the vast choice of types available in .NET and uses these types every time it is possible.

Users that are accustomed with standard FairCom DB or c-treeDB types may still use these types provided a mapping is established as explained later.

The following table shows some of the c-tree types mapped to corresponding .NET types.

c-tree Plus/c-treeDB

.NET

TEXT

char (System.Char)

UTEXT

byte (System.Byte)

COUNT

short (System.Int16)

UCOUNT

ushort (System.UInt16)

NINT

int (System.Int32)

UINT

uint (System.UInt32)

LONG

int (System.Int32)

ULONG

uint (System.UInt32)

CTTIME

uint (System.UInt32)

VRLEN

int (System.Int32)

pVOID

Intptr

CTBOOL

bool (Sustem.Boolean)

CTSIGNED

int (System.Int32)

CTUNSIGNED

uint (System.UInt32)

DOUBLE

double (System.Double)

CTFLOAT

single (System.Single)

CTHANDLE

IntPtr (System.IntPtr)

The usual c-tree types may still be used provided they are mapped to .NET types with the following syntax:

C#

using CTHANDLE = System.IntPtr;

VB.NET

Imports CTHANDLE = System.IntPtr

The CTString class used by c-treeDB is not used in c-treeDB .NET. Instead, the standard .NET String class for unvariable strings or the StringBuilder class is used.

TOCIndex