Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Class Members | File Members

splitter Class Reference

Class splitter implements a sentence splitter, which accumulates lists of words until a sentence is completed, and then returns a list of sentence objects. More...

#include <splitter.h>

Collaboration diagram for splitter:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 splitter (const string &)
 Constructor.
list< sentencesplit (const list< word > &, bool)
 split sentences with default options

Private Member Functions

bool end_of_sentence (list< word >::const_iterator, const list< word > &) const
 check for sentence markers

Private Attributes

bool SPLIT_AllowBetweenMarkers
 configuration options
int SPLIT_MaxLines
set< string > starters
 Sentence delimiters.
map< string, boolenders
map< string, int > markers
 Open-close marker pairs (parenthesis, etc).
bool betweenMrk
int no_split_count
int mark_type
list< sentencels
 accumulated list of returned sentences
sentence buffer
 accumulated words of current sentence

Detailed Description

Class splitter implements a sentence splitter, which accumulates lists of words until a sentence is completed, and then returns a list of sentence objects.


Constructor & Destructor Documentation

splitter::splitter const string &   ) 
 

Constructor.


Member Function Documentation

bool splitter::end_of_sentence list< word >::const_iterator  ,
const list< word > & 
const [private]
 

check for sentence markers

list< sentence > splitter::split const list< word > &  v,
bool  flush
 

split sentences with default options

If a sentence marker is reached (or flush flag is set), return all sentences currently in buffer, and clean buffer. If a new sentence is started but not completed, keep in buffer, and wait for further calls with more data.


Member Data Documentation

bool splitter::betweenMrk [private]
 

sentence splitter::buffer [private]
 

accumulated words of current sentence

map<string,bool> splitter::enders [private]
 

list<sentence> splitter::ls [private]
 

accumulated list of returned sentences

int splitter::mark_type [private]
 

map<string,int> splitter::markers [private]
 

Open-close marker pairs (parenthesis, etc).

int splitter::no_split_count [private]
 

bool splitter::SPLIT_AllowBetweenMarkers [private]
 

configuration options

int splitter::SPLIT_MaxLines [private]
 

set<string> splitter::starters [private]
 

Sentence delimiters.


The documentation for this class was generated from the following files:
Generated on Wed Apr 26 12:59:14 2006 for FreeLing by  doxygen 1.4.4