2001-11-16 23:51:15 +00:00
|
|
|
/*
|
|
|
|
**********************************************************************
|
|
|
|
* Copyright (C) 2001, International Business Machines
|
|
|
|
* Corporation and others. All Rights Reserved.
|
|
|
|
**********************************************************************
|
|
|
|
* Date Name Description
|
|
|
|
* 05/24/01 aliu Creation.
|
|
|
|
**********************************************************************
|
|
|
|
*/
|
|
|
|
#ifndef TOLOWTRN_H
|
|
|
|
#define TOLOWTRN_H
|
|
|
|
|
2001-12-03 21:43:13 +00:00
|
|
|
#include "unicode/translit.h"
|
2001-11-16 23:51:15 +00:00
|
|
|
#include "unicode/locid.h"
|
|
|
|
|
|
|
|
U_NAMESPACE_BEGIN
|
|
|
|
|
|
|
|
/**
|
|
|
|
* A transliterator that performs locale-sensitive toLower()
|
|
|
|
* case mapping.
|
|
|
|
* @author Alan Liu
|
|
|
|
*/
|
2001-11-30 00:57:29 +00:00
|
|
|
class U_I18N_API LowercaseTransliterator : public Transliterator {
|
2001-11-16 23:51:15 +00:00
|
|
|
|
|
|
|
public:
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Constructs a transliterator.
|
|
|
|
*/
|
2001-11-30 00:57:29 +00:00
|
|
|
LowercaseTransliterator(const Locale& loc = Locale::getDefault());
|
2001-11-16 23:51:15 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Destructor.
|
|
|
|
*/
|
|
|
|
virtual ~LowercaseTransliterator();
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Copy constructor.
|
|
|
|
*/
|
|
|
|
LowercaseTransliterator(const LowercaseTransliterator&);
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Assignment operator.
|
|
|
|
*/
|
|
|
|
LowercaseTransliterator& operator=(const LowercaseTransliterator&);
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Transliterator API.
|
|
|
|
*/
|
|
|
|
Transliterator* clone(void) const;
|
|
|
|
|
|
|
|
protected:
|
|
|
|
|
|
|
|
/**
|
2001-11-30 00:57:29 +00:00
|
|
|
* Implements {@link Transliterator#handleTransliterate}.
|
2001-11-16 23:51:15 +00:00
|
|
|
*/
|
2001-11-30 00:57:29 +00:00
|
|
|
virtual void handleTransliterate(Replaceable& text,
|
|
|
|
UTransPosition& offsets,
|
|
|
|
UBool isIncremental) const;
|
2001-11-16 23:51:15 +00:00
|
|
|
|
|
|
|
private:
|
|
|
|
|
|
|
|
Locale loc;
|
2001-11-30 00:57:29 +00:00
|
|
|
UChar* buffer;
|
2001-11-16 23:51:15 +00:00
|
|
|
static const char _ID[];
|
|
|
|
};
|
|
|
|
|
|
|
|
U_NAMESPACE_END
|
|
|
|
|
|
|
|
#endif
|