TStrItem

List of ancestors:
TObj
Files:
strlist.h, strlist.cpp

Desc. & Idea Warnings Methods Attributes Operators Specials

 

Abstrct.bmp (246 bytes)  Abstract

Virtual.bmp (246 bytes)  Virtual Overriden.bmp (246 bytes)  Overridden
Key.bmp (246 bytes)  Key, Important Constructor.bmp (248 bytes)  Constructor Destructor.bmp (246 bytes)  Destructor
Methods beginning with Get or Set (get/set) are usually intended to access Attributes of same name (exceptions will be marked).

 

Description

This class represents a single line of text in the TStrList class.

Title

 

Warnings

Title

 

Methods

Public:             

char *GetLine()
TStrItem *GetNext()
TStrItem *GetPrior()
void PutAfter(TStrItem *Who)
void PutBefore(TStrItem *Who)
void SetLine(const char *val)
Constructor.gif (920 bytes) TStrItem(const char *ALine, TStrItem *After=NULL)
void Unchain()
Destructor.gif (913 bytes) ~TStrItem()

Protected:
Private:

 Title



void PutAfter(TStrItem *Who)

Puts this item into the bi-directional list behind the argument.

Arguments:

Who ... item to chain behind

Section Title


void PutBefore(TStrItem *Who)

Puts this item into the bi-directional list before the argument.

Arguments:

Who ... item to chain before

Section Title


TStrItem(const char *ALine, TStrItem *After=NULL)

Constructor of the class. The string is copied not just the pointer taken.

Arguments:

ALine .. initiate string (copy is made)
Who ... item to chain behind

Section Title


void Unchain()

Removes the item from the bi-directional list. The consistency of the list is kept

Section Title


 



Attributes

Public:
Protected:
Private:

Key.gif (897 bytes) char *Line
TStrItem *Next
TStrItem *Prior

 Title


 char *Line

Pointer to the represented text.
The setLine method copies the line.

Section Title


TStrItem *Next

Pointer to the next item in the bi-directinal list.

Section Title


TStrItem *Prior

Pointer to the previous item in the bi-directinal list.

Section Title




Operators

Title



Specials

The string from the constructor is copied not just the pointer taken. Same function performs the SetLine function.
Eye.gif (947 bytes) TStrList

Title