Main Page Modules Class Hierarchy Compound List File List Compound Members

# cSubModIterator Class Reference

`#include <cmodule.h>`

List of all members.

## Public Methods

| cSubModIterator (const cModule &p)
void | init (const cModule &p)
cModule& | operator[] (int)
cModule* | operator() ()
bool | end () const
cModule* | operator++ (int)

## Detailed Description

Iterates through submodules of a compound module.

## Constructor & Destructor Documentation

cSubModIterator::cSubModIterator ( | const cModule & p )`[inline]`

| Constructor. It takes the parent module.

## Member Function Documentation

bool cSubModIterator::end ( | ) const`[inline]`

| Returns true of the iterator has reached the end of the list.

void cSubModIterator::init ( | const cModule & p )`[inline]`

| Reinitializes the iterator.

cModule * cSubModIterator::operator() ( | )`[inline]`

| Returns pointer to the current module. The pointer then may be cast to the appropriate cModule subclass. Returns NULL of the iterator has reached the end of the list.

cModule * cSubModIterator::operator++ ( | int )

| Returns the current module, then moves the iterator to the next module. Returns NULL if the iterator has already reached the end of the list.

cModule & cSubModIterator::operator[] ( | int )`[inline]`

| DEPRECATED because it might return null reference; use operator() instead.

The documentation for this class was generated from the following file:

- cmodule.h