1/* 2******************************************************************************** 3* Copyright (C) 2012-2014, International Business Machines 4* Corporation and others. All Rights Reserved. 5********************************************************************************/ 6 7#ifndef DCFMTIMP_H 8#define DCFMTIMP_H 9 10#include "unicode/utypes.h" 11 12 13#if UCONFIG_FORMAT_FASTPATHS_49 14 15U_NAMESPACE_BEGIN 16 17enum EDecimalFormatFastpathStatus { 18 kFastpathNO = 0, 19 kFastpathYES = 1, 20 kFastpathUNKNOWN = 2 /* not yet set */ 21}; 22 23/** 24 * Must be smaller than DecimalFormat::fReserved 25 */ 26struct DecimalFormatInternal { 27 uint8_t fFastFormatStatus; 28 uint8_t fFastParseStatus; 29 30 DecimalFormatInternal &operator=(const DecimalFormatInternal& rhs) { 31 fFastParseStatus = rhs.fFastParseStatus; 32 fFastFormatStatus = rhs.fFastFormatStatus; 33 return *this; 34 } 35#ifdef FMT_DEBUG 36 void dump() const { 37 printf("DecimalFormatInternal: fFastFormatStatus=%c, fFastParseStatus=%c\n", 38 "NY?"[(int)fFastFormatStatus&3], 39 "NY?"[(int)fFastParseStatus&3] 40 ); 41 } 42#endif 43}; 44 45 46 47U_NAMESPACE_END 48 49#endif 50 51#endif 52