/*
*******************************************************************************
*
-* Copyright (C) 2001-2005, International Business Machines
+* Copyright (C) 2001-2011, International Business Machines
* Corporation and others. All Rights Reserved.
*
*******************************************************************************
#include "unicode/uchar.h"
#include "unicode/ustring.h"
+#include "unicode/utf.h"
+#include "unicode/utf16.h"
#include "tolowtrn.h"
#include "ucase.h"
#include "cpputils.h"
U_CFUNC UChar32 U_CALLCONV
utrans_rep_caseContextIterator(void *context, int8_t dir)
{
+ U_NAMESPACE_USE
+
UCaseContext *csc=(UCaseContext *)context;
Replaceable *rep=(Replaceable *)csc->p;
UChar32 c;
U_NAMESPACE_BEGIN
-UOBJECT_DEFINE_RTTI_IMPLEMENTATION(CaseMapTransliterator)
+UOBJECT_DEFINE_ABSTRACT_RTTI_IMPLEMENTATION(CaseMapTransliterator)
/**
* Constructs a transliterator.
*/
CaseMapTransliterator::CaseMapTransliterator(const UnicodeString &id, UCaseMapFull *map) :
Transliterator(id, 0),
- fCsp(NULL),
+ fCsp(ucase_getSingleton()),
fMap(map)
{
- UErrorCode errorCode = U_ZERO_ERROR;
- fCsp = ucase_getSingleton(&errorCode); // expect to get NULL if failure
-
// TODO test incremental mode with context-sensitive text (e.g. greek sigma)
// TODO need to call setMaximumContextLength()?!
}
/**
* Assignment operator.
*/
-CaseMapTransliterator& CaseMapTransliterator::operator=(const CaseMapTransliterator& o) {
+/*CaseMapTransliterator& CaseMapTransliterator::operator=(const CaseMapTransliterator& o) {
Transliterator::operator=(o);
fCsp = o.fCsp;
fMap = o.fMap;
return *this;
-}
+}*/
/**
* Transliterator API.
*/
-Transliterator* CaseMapTransliterator::clone(void) const {
+/*Transliterator* CaseMapTransliterator::clone(void) const {
return new CaseMapTransliterator(*this);
-}
+}*/
/**
* Implements {@link Transliterator#handleTransliterate}.