Unicorn XML Toolkit
Version 1.00.00

Namespace Sql
Class CNullParam

class CNullParam {
public:
    CNullParam();
    ~CNullParam();
public:
    void Add(bool bValue, const CString &strValue);
    int GetSize() const;
    bool GetAt(int nIndex, CString &strValue) const;
    void RemoveAll();
    };

The array of null-indicators.

This array is passed to functions responsible for execution of SQL statements in order to specify, which parameter values must be interpreted as SQL null values.

See CSqlStatement for more information about null-indicators.

Since:
1.00.00
Version:
1.00.00
Author:
Alexey Gokhberg
Constructor/Destructor Summary
CNullParam ();
����������Constructs the array of null-indicators.
~CNullParam ();
����������Destroys the array of null-indicators.

Function Summary
void Add (bool bValue, const CString &strValue);
����������Adds the element to this array of null-indicators.
int GetSize () const;
����������Returns the number of elements in this array of null-indicators.
bool GetAt (int nIndex, CString &strValue) const;
����������Returns the element at the given index in this array of null-indicators.
void RemoveAll ();
����������Removes all elements from this array of null-indicators.

Constructor/Destructor Detail

CNullParam

CNullParam();

Constructs the array of null-indicators.

The array is initially empty.

~CNullParam

~CNullParam();

Destroys the array of null-indicators.

Function Detail

Add

void Add(bool bValue, const CString &strValue);

Adds the element to this array of null-indicators.

This function requires two arguments. The first argument is a boolean which specifies, whether any value must be interpreted as null for the corresponding parameter of the SQL statement. If this argument is true , there exists a particular value that is interpreted as null; this value must be suppled as the second argument. If the first argument is false , there is no value interpreted as null, and the second argument is not used (must be the empty string in this case).

Parameters:
bValue - specifies whether the null-indicator value is available
strValue - the null-indicator value

GetSize

int GetSize() const;

Returns the number of elements in this array of null-indicators.

Returns:
the number of elements in this array of null-indicators

GetAt

bool GetAt(int nIndex, CString &strValue) const;

Returns the element at the given index in this array of null-indicators.

Parameters:
nIndex - the index (zero-based)
strValue - on return, the null-indicator value at the specified index
Returns:
true if for the specified index there exists a particular value that is interpreted as null; false otherwise

RemoveAll

void RemoveAll();

Removes all elements from this array of null-indicators.


Unicorn XML Toolkit
Version 1.00.00


This document was created using Unicorn DOC++.

Copyright 1999-2001 Unicorn Enterprises SA.
All Rights Reserved.