presage  0.8.7
Public Member Functions | Private Attributes | Friends
Ngram Class Reference

#include <ngram.h>

List of all members.

Public Member Functions

 Ngram (const int N)
 ~Ngram ()
int getN () const
std::string getNgram (const int n) const
void setNgram (const int n, const std::string str)
bool operator< (const Ngram &) const
Ngramoperator= (const Ngram &)
std::string toString () const

Private Attributes

int N
std::string * ngrams

Friends

std::ostream & operator<< (std::ostream &, const Ngram &)

Detailed Description

Definition at line 33 of file ngram.h.


Constructor & Destructor Documentation

Ngram::Ngram ( const int  N)

Definition at line 27 of file ngram.cpp.

References N, and ngrams.

Definition at line 34 of file ngram.cpp.

References ngrams.


Member Function Documentation

int Ngram::getN ( ) const

Definition at line 85 of file ngram.cpp.

References N.

std::string Ngram::getNgram ( const int  n) const

Definition at line 73 of file ngram.cpp.

References N, and ngrams.

bool Ngram::operator< ( const Ngram other) const

Definition at line 51 of file ngram.cpp.

References N, and ngrams.

Ngram & Ngram::operator= ( const Ngram other)

Definition at line 39 of file ngram.cpp.

References N, and ngrams.

void Ngram::setNgram ( const int  n,
const std::string  str 
)

Definition at line 79 of file ngram.cpp.

References N, and ngrams.

std::string Ngram::toString ( ) const

Definition at line 64 of file ngram.cpp.

References N, and ngrams.

Referenced by operator<<().

Here is the caller graph for this function:


Friends And Related Function Documentation

std::ostream& operator<< ( std::ostream &  output,
const Ngram b 
) [friend]

Definition at line 90 of file ngram.cpp.


Member Data Documentation

int Ngram::N [private]

Definition at line 50 of file ngram.h.

Referenced by getN(), getNgram(), Ngram(), operator<(), operator=(), setNgram(), and toString().

std::string* Ngram::ngrams [private]

Definition at line 51 of file ngram.h.

Referenced by getNgram(), Ngram(), operator<(), operator=(), setNgram(), toString(), and ~Ngram().


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