00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014 #ifndef CPPUTILS_H
00015 #define CPPUTILS_H
00016
00017 #include "unicode/utypes.h"
00018
00019 #ifdef XP_CPLUSPLUS
00020
00021 #include "cmemory.h"
00022 #include "unicode/unistr.h"
00023
00024
00025
00026
00027
00028 inline void uprv_arrayCopy(const double* src, double* dst, int32_t count)
00029 { uprv_memcpy(dst, src, (size_t)(count * sizeof(*src))); }
00030
00031 inline void uprv_arrayCopy(const double* src, int32_t srcStart,
00032 double* dst, int32_t dstStart, int32_t count)
00033 { uprv_memcpy(dst+dstStart, src+srcStart, (size_t)(count * sizeof(*src))); }
00034
00035 inline void uprv_arrayCopy(const int8_t* src, int8_t* dst, int32_t count)
00036 { uprv_memcpy(dst, src, (size_t)(count * sizeof(*src))); }
00037
00038 inline void uprv_arrayCopy(const int8_t* src, int32_t srcStart,
00039 int8_t* dst, int32_t dstStart, int32_t count)
00040 { uprv_memcpy(dst+dstStart, src+srcStart, (size_t)(count * sizeof(*src))); }
00041
00042 inline void uprv_arrayCopy(const int16_t* src, int16_t* dst, int32_t count)
00043 { uprv_memcpy(dst, src, (size_t)(count * sizeof(*src))); }
00044
00045 inline void uprv_arrayCopy(const int16_t* src, int32_t srcStart,
00046 int16_t* dst, int32_t dstStart, int32_t count)
00047 { uprv_memcpy(dst+dstStart, src+srcStart, (size_t)(count * sizeof(*src))); }
00048
00049 inline void uprv_arrayCopy(const int32_t* src, int32_t* dst, int32_t count)
00050 { uprv_memcpy(dst, src, (size_t)(count * sizeof(*src))); }
00051
00052 inline void uprv_arrayCopy(const int32_t* src, int32_t srcStart,
00053 int32_t* dst, int32_t dstStart, int32_t count)
00054 { uprv_memcpy(dst+dstStart, src+srcStart, (size_t)(count * sizeof(*src))); }
00055
00056 inline void
00057 uprv_arrayCopy(const UChar *src, int32_t srcStart,
00058 UChar *dst, int32_t dstStart, int32_t count)
00059 { uprv_memcpy(dst+dstStart, src+srcStart, (size_t)(count * sizeof(*src))); }
00060
00061
00062
00063
00064
00065 U_CAPI void U_EXPORT2 T_fillOutputParams(const UnicodeString* temp,
00066 UChar* result,
00067 const int32_t resultLength,
00068 int32_t* resultLengthOut,
00069 UErrorCode* status);
00070 #endif
00071
00072
00073
00074
00075 #endif