Main Page | Class Hierarchy | Class List | File List | Class Members | File Members

ProjectPatcher Class Reference

Inheritance diagram for ProjectPatcher:

Inheritance graph
[legend]
Collaboration diagram for ProjectPatcher:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 ProjectPatcher (const cmt_string &p)
void commit ()
void filter (const cmt_string &line)

Private Attributes

cmt_string m_output
const cmt_stringm_project

Constructor & Destructor Documentation

ProjectPatcher::ProjectPatcher const cmt_string p  )  [inline]
 

Definition at line 51 of file cmt_project.cxx.

References m_project.

00051                                        : m_project (p)
00052   {
00053   }


Member Function Documentation

void ProjectPatcher::commit  )  [inline]
 

Definition at line 55 of file cmt_project.cxx.

References m_output, and cmt_string::write().

Referenced by Project::create().

00056   {
00057     m_output.write (Project::get_project_file_name ());
00058   }

void ProjectPatcher::filter const cmt_string line  )  [inline, virtual]
 

Reimplemented from Awk.

Definition at line 60 of file cmt_project.cxx.

References CmtSystem::cmt_string_vector, m_output, m_project, and CmtSystem::split().

00061   {
00062     if (m_output != "")
00063       {
00064         m_output += "\n";
00065       }
00066     
00067     CmtSystem::cmt_string_vector words;
00068     CmtSystem::split (line, " \t", words);
00069     if (words[0] == "project")
00070       {
00071         m_output += "project ";
00072         m_output += m_project;
00073       }
00074     else
00075       {
00076         m_output += line;
00077       }
00078   }


Member Data Documentation

cmt_string ProjectPatcher::m_output [private]
 

Definition at line 81 of file cmt_project.cxx.

Referenced by commit(), and filter().

const cmt_string& ProjectPatcher::m_project [private]
 

Definition at line 82 of file cmt_project.cxx.

Referenced by filter(), and ProjectPatcher().


The documentation for this class was generated from the following file:
Generated on Mon May 2 10:25:57 2005 for CMT by doxygen 1.3.5