2000-01-11 17:28:49 +00:00
|
|
|
/*
|
|
|
|
**********************************************************************
|
|
|
|
* Copyright (c) 2000, International Business Machines
|
|
|
|
* Corporation and others. All Rights Reserved.
|
|
|
|
**********************************************************************
|
|
|
|
* Date Name Description
|
|
|
|
* 01/11/2000 aliu Creation.
|
|
|
|
**********************************************************************
|
|
|
|
*/
|
|
|
|
#ifndef NULTRANS_H
|
|
|
|
#define NULTRANS_H
|
|
|
|
|
2002-09-20 01:54:48 +00:00
|
|
|
#include "unicode/utypes.h"
|
|
|
|
|
|
|
|
#if !UCONFIG_NO_TRANSLITERATION
|
|
|
|
|
2000-01-11 17:28:49 +00:00
|
|
|
#include "unicode/translit.h"
|
|
|
|
|
2002-08-21 19:12:24 +00:00
|
|
|
#ifdef ICU_NULLTRANSLITERATOR_USE_DEPRECATES
|
2001-10-08 23:26:58 +00:00
|
|
|
U_NAMESPACE_BEGIN
|
|
|
|
|
2000-01-11 17:28:49 +00:00
|
|
|
/**
|
|
|
|
* A transliterator that leaves text unchanged.
|
|
|
|
* @author Alan Liu
|
2001-11-16 23:50:18 +00:00
|
|
|
* @deprecated To be removed after 2002-sep-30; use Transliterator::createInstance factory method
|
2000-01-11 17:28:49 +00:00
|
|
|
*/
|
|
|
|
class U_I18N_API NullTransliterator : public Transliterator {
|
|
|
|
|
2001-03-27 19:35:33 +00:00
|
|
|
public:
|
|
|
|
|
2000-01-11 17:28:49 +00:00
|
|
|
/**
|
|
|
|
* ID for this transliterator.
|
2001-11-16 23:50:18 +00:00
|
|
|
* @deprecated To be removed after 2002-sep-30.
|
2000-01-11 17:28:49 +00:00
|
|
|
*/
|
2001-06-20 22:52:03 +00:00
|
|
|
static const UChar ID[]; // public for Transliterator
|
2000-01-11 17:28:49 +00:00
|
|
|
|
2001-08-15 19:06:40 +00:00
|
|
|
/**
|
|
|
|
* ID for this transliterator.
|
2001-11-16 23:50:18 +00:00
|
|
|
* @deprecated To be removed after 2002-sep-30.
|
2001-08-15 19:06:40 +00:00
|
|
|
*/
|
|
|
|
static const UChar SHORT_ID[]; // public for Transliterator
|
|
|
|
|
2000-01-11 17:28:49 +00:00
|
|
|
/**
|
|
|
|
* Constructs a transliterator.
|
2001-11-16 23:50:18 +00:00
|
|
|
* @deprecated To be removed after 2002-sep-30.
|
2000-01-11 17:28:49 +00:00
|
|
|
*/
|
|
|
|
NullTransliterator();
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Destructor.
|
2001-11-16 23:50:18 +00:00
|
|
|
* @deprecated To be removed after 2002-sep-30.
|
2000-01-11 17:28:49 +00:00
|
|
|
*/
|
|
|
|
virtual ~NullTransliterator();
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Transliterator API.
|
2001-11-16 23:50:18 +00:00
|
|
|
* @deprecated To be removed after 2002-sep-30.
|
2000-01-11 17:28:49 +00:00
|
|
|
*/
|
|
|
|
Transliterator* clone(void) const;
|
|
|
|
|
|
|
|
/**
|
2000-01-18 18:27:27 +00:00
|
|
|
* Implements {@link Transliterator#handleTransliterate}.
|
2001-11-16 23:50:18 +00:00
|
|
|
* @deprecated To be removed after 2002-sep-30.
|
2000-01-11 17:28:49 +00:00
|
|
|
*/
|
2000-06-27 19:00:38 +00:00
|
|
|
virtual void handleTransliterate(Replaceable& text, UTransPosition& offset,
|
2000-05-18 22:08:39 +00:00
|
|
|
UBool isIncremental) const;
|
2002-06-29 00:04:16 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* ICU "poor man's RTTI", returns a UClassID for the actual class.
|
|
|
|
*
|
|
|
|
* @draft ICU 2.2
|
|
|
|
*/
|
|
|
|
virtual inline UClassID getDynamicClassID() const { return getStaticClassID(); }
|
|
|
|
|
|
|
|
/**
|
|
|
|
* ICU "poor man's RTTI", returns a UClassID for this class.
|
|
|
|
*
|
|
|
|
* @draft ICU 2.2
|
|
|
|
*/
|
|
|
|
static inline UClassID getStaticClassID() { return (UClassID)&fgClassID; }
|
|
|
|
|
|
|
|
private:
|
|
|
|
|
|
|
|
/**
|
|
|
|
* The address of this static class variable serves as this class's ID
|
|
|
|
* for ICU "poor man's RTTI".
|
|
|
|
*/
|
|
|
|
static const char fgClassID;
|
2000-01-11 17:28:49 +00:00
|
|
|
};
|
|
|
|
|
2001-03-27 19:35:33 +00:00
|
|
|
inline NullTransliterator::NullTransliterator() : Transliterator(ID, 0) {}
|
2000-01-11 17:28:49 +00:00
|
|
|
|
|
|
|
inline NullTransliterator::~NullTransliterator() {}
|
|
|
|
|
2001-10-08 23:26:58 +00:00
|
|
|
U_NAMESPACE_END
|
2002-08-21 19:12:24 +00:00
|
|
|
#endif /* ICU_NULLTRANSLITERATOR_USE_DEPRECATES */
|
2001-10-08 23:26:58 +00:00
|
|
|
|
2002-09-20 01:54:48 +00:00
|
|
|
#endif /* #if !UCONFIG_NO_TRANSLITERATION */
|
|
|
|
|
2000-01-11 17:28:49 +00:00
|
|
|
#endif
|