2000-01-18 01:55:52 +00:00
|
|
|
/*
|
|
|
|
**********************************************************************
|
|
|
|
* Copyright (c) 2000, International Business Machines
|
|
|
|
* Corporation and others. All Rights Reserved.
|
|
|
|
**********************************************************************
|
|
|
|
* Date Name Description
|
|
|
|
* 01/17/2000 aliu Ported from Java.
|
|
|
|
**********************************************************************
|
|
|
|
*/
|
|
|
|
#ifndef HANGJAMO_H
|
|
|
|
#define HANGJAMO_H
|
|
|
|
|
|
|
|
#include "unicode/translit.h"
|
|
|
|
|
|
|
|
/**
|
|
|
|
* A transliterator that converts Hangul to Jamo.
|
|
|
|
*
|
|
|
|
* @author Mark Davis
|
2000-06-27 19:00:38 +00:00
|
|
|
* @version $RCSfile: hangjamo.h,v $ $Revision: 1.5 $ $Date: 2000/06/27 19:00:38 $
|
2000-01-18 01:55:52 +00:00
|
|
|
*/
|
|
|
|
class U_I18N_API HangulJamoTransliterator : public Transliterator {
|
|
|
|
|
|
|
|
/**
|
|
|
|
* ID for this transliterator.
|
|
|
|
*/
|
|
|
|
static const char* _ID;
|
|
|
|
|
|
|
|
public:
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Constructs a transliterator.
|
|
|
|
*/
|
|
|
|
HangulJamoTransliterator(UnicodeFilter* adoptedFilter = 0);
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Destructor.
|
|
|
|
*/
|
|
|
|
virtual ~HangulJamoTransliterator();
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Copy constructor.
|
|
|
|
*/
|
|
|
|
HangulJamoTransliterator(const HangulJamoTransliterator&);
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Assignment operator.
|
|
|
|
*/
|
|
|
|
HangulJamoTransliterator& operator=(const HangulJamoTransliterator&);
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Transliterator API.
|
|
|
|
*/
|
|
|
|
Transliterator* clone(void) const;
|
|
|
|
|
|
|
|
/**
|
2000-01-18 18:27:27 +00:00
|
|
|
* Implements {@link Transliterator#handleTransliterate}.
|
2000-01-18 01:55:52 +00:00
|
|
|
*/
|
2000-06-27 19:00:38 +00:00
|
|
|
virtual void handleTransliterate(Replaceable& text, UTransPosition& offsets,
|
2000-05-18 22:08:39 +00:00
|
|
|
UBool isIncremental) const;
|
2000-01-18 01:55:52 +00:00
|
|
|
|
|
|
|
private:
|
|
|
|
|
2000-05-18 22:08:39 +00:00
|
|
|
static UBool decomposeHangul(UChar s, UnicodeString& result);
|
2000-01-18 01:55:52 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
inline HangulJamoTransliterator::~HangulJamoTransliterator() {}
|
|
|
|
|
|
|
|
#endif
|