class toQValue

# class toQValue | This function is used to represent values that are passed to and from queries More...
Definition | `#include <toqvalue.h>`
List of all Methods
Annotated List
Files
Globals
Hierarchy
Index

#### Public Methods

- toQValue (void)
- toQValue (int i)
- toQValue (const QString &str)
- toQValue (double d)
- ~toQValue ()
- toQValue (const toQValue ©)
- const toQValue & operator = (const toQValue ©)
- bool operator == (const toQValue &) const
- bool isInt (void) const
- bool isDouble (void) const
- bool isString (void) const
- bool isNull (void) const
- bool isBinary (void) const
- QCString utf8 (void) const
- int toInt (void) const
- double toDouble (void) const
- const QByteArray & toByteArray (void) const
- operator QString () const
- QString toString () const

#### Public Static Methods

- static void setNumberFormat (int format,int decimals)
- static QString formatNumber (double number)
- static int numberFormat (void)
- static int numberDecimals (void)
- static toQValue createBinary (const QByteArray &arr)
- static toQValue createFromHex (const QString &hex)
- static toQValue createFromHex (const QCString &hex)

## Detailed Description

This function is used to represent values that are passed to and from queries

toQValue (void) | ### toQValue

Create null value.

toQValue (int i) | ### toQValue

Create integer value.

Parameters:

i | Value.

toQValue (const QString &str) | ### toQValue

Create string value.

Parameters:

str | Value.

toQValue (double d) | ### toQValue

Create double value.

Parameters:

d | Value.

~toQValue () | ### ~toQValue

Destruct query.

toQValue (const toQValue ©) | ### toQValue

Create a copy of a value.

const toQValue & operator = (const toQValue ©) | ### operator =

Assign this value from another value.

bool operator == (const toQValue &) | ### operator ==

[const]

Check a value for equality. Requires same type and same value. NULL is equal to other NULL values.

bool isInt (void) | ### isInt

[const]

Check if this is an int value.

bool isDouble (void) | ### isDouble

[const]

Check if this is a double value.

bool isString (void) | ### isString

[const]

Check if this is a string value.

bool isNull (void) | ### isNull

[const]

Check if this value is null.

bool isBinary (void) | ### isBinary

[const]

Check if this value is binary.

QCString utf8 (void) | ### utf8

[const]

Get utf8 format of this value.

int toInt (void) | ### toInt

[const]

Get integer representation of this value.

double toDouble (void) | ### toDouble

[const]

Get double representation of this value.

const QByteArray & toByteArray (void) | ### toByteArray

[const]

Get binary representation of value. Can only be called when the data is actually binary.

operator QString () | ### QString

[const]

Convert value to a string. If binary convert to hex.

QString toString () | ### toString

[const]

Convert value to a string. If binary convert to hex.

void setNumberFormat (int format,int decimals) | ### setNumberFormat

[static]

Set numberformat.

Parameters:

format | 0 = Default, 1 = Scientific, 2 = Fixed Decimals
decimals | Number on decimals for fixed decimals.

QString formatNumber (double number) | ### formatNumber

[static]

Format a number according to current settings.

int numberFormat (void) | ### numberFormat

[static]

Get number format.

Returns: Format 0 = Default, 1 = Scientific, 2 = Fixed Decimals

int numberDecimals (void) | ### numberDecimals

[static]

Get decimals if fixed decimals.

toQValue createBinary (const QByteArray &arr) | ### createBinary

[static]

Create a binary value

toQValue createFromHex (const QString &hex) | ### createFromHex

[static]

Create a binary value from it's hex representation.

toQValue createFromHex (const QCString &hex) | ### createFromHex

[static]

Create a binary value from it's hex representation.

Generated by: nneul on skyhawk on Wed Feb 23 19:49:58 2005, using kdoc 2.0a54.