Ets_Topo_Child_Count_Get()
Abstract
Returns the number of direct children of the specified type contained by the parent object.
Syntax
Ets_Topo_Child_Count_Get (parent_obj_hndl, child_type)
| Argument | Type | Description |
|---|---|---|
parent_obj_hndl |
EtsT_Obj_Handle |
Handle to parent object. |
child_type |
“EtsT_Obj_Type“ |
Value specifying the type or meta-type of child objects (one of the values in Table 33 “General Sub-Package Symbolic Constants“ on page 1046). |
Return Type
int
Number of child objects of the specified type.
Header
ets_api_topo.h
Details
When the parent object is a network subnet object, the children are the nodes, subnets, links, and annotations that reside directly in that subnet. When the parent object is a compound object, the children are the “rows” of that compound object.
The child_type argument can be either a specific object type (such as EtsC_Obj_Type_Node_Fix) or a general object meta-type (such as EtsC_Obj_Mtype_Link).
Paths have no children and do not belong to any subnet; hence this function returns zero if parent_obj_hndl references a path object or child_type equals EtsC_Obj_Type_Path.
The function Ets_Topo_Child_Get() will return an ETS object handle for each of the counted objects when called with the same parent object, the same object type, and an index ranging from zero (inclusive) and the count (exclusive).