Interface IParent

All Known Subinterfaces:
IArchive, IArchiveContainer, IBinary, IBinaryContainer, IBinaryModule, ICContainer, ICModel, ICProject, IEnumeration, IIncludeReference, ILibraryReference, INamespace, ISourceRoot, IStructure, IStructureTemplate, ITranslationUnit, IWorkingCopy

public interface IParent
Common protocol for C elements that contain other C elements.
  • Method Summary

    Modifier and Type
    Method
    Description
    Returns the immediate children of this element.
    returns the children of a certain type
    boolean
    Returns whether this element has one or more immediate children.
  • Method Details

    • getChildren

      ICElement[] getChildren() throws CModelException
      Returns the immediate children of this element. The children are in no particular order.
      Throws:
      CModelException - if this element does not exist or if an exception occurs while accessing its corresponding resource
    • getChildrenOfType

      List<ICElement> getChildrenOfType(int type) throws CModelException
      returns the children of a certain type
      Throws:
      CModelException
    • hasChildren

      boolean hasChildren()
      Returns whether this element has one or more immediate children. This is a convenience method, and may be more efficient than testing whether getChildren() returns an empty array.