diff options
author | Matt A. Tobin <mattatobin@localhost.localdomain> | 2018-02-02 04:16:08 -0500 |
---|---|---|
committer | Matt A. Tobin <mattatobin@localhost.localdomain> | 2018-02-02 04:16:08 -0500 |
commit | 5f8de423f190bbb79a62f804151bc24824fa32d8 (patch) | |
tree | 10027f336435511475e392454359edea8e25895d /intl/icu/source/i18n/inputext.h | |
parent | 49ee0794b5d912db1f95dce6eb52d781dc210db5 (diff) | |
download | UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.gz UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.lz UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.xz UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.zip |
Add m-esr52 at 52.6.0
Diffstat (limited to 'intl/icu/source/i18n/inputext.h')
-rw-r--r-- | intl/icu/source/i18n/inputext.h | 63 |
1 files changed, 63 insertions, 0 deletions
diff --git a/intl/icu/source/i18n/inputext.h b/intl/icu/source/i18n/inputext.h new file mode 100644 index 000000000..efffb613e --- /dev/null +++ b/intl/icu/source/i18n/inputext.h @@ -0,0 +1,63 @@ +// Copyright (C) 2016 and later: Unicode, Inc. and others. +// License & terms of use: http://www.unicode.org/copyright.html +/* + ********************************************************************** + * Copyright (C) 2005-2008, International Business Machines + * Corporation and others. All Rights Reserved. + ********************************************************************** + */ + +#ifndef __INPUTEXT_H +#define __INPUTEXT_H + +/** + * \file + * \internal + * + * This is an internal header for the Character Set Detection code. The + * name is probably too generic... + */ + + +#include "unicode/uobject.h" + +#if !UCONFIG_NO_CONVERSION + +U_NAMESPACE_BEGIN + +class InputText : public UMemory +{ + // Prevent copying + InputText(const InputText &); +public: + InputText(UErrorCode &status); + ~InputText(); + + void setText(const char *in, int32_t len); + void setDeclaredEncoding(const char *encoding, int32_t len); + UBool isSet() const; + void MungeInput(UBool fStripTags); + + // The text to be checked. Markup will have been + // removed if appropriate. + uint8_t *fInputBytes; + int32_t fInputLen; // Length of the byte data in fInputBytes. + // byte frequency statistics for the input text. + // Value is percent, not absolute. + // Value is rounded up, so zero really means zero occurences. + int16_t *fByteStats; + UBool fC1Bytes; // True if any bytes in the range 0x80 - 0x9F are in the input;false by default + char *fDeclaredEncoding; + + const uint8_t *fRawInput; // Original, untouched input bytes. + // If user gave us a byte array, this is it. + // If user gave us a stream, it's read to a + // buffer here. + int32_t fRawLength; // Length of data in fRawInput array. + +}; + +U_NAMESPACE_END + +#endif +#endif /* __INPUTEXT_H */ |