Home · All Classes · Main Classes · Deprecated |
class representing a match obtained from MCharsetDetector More...
Public Member Functions | |
MCharsetMatch () | |
MCharsetMatch (const QString name, const QString language=QString(), const qint32 confidence=0) | |
MCharsetMatch (const MCharsetMatch &other) | |
virtual | ~MCharsetMatch () |
MCharsetMatch & | operator= (const MCharsetMatch &other) |
bool | operator< (const MCharsetMatch &other) const |
bool | operator> (const MCharsetMatch &other) const |
QString | name () const |
void | setName (QString name) |
QString | language () const |
void | setLanguage (QString language) |
qint32 | confidence () const |
void | setConfidence (qint32 confidence) |
class representing a match obtained from MCharsetDetector
ML10N::MCharsetMatch::MCharsetMatch | ( | ) |
constructor for MCharsetMatch
ML10N::MCharsetMatch::MCharsetMatch | ( | const QString | name, | |
const QString | language = QString() , |
|||
const qint32 | confidence = 0 | |||
) | [explicit] |
constructor for MCharsetMatch
name | name of the charset. For example "UTF-8", "ISO-8859-1", ... | |
language | RFC 3066 code of the language like "en", "zh", ... | |
confidence | number between 0 and 100 for the quality of the match |
Constructs an MCharsetMatch object setting a name of the charset a language, and a confidence.
ML10N::MCharsetMatch::MCharsetMatch | ( | const MCharsetMatch & | other | ) |
copy constructor for MCharsetMatch
ML10N::MCharsetMatch::~MCharsetMatch | ( | ) | [virtual] |
destructor for MCharsetMatch
qint32 ML10N::MCharsetMatch::confidence | ( | ) | const |
confidence level of this match
returns the confidence level of the match represented by this MCharsetMatch object.
Confidence numbers range from zero to 100, with 100 representing complete confidence and zero representing no confidence.
The confidence values are somewhat arbitrary. They define an an ordering within the results for any single detection operation but are not generally comparable between the results for different input.
A confidence value of 10 does have a general meaning — it is used for charsets that can represent the input data, but for which there is no other indication that suggests that the charset is the correct one.
QString ML10N::MCharsetMatch::language | ( | ) | const |
detected language of this match
returns the detected language of the match represented by this MCharsetMatch object.
QString ML10N::MCharsetMatch::name | ( | ) | const |
name of the detected charset of this match
returns the name of the charset of the match represented by this MCharsetMatch object.
bool ML10N::MCharsetMatch::operator< | ( | const MCharsetMatch & | other | ) | const |
operator< for MCharsetMatch
A MCharsetMatch object is less than another MCharsetMatch object if its confidence value is less than the confidence value of the other object.
MCharsetMatch & ML10N::MCharsetMatch::operator= | ( | const MCharsetMatch & | other | ) |
operator= for MCharsetMatch
bool ML10N::MCharsetMatch::operator> | ( | const MCharsetMatch & | other | ) | const |
operator> for MCharsetMatch
A MCharsetMatch object is greater than another MCharsetMatch object if its confidence value is greater than the confidence value of the other object.
void ML10N::MCharsetMatch::setConfidence | ( | qint32 | confidence | ) |
sets the confidence level for this match
sets the confidece level of the match represented by this MCharsetMatch object. In most cases only used by MCharsetDetector when storing the matches found.
void ML10N::MCharsetMatch::setLanguage | ( | QString | language | ) |
sets the detected language for this match
sets the detected language of the match represented by this MCharsetMatch object. In most cases only used by MCharsetDetector when storing the matches found.
void ML10N::MCharsetMatch::setName | ( | QString | name | ) |
sets the name of the detected charset for this match
sets the name of the charset of the match represented by this MCharsetMatch object. In most cases only used by MCharsetDetector when storing the matches found.
Copyright © 2010 Nokia Corporation | MeeGo Touch |