FDO API Reference Feature Data Objects
Main Page | Modules | Class Hierarchy | Alphabetical List | Class List | File List | Class Members | File Members

FdoPropertyValueConstraintList Class Reference

#include <PropertyValueConstraintList.h>

Inherits FdoPropertyValueConstraint.

Inheritance diagram for FdoPropertyValueConstraintList:

[legend]
List of all members.

Detailed Description

FdoPropertyValueConstraintList is used to specify a list of allowed values for a particular property. It can be used for all data property types except for Boolean, BLOB, or CLOB. This constraint is represented by a list of values of the same type as the corresponding data property. The list cannot be empty. The list could be a single value. While that may not seem very useful it could serve as a temporary way to enforce a single value for a property, e.g. for a particular customer, Parcel.State is always 'CA' In this case, the definer of the property definition probably should also set the default value to be the same, unless it can be null. The list does not need to be ordered. However, a provider may choose to reorder the list so the list that is returned when a user gets the definition of this constraint for a property may be different than the order that was given when defined. E.g. defined as (12, 8, 24), but returned as (8, 12, 24). If the list has duplicate values, the provider may choose to eliminate duplicates from the list. If the data property definition allows nulls, a null value is considered as being valid regardless of this list of valid values. The list of valid values should not include the null value itself, but leave the specification of whether null is allowed to the null value constraint. If the data property definition includes a non-null default value, then that value should be one of the values in the list. If both a valid values list constraint and a unique constraint on the same property are included, then the side effect is that there will be an upper limit of the number of objects of that class that have non-null values for the property.

Definition at line 46 of file PropertyValueConstraintList.h.


Public Member Functions

virtual bool Equals (FdoPropertyValueConstraint *pConstraint)
FDO_API FdoDataValueCollectionGetConstraintList ()
 Returns the list of allowed values for a particular property.
virtual FDO_API FdoPropertyValueConstraintType GetConstraintType ()
 Returns FdoPropertyValueConstraintType_Range type.
virtual void Set (FdoPropertyValueConstraint *pProperty, FdoString *parentName, FdoSchemaMergeContext *pContext)
 Update this list constraint from the given value constraint.

Static Public Member Functions

FDO_API FdoPropertyValueConstraintListCreate ()
 Constructs an empty instance of an FdoPropertyValueConstraintList.

Protected Member Functions

virtual void Dispose ()
 Dispose this object.
 FdoPropertyValueConstraintList ()
 Constructs a default instance of a FdoPropertyValueConstraintList.
virtual ~FdoPropertyValueConstraintList ()

Friends

class FdoInternalPropertyValueConstraintList

Constructor & Destructor Documentation

FdoPropertyValueConstraintList::FdoPropertyValueConstraintList  )  [protected]
 

Constructs a default instance of a FdoPropertyValueConstraintList.

virtual FdoPropertyValueConstraintList::~FdoPropertyValueConstraintList  )  [protected, virtual]
 


Member Function Documentation

FDO_API FdoPropertyValueConstraintList* FdoPropertyValueConstraintList::Create  )  [static]
 

Constructs an empty instance of an FdoPropertyValueConstraintList.

Returns:
Returns an FdoPropertyValueConstraintList

virtual void FdoPropertyValueConstraintList::Dispose  )  [inline, protected, virtual]
 

Dispose this object.

Returns:
Returns nothing

Implements FdoIDisposable.

Definition at line 56 of file PropertyValueConstraintList.h.

virtual bool FdoPropertyValueConstraintList::Equals FdoPropertyValueConstraint pConstraint  )  [virtual]
 

Implements FdoPropertyValueConstraint.

FDO_API FdoDataValueCollection* FdoPropertyValueConstraintList::GetConstraintList  ) 
 

Returns the list of allowed values for a particular property.

Returns:
Returns na instance of FdoDataValueCollection.

virtual FDO_API FdoPropertyValueConstraintType FdoPropertyValueConstraintList::GetConstraintType  )  [virtual]
 

Returns FdoPropertyValueConstraintType_Range type.

Returns:
Returns the constraint type

Implements FdoPropertyValueConstraint.

virtual void FdoPropertyValueConstraintList::Set FdoPropertyValueConstraint pProperty,
FdoString parentName,
FdoSchemaMergeContext pContext
[virtual]
 

Update this list constraint from the given value constraint.

Reimplemented from FdoPropertyValueConstraint.


Friends And Related Function Documentation

friend class FdoInternalPropertyValueConstraintList [friend]
 

Definition at line 48 of file PropertyValueConstraintList.h.


The documentation for this class was generated from the following file:
Comments or suggestions? Send us feedback.