#include "unicode/utypes.h"
#if !UCONFIG_NO_FORMATTING
#define UNISTR_FROM_STRING_EXPLICIT
#include "numparse_types.h"
#include "numparse_affixes.h"
#include "numparse_utils.h"
#include "number_utils.h"
#include "string_segment.h"
usingnamespaceicu;
usingnamespaceicu::numparse;
usingnamespaceicu::numparse::impl;
usingnamespaceicu::number;
usingnamespaceicu::number::impl;
namespace {
static bool matched(const AffixPatternMatcher* affix, const UnicodeString& patternString) { … }
static int32_t length(const AffixPatternMatcher* matcher) { … }
static bool equals(const AffixPatternMatcher* lhs, const AffixPatternMatcher* rhs) { … }
}
AffixPatternMatcherBuilder::AffixPatternMatcherBuilder(const UnicodeString& pattern,
AffixTokenMatcherWarehouse& warehouse,
IgnorablesMatcher* ignorables)
: … { … }
void AffixPatternMatcherBuilder::consumeToken(AffixPatternType type, UChar32 cp, UErrorCode& status) { … }
void AffixPatternMatcherBuilder::addMatcher(NumberParseMatcher& matcher) { … }
AffixPatternMatcher AffixPatternMatcherBuilder::build(UErrorCode& status) { … }
AffixTokenMatcherWarehouse::AffixTokenMatcherWarehouse(const AffixTokenMatcherSetupData* setupData)
: … { … }
NumberParseMatcher& AffixTokenMatcherWarehouse::minusSign() { … }
NumberParseMatcher& AffixTokenMatcherWarehouse::plusSign() { … }
NumberParseMatcher& AffixTokenMatcherWarehouse::percent() { … }
NumberParseMatcher& AffixTokenMatcherWarehouse::permille() { … }
NumberParseMatcher& AffixTokenMatcherWarehouse::currency(UErrorCode& status) { … }
IgnorablesMatcher& AffixTokenMatcherWarehouse::ignorables() { … }
NumberParseMatcher* AffixTokenMatcherWarehouse::nextCodePointMatcher(UChar32 cp, UErrorCode& status) { … }
bool AffixTokenMatcherWarehouse::hasEmptyCurrencySymbol() const { … }
CodePointMatcher::CodePointMatcher(UChar32 cp)
: … { … }
bool CodePointMatcher::match(StringSegment& segment, ParsedNumber& result, UErrorCode&) const { … }
bool CodePointMatcher::smokeTest(const StringSegment& segment) const { … }
UnicodeString CodePointMatcher::toString() const { … }
AffixPatternMatcher AffixPatternMatcher::fromAffixPattern(const UnicodeString& affixPattern,
AffixTokenMatcherWarehouse& tokenWarehouse,
parse_flags_t parseFlags, bool* success,
UErrorCode& status) { … }
AffixPatternMatcher::AffixPatternMatcher(MatcherArray& matchers, int32_t matchersLen,
const UnicodeString& pattern, UErrorCode& status)
: … { … }
UnicodeString AffixPatternMatcher::getPattern() const { … }
bool AffixPatternMatcher::operator==(const AffixPatternMatcher& other) const { … }
AffixMatcherWarehouse::AffixMatcherWarehouse(AffixTokenMatcherWarehouse* tokenWarehouse)
: … { … }
bool AffixMatcherWarehouse::isInteresting(const AffixPatternProvider& patternInfo,
const IgnorablesMatcher& ignorables, parse_flags_t parseFlags,
UErrorCode& status) { … }
void AffixMatcherWarehouse::createAffixMatchers(const AffixPatternProvider& patternInfo,
MutableMatcherCollection& output,
const IgnorablesMatcher& ignorables,
parse_flags_t parseFlags, UErrorCode& status) { … }
AffixMatcher::AffixMatcher(AffixPatternMatcher* prefix, AffixPatternMatcher* suffix, result_flags_t flags)
: … { … }
bool AffixMatcher::match(StringSegment& segment, ParsedNumber& result, UErrorCode& status) const { … }
bool AffixMatcher::smokeTest(const StringSegment& segment) const { … }
void AffixMatcher::postProcess(ParsedNumber& result) const { … }
int8_t AffixMatcher::compareTo(const AffixMatcher& rhs) const { … }
UnicodeString AffixMatcher::toString() const { … }
#endif