#include
Collaboration diagram for Branch:
Public Types |
|
typedef cmt_vector< Branch >? | BranchVector |
Public Methods |
|
? | Branch () |
? | ~Branch () |
const cmt_string &? | name () const |
void? | print (PrintMode mode) const |
Static Public Methods |
|
void? | action (const CmtSystem::cmt_string_vector &words) |
Branch *? | find (const cmt_string &name) |
void? | add (const cmt_string &name) |
void? | print_all (PrintMode mode) |
void? | clear_all () |
BranchVector &? | branches () |
Private Attributes |
|
cmt_string? | m_name |
|
? |
Definition at line 16 of file cmt_branch.h. |
|
? |
Definition at line 122 of file cmt_branch.cxx. 00124 { 00125 } |
|
? |
Definition at line 128 of file cmt_branch.cxx. 00130 { 00131 } |
|
? |
Definition at line 22 of file cmt_branch.cxx. References add(), name(), and cmt_vector< cmt_string >::size(). Referenced by KwdBranches::action(). 00024 { 00025 for (int i = 1; i < words.size (); i++) 00026 { 00027 const cmt_string& name = words[i]; 00028 if (name == "") return; 00029 00030 add (name); 00031 } 00032 } |
|
? |
Definition at line 60 of file cmt_branch.cxx. References cmt_vector< Branch >::add(), branches(), find(), and m_name. Referenced by action(). |
|
? |
Definition at line 112 of file cmt_branch.cxx. References Database::branches(), and Database::instance(). Referenced by add(), clear_all(), Cmt::do_config(), find(), and print_all(). 00114 { 00115 static Database& db = Database::instance (); 00116 static BranchVector& Branches = db.branches (); 00117 00118 return (Branches); 00119 } |
|
? |
Definition at line 94 of file cmt_branch.cxx. References branches(), cmt_vector< Branch >::clear(), m_name, and cmt_vector< Branch >::size(). Referenced by Database::clear(). 00096 { 00097 static BranchVector& Branches = branches (); 00098 00099 int number; 00100 00101 for (number = 0; number < Branches.size (); number++) 00102 { 00103 Branch& b = Branches[number]; 00104 00105 b.m_name = ""; 00106 } 00107 00108 Branches.clear (); 00109 } |
|
? |
Definition at line 35 of file cmt_branch.cxx. References branches(), name(), and cmt_vector< Branch >::size(). Referenced by add(). 00037 { 00038 static BranchVector& Branches = branches (); 00039 00040 int branch_index; 00041 00042 if (Branches.size () == 0) return (0); 00043 00044 for (branch_index = 0; 00045 branch_index < Branches.size (); 00046 branch_index++) 00047 { 00048 Branch& branch = Branches[branch_index]; 00049 00050 if (branch.name () == name) 00051 { 00052 return (&branch); 00053 } 00054 } 00055 00056 return (0); 00057 } |
|
? |
Definition at line 134 of file cmt_branch.cxx. Referenced by action(), Cmt::do_config(), and find(). 00136 {
00137 return (m_name);
00138 }
|
|
? |
Definition at line 141 of file cmt_branch.cxx. References PrintMode. 00143 { 00144 cout << m_name; 00145 } |
|
? |
Definition at line 78 of file cmt_branch.cxx. References branches(), PrintMode, and cmt_vector< Branch >::size(). Referenced by Cmt::do_show_branches(). 00080 { 00081 static BranchVector& Branches = branches (); 00082 00083 int number; 00084 00085 for (number = 0; number < Branches.size (); number++) 00086 { 00087 if (number > 0) cout << " "; 00088 Branches[number].print (mode); 00089 } 00090 if (number > 0) cout << endl; 00091 } |
|
? |
Definition at line 32 of file cmt_branch.h. Referenced by add(), and clear_all(). |