Main Page Class Hierarchy Compound List File List Compound Members File Members

# cmt_or_node Class Reference

Inheritance diagram for cmt_or_node

[legend]
Collaboration diagram for cmt_or_node:

[legend]
List of all members.

## Public Methods
| cmt_or_node (cmt_node_set* father)
const cmt_regexp::iterator | match (const cmt_string& text, int pos) const

## Constructor & Destructor Documentation

cmt_or_node::cmt_or_node ( | cmt_node_set * father )

| Definition at line 906 of file cmt_regexp.cxx.
    00906                                               : cmt_node_set (father)
    00907 {
    00908 }

## Member Function Documentation

const cmt_regexp::iterator cmt_or_node::match ( | const cmt_string & text,
| int pos ) const`[virtual]`

| Reimplemented from cmt_node. Definition at line 910 of file cmt_regexp.cxx.
    00912 {
    00913   if ((pos < 0) || (pos >= text.size ()))
    00914     {
    00915       return (cmt_regexp::iterator::null ());
    00916     }
    00917
    00918   if (_nodes.size () == 0) return (cmt_regexp::iterator (pos, 0));
    00919
    00920   int i;
    00921
    00922   for (i = 0; i < _nodes.size (); i++)
    00923     {
    00924       const cmt_node* n = _nodes[i];
    00925
    00926       const cmt_regexp::iterator it = n->match (text, pos);
    00927
    00928         //        at least one or-ed expression matches
    00929       if (it != cmt_regexp::iterator::null ()) return (it);
    00930     }
    00931
    00932   return (cmt_regexp::iterator::null ());
    00933 }

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

- cmt_regexp.cxx