CCeDBProp::CCeDBProp
Use this constructor to construct a CCeDBProp object.
Syntax
CCeDBProp( );
CCeDBProp( CCeDBProp::enType nType, WORD wIdent = 0, WORD wSortFlags = Sort_Ascending );
CCeDBProp( short iVal, WORD wIdent = 0 );
CCeDBProp( USHORT uiVal, WORD wIdent = 0 );
CCeDBProp( long lVal, WORD wIdent = 0 );
CCeDBProp( ULONG ulVal, WORD wIdent = 0 );
CCeDBProp( FILETIME filetime, WORD wIdent = 0 );
CCeDBProp( LPWSTR lpwstr, WORD wIdent = 0, CCeDBProp::enCopyMode nMode = Copy );
CCeDBProp( CEBLOB blob, WORD wIdent = 0, CCeDBProp::enCopyMode nMode = Copy );
CCeDBProp( CCeDBProp& prop );// copy constructor
At a Glance
Header file: |
Wcedb.h |
Platforms: |
|
Versions: |
2.0 and later |
Parameters
-
nType
-
The data type of the property, used only when constructing valueless properties. CCeDBProp::enType is an enumeration, that defines the following values.
-
CCeDBProp::Type_Short
-
A signed short integer.
-
CCeDBProp::Type_UShort
-
An unsigned short integer.
-
CCeDBProp::Type_Long
-
A signed long integer.
-
CCeDBProp::Type_ULong
-
An unsigned long integer.
-
CCeDBProp::Type_Filetime
-
A FILETIME structure.
-
CCeDBProp::Type_String
-
A null-terminated string. (This is a wide character array (WCHAR), not a CString object.)
-
CCeDBProp::Type_Blob
-
A CEBLOB structure.
-
wIdent
-
The property's application-defined identifier. The default value is zero.
-
wSortFlags
-
For a sort property, the flags that determine the sort order. This parameter can have one of the following values:
-
CCeDBProp::Sort_Ascending
-
The sort is done in ascending order.
-
CCeDBProp::Sort_CaseInsensitive
-
The sort operation is case insensitive. This value is valid only for strings.
-
CCeDBProp::Sort_Descending
-
The sort is done in descending order.
-
CCeDBProp::Sort_UnknownFirst
-
Records that do not contain the property identified by wIdent are placed before all the other records. By default, these records are placed after all other records.
-
iVal
-
A signed short integer value.
-
uiVal
-
An unsigned short integer value.
-
lVal
-
A signed long integer value.
-
ulVal
-
An unsigned long integer value.
-
filetime
-
A FILETIME structure, initialized with meaningful data.
-
lpwstr
-
A null-terminated string. (This must be a wide character array (WCHAR), not a CString object.)
-
blob
-
A CEBLOB structure, initialized with meaningful data.
-
nMode
-
A flag that specifies whether to allocate memory to store the passed in string or BLOB. This parameter can have one of the following values.
-
CCeDBProp::Copy
-
Allocate new memory. The property will have its own copy of the string or BLOB used to create it.
-
CCeDBProp::NoCopy
-
The property will maintain a pointer to the existing string or BLOB, but will not own it.
-
prop
-
The CCeDBProp object to be copied.
Remarks
The default constructor sets the property's value to (long) 0. The default sort flag is CCeDBProp::Sort_Ascending.
The overloaded constructor with the syntax CCeDBProp(CCeDBProp::enType nType, WORD wIdent , WORD wSortFlags) is used to create valueless properties. You use valueless properties to set a database's sort orders, and to create filters for reading and writing records. When you create valueless properties for filters, you ignore the wSortFlags parameter.
See Also
CCeDBProp Overview, CCeDBProp Member Functions, Windows CE Database Classes, CEBLOB, FILETIME