• Skip to content
  • Skip to link menu
  • KDE API Reference
  • kdelibs-4.8.3 API Reference
  • KDE Home
  • Contact Us
 

KDECore

  • kencodingprober
  • nsHebrewProber
Public Member Functions | Static Protected Member Functions | Protected Attributes
kencodingprober::nsHebrewProber Class Reference

#include <nsHebrewProber.h>

Inheritance diagram for kencodingprober::nsHebrewProber:
Inheritance graph
[legend]

List of all members.

Public Member Functions

 nsHebrewProber (void)
virtual ~nsHebrewProber (void)
virtual const char * GetCharSetName ()
virtual float GetConfidence (void)
virtual nsProbingState GetState (void)
virtual nsProbingState HandleData (const char *aBuf, unsigned int aLen)
virtual void Reset (void)
void SetModelProbers (nsCharSetProber *logicalPrb, nsCharSetProber *visualPrb)
virtual void SetOpion ()

Static Protected Member Functions

static bool isFinal (char c)
static bool isNonFinal (char c)

Protected Attributes

char mBeforePrev
int mFinalCharLogicalScore
int mFinalCharVisualScore
nsCharSetProber * mLogicalProb
char mPrev
nsCharSetProber * mVisualProb

Detailed Description

Definition at line 33 of file nsHebrewProber.h.


Constructor & Destructor Documentation

kencodingprober::nsHebrewProber::nsHebrewProber ( void  ) [inline]

Definition at line 36 of file nsHebrewProber.h.

virtual kencodingprober::nsHebrewProber::~nsHebrewProber ( void  ) [inline, virtual]

Definition at line 38 of file nsHebrewProber.h.


Member Function Documentation

const char * kencodingprober::nsHebrewProber::GetCharSetName ( ) [virtual]

Implements kencodingprober::nsCharSetProber.

Definition at line 134 of file nsHebrewProber.cpp.

virtual float kencodingprober::nsHebrewProber::GetConfidence ( void  ) [inline, virtual]

Implements kencodingprober::nsCharSetProber.

Definition at line 45 of file nsHebrewProber.h.

nsProbingState kencodingprober::nsHebrewProber::GetState ( void  ) [virtual]

Implements kencodingprober::nsCharSetProber.

Definition at line 170 of file nsHebrewProber.cpp.

nsProbingState kencodingprober::nsHebrewProber::HandleData ( const char *  aBuf,
unsigned int  aLen 
) [virtual]

HandleData Final letter analysis for logical-visual decision.

Look for evidence that the received buffer is either logical Hebrew or visual Hebrew. The following cases are checked: 1) A word longer than 1 letter, ending with a final letter. This is an indication that the text is laid out "naturally" since the final letter really appears at the end. +1 for logical score. 2) A word longer than 1 letter, ending with a Non-Final letter. In normal Hebrew, words ending with Kaf, Mem, Nun, Pe or Tsadi, should not end with the Non-Final form of that letter. Exceptions to this rule are mentioned above in isNonFinal(). This is an indication that the text is laid out backwards. +1 for visual score 3) A word longer than 1 letter, starting with a final letter. Final letters should not appear at the beginning of a word. This is an indication that the text is laid out backwards. +1 for visual score.

The visual score and logical score are accumulated throughout the text and are finally checked against each other in GetCharSetName(). No checking for final letters in the middle of words is done since that case is not an indication for either Logical or Visual text.

The input buffer should not contain any white spaces that are not (' ') or any low-ascii punctuation marks.

Implements kencodingprober::nsCharSetProber.

Definition at line 98 of file nsHebrewProber.cpp.

bool kencodingprober::nsHebrewProber::isFinal ( char  c) [static, protected]

Definition at line 53 of file nsHebrewProber.cpp.

bool kencodingprober::nsHebrewProber::isNonFinal ( char  c) [static, protected]

Definition at line 58 of file nsHebrewProber.cpp.

void kencodingprober::nsHebrewProber::Reset ( void  ) [virtual]

Implements kencodingprober::nsCharSetProber.

Definition at line 159 of file nsHebrewProber.cpp.

void kencodingprober::nsHebrewProber::SetModelProbers ( nsCharSetProber *  logicalPrb,
nsCharSetProber *  visualPrb 
) [inline]

Definition at line 48 of file nsHebrewProber.h.

virtual void kencodingprober::nsHebrewProber::SetOpion ( ) [inline, virtual]

Implements kencodingprober::nsCharSetProber.

Definition at line 46 of file nsHebrewProber.h.


Member Data Documentation

char kencodingprober::nsHebrewProber::mBeforePrev [protected]

Definition at line 62 of file nsHebrewProber.h.

int kencodingprober::nsHebrewProber::mFinalCharLogicalScore [protected]

Definition at line 59 of file nsHebrewProber.h.

int kencodingprober::nsHebrewProber::mFinalCharVisualScore [protected]

Definition at line 59 of file nsHebrewProber.h.

nsCharSetProber* kencodingprober::nsHebrewProber::mLogicalProb [protected]

Definition at line 65 of file nsHebrewProber.h.

char kencodingprober::nsHebrewProber::mPrev [protected]

Definition at line 62 of file nsHebrewProber.h.

nsCharSetProber * kencodingprober::nsHebrewProber::mVisualProb [protected]

Definition at line 65 of file nsHebrewProber.h.


The documentation for this class was generated from the following files:
  • nsHebrewProber.h
  • nsHebrewProber.cpp
This file is part of the KDE documentation.
Documentation copyright © 1996-2012 The KDE developers.
Generated on Thu May 10 2012 20:49:42 by doxygen 1.8.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

KDECore

Skip menu "KDECore"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • File Members
  • Modules
  • Related Pages

kdelibs-4.8.3 API Reference

Skip menu "kdelibs-4.8.3 API Reference"
  • DNSSD
  • Interfaces
  •   KHexEdit
  •   KMediaPlayer
  •   KSpeech
  •   KTextEditor
  • kconf_update
  • KDE3Support
  •   KUnitTest
  • KDECore
  • KDED
  • KDEsu
  • KDEUI
  • KDEWebKit
  • KDocTools
  • KFile
  • KHTML
  • KImgIO
  • KInit
  • kio
  • KIOSlave
  • KJS
  •   KJS-API
  •   WTF
  • kjsembed
  • KNewStuff
  • KParts
  • KPty
  • Kross
  • KUnitConversion
  • KUtils
  • Nepomuk
  • Plasma
  • Solid
  • Sonnet
  • ThreadWeaver
Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal