getCardinality()

Retrieves the cardinality of an attribute.

Syntax

char * getCardinality();

Parameters

None.

Return values

The cardinality of an attribute:

1
Indicates that the attribute has single cardinality: it can reference one child business object.

n
Indicates that the attribute has multiple cardinality: it can reference multiple child business objects.

Notes

Cardinality defines whether an attribute references a single child business object or an array of child business objects. This operation applies only to attributes that contain a business object. If the attribute does not contain a business object, the getCardinality() method returns the value 1.

See also

hasCardinality(), isMultipleCard()

Copyright IBM Corp. 1997, 2004