patch_context_ty Class Reference

#include <context.h>


Public Member Functions

 ~patch_context_ty ()
 patch_context_ty (input &arg)
string_tygetline (int n)
void discard (int n)
nstring get_file_name ()

Private Member Functions

 patch_context_ty ()
 patch_context_ty (const patch_context_ty &)
patch_context_tyoperator= (const patch_context_ty &)

Private Attributes

input in
string_list_ty buffer


Detailed Description

The patch_context_ty class is used to represent a line buffered input stream, with the ability to fetch individual lines of input.

Definition at line 30 of file context.h.


Constructor & Destructor Documentation

patch_context_ty::~patch_context_ty (  ) 

The destructor.

patch_context_ty::patch_context_ty ( input arg  ) 

The constructor.

Parameters:
arg The input stream to read and buffer.

patch_context_ty::patch_context_ty (  )  [private]

The default constructor. Do not use.

patch_context_ty::patch_context_ty ( const patch_context_ty  )  [private]

The copy constructor. Do not use.


Member Function Documentation

string_ty* patch_context_ty::getline ( int  n  ) 

The getline method is used to grab the line with the given numkber (zero based).

Parameters:
n The line number to fatch (zero based), relative to the current position.

void patch_context_ty::discard ( int  n  ) 

The discard method is used to consume some lines of inout.

Parameters:
n The number of lines to discard from the front of the buffer.

nstring patch_context_ty::get_file_name (  )  [inline]

The get_file_name method is used to get the name and line number of the input stream. This is mostly used for debugging.

Definition at line 68 of file context.h.

patch_context_ty& patch_context_ty::operator= ( const patch_context_ty  )  [private]

The assignment operator. Do not use.


Field Documentation

The input instance variable is used to remember where to get more input lines from.

Definition at line 75 of file context.h.

The buffer instance variable is used to remember lines which have already been read from the input.

Definition at line 81 of file context.h.


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

Generated on Wed Mar 12 23:37:41 2008 for Aegis by  doxygen 1.5.5