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

symbol_marker Class Reference

List of all members.

Public Methods

? symbol_marker ()
? symbol_marker (int a_ptr, char a_pattern, int a_intro)
? symbol_marker (const symbol_marker &other)
void? set (int a_ptr, char a_pattern, int a_intro)

Static Public Methods

symbol_marker &? get_lowest (symbol_marker markers[], int count)

Public Attributes

int? ptr
char? pattern
int? intro

Constructor & Destructor Documentation

symbol_marker::symbol_marker (? ? )? [inline]
?

Definition at line 86 of file cmt_symbol.cxx.

References intro, cmt_string::npos, pattern, and ptr.

00087   {
00088     ptr = cmt_string::npos;
00089     pattern = 0;
00090     intro = 0;
00091   }

symbol_marker::symbol_marker (? int? ? a_ptr,
char? ? a_pattern,
int? ? a_intro
)? [inline]
?

Definition at line 93 of file cmt_symbol.cxx.

References intro, pattern, and ptr.

00094   {
00095     ptr = a_ptr;
00096     pattern = a_pattern;
00097     intro = a_intro;
00098   }

symbol_marker::symbol_marker (? const symbol_marker &? ? other )? [inline]
?

Definition at line 100 of file cmt_symbol.cxx.

References intro, pattern, and ptr.

00101   {
00102     ptr = other.ptr;
00103     pattern = other.pattern;
00104     intro = other.intro;
00105   }

Member Function Documentation

symbol_marker& symbol_marker::get_lowest (? symbol_marker? ? markers[],
int? ? count
)? [inline, static]
?

Definition at line 114 of file cmt_symbol.cxx.

References cmt_string::npos, and ptr.

Referenced by resolve_value(), resolve_value_for_macros(), and suppress_OS_delimiters().

00115   {
00116     static symbol_marker result;
00117     int real_count = 0;
00118     int i;
00119 
00120       // Check that at least one marker has result
00121 
00122     for (i = 0; i < count; i++)
00123       {
00124         if (markers[i].ptr != cmt_string::npos) real_count++;
00125       }
00126 
00127     if (real_count == 0) return (result);
00128 
00129     // since we've passed the previous test, 
00130     // at least one entry is not npos.
00131     // Now discards other npos by moving them to the end
00132     
00133     for (i = 0; i < count;)
00134       {
00135         if (markers[i].ptr == cmt_string::npos)
00136           {
00137             markers[i] = markers[count-1];
00138             count--;
00139             if (count == 0) break;
00140           }
00141         else
00142           {
00143             i++;
00144           }
00145       }
00146     
00147     if (count == 0) return (result);
00148     
00149     // now all entries in [0, count-1] are not npos
00150     // let's sort the lowest one in [0]
00151     
00152     for (i = 1; i < count;)
00153       {
00154         if (markers[0].ptr > markers[i].ptr)
00155           {
00156             symbol_marker temp = markers[0];
00157             markers[0] = markers[i];
00158             markers[i] = temp;
00159             i = 1;
00160           }
00161         else
00162           {
00163             i++;
00164           }
00165       }
00166     
00167     return (markers[0]);
00168   }

void symbol_marker::set (? int? ? a_ptr,
char? ? a_pattern,
int? ? a_intro
)? [inline]
?

Definition at line 107 of file cmt_symbol.cxx.

References intro, pattern, and ptr.

Referenced by resolve_value(), resolve_value_for_macros(), and suppress_OS_delimiters().

00108   {
00109     ptr = a_ptr;
00110     pattern = a_pattern;
00111     intro = a_intro;
00112   }

Member Data Documentation

int symbol_marker::intro
?

Definition at line 172 of file cmt_symbol.cxx.

Referenced by resolve_value(), resolve_value_for_macros(), set(), suppress_OS_delimiters(), and symbol_marker().

char symbol_marker::pattern
?

Definition at line 171 of file cmt_symbol.cxx.

Referenced by resolve_value(), resolve_value_for_macros(), set(), suppress_OS_delimiters(), and symbol_marker().

int symbol_marker::ptr
?

Definition at line 170 of file cmt_symbol.cxx.

Referenced by get_lowest(), resolve_value(), resolve_value_for_macros(), set(), suppress_OS_delimiters(), and symbol_marker().


The documentation for this class was generated from the following file:
Generated on Thu Jul 1 15:27:42 2004 for CMT by 1.2.18