Home | History | Annotate | Download | only in i18n

Lines Matching defs:skeleton

69 DateIntervalFormat::createInstance(const UnicodeString& skeleton, 
71 return createInstance(skeleton, Locale::getDefault(), status);
76 DateIntervalFormat::createInstance(const UnicodeString& skeleton,
83 skeleton.extract(0, skeleton.length(), result, "UTF-8");
87 sprintf(mesg, "skeleton: %s; pattern: %s\n", result, result_1);
92 return create(locale, dtitvinf, &skeleton, status);
98 DateIntervalFormat::createInstance(const UnicodeString& skeleton,
101 return createInstance(skeleton, Locale::getDefault(), dtitvinf, status);
106 DateIntervalFormat::createInstance(const UnicodeString& skeleton,
111 return create(locale, ptn, &skeleton, status);
465 const UnicodeString* skeleton,
478 SimpleDateFormat* dtfmt = createSDFPatternInstance(*skeleton, locale,
494 if ( skeleton ) {
495 fSkeleton = *skeleton;
511 DateIntervalFormat::createSDFPatternInstance(const UnicodeString& skeleton,
520 const UnicodeString pattern = dtpng->getBestPattern(skeleton, status);
536 const UnicodeString* skeleton,
539 skeleton, status);
562 * For example, it has interval patterns on skeleton "dMy" and "hm",
563 * but it does not have interval patterns on skeleton "dMyhm".
565 * The rule to genearte interval patterns for both date and time skeleton are
581 * For example, a pattern/skeleton is "hm", but the interval pattern
605 // or by createInstance(UnicodeString skeleton, .... )
618 /* Check whether the skeleton is a combination of date and time.
627 /* the difference between time skeleton and normalizedTimeSkeleton are:
628 * 1. (Formerly, normalized time skeleton folded 'H' to 'h'; no longer true)
629 * 2. 'a' is omitted in normalized time skeleton.
631 * time skeleton
633 * The difference between date skeleton and normalizedDateSkeleton are:
679 } // end of skeleton not found
680 // interval patterns for skeleton are found in resource
709 UnicodeString skeleton = fSkeleton;
711 // prefix skeleton with 'd'
712 skeleton.insert(0, LOW_D);
713 setFallbackPattern(UCAL_DATE, skeleton, status);
716 // then prefix skeleton with 'M'
717 skeleton.insert(0, CAP_M);
718 setFallbackPattern(UCAL_MONTH, skeleton, status);
721 // then prefix skeleton with 'y'
722 skeleton.insert(0, LOW_Y);
723 setFallbackPattern(UCAL_YEAR, skeleton, status);
772 DateIntervalFormat::getDateTimeSkeleton(const UnicodeString& skeleton,
790 for (i = 0; i < skeleton.length(); ++i) {
791 UChar ch = skeleton[i];
926 * 2. there might be no pattern for 'y' differ for skeleton "Md",
928 * need to look for it from skeleton 'yMd'
930 * @param dateSkeleton normalized date skeleton
931 * @param timeSkeleton normalized time skeleton
932 * @return whether the resource is found for the skeleton.
933 * TRUE if interval pattern found for the skeleton,
941 const UnicodeString* skeleton;
942 // if both date and time skeleton present,
948 skeleton = &timeSkeleton;
950 skeleton = &dateSkeleton;
953 /* interval patterns for skeleton "dMMMy" (but not "dMMMMy")
955 * interval patterns for skeleton "dMMMMy" are calculated by
956 * 1. get the best match skeleton for "dMMMMy", which is "dMMMy"
961 // best skeleton, and the difference information
963 const UnicodeString* bestSkeleton = fInfo->getBestSkeleton(*skeleton,
965 /* best skeleton could be NULL.
972 and the best skeleton match could be NULL
979 // 0 means the best matched skeleton is the same as input skeleton
984 // skeleton has different fields, not only v/z difference
991 // only has date skeleton
992 setIntervalPattern(UCAL_DATE, skeleton, bestSkeleton, differenceInfo,
995 UBool extended = setIntervalPattern(UCAL_MONTH, skeleton, bestSkeleton,
1001 skeleton = &extendedSkeleton;
1003 setIntervalPattern(UCAL_YEAR, skeleton, bestSkeleton, differenceInfo,
1006 setIntervalPattern(UCAL_MINUTE, skeleton, bestSkeleton, differenceInfo);
1007 setIntervalPattern(UCAL_HOUR, skeleton, bestSkeleton, differenceInfo);
1008 setIntervalPattern(UCAL_AM_PM, skeleton, bestSkeleton, differenceInfo);
1017 const UnicodeString& skeleton,
1022 UnicodeString pattern = fDtpng->getBestPattern(skeleton, status);
1109 * but also return the extended skeleton and its best match skeleton.
1112 * @param skeleton skeleton
1113 * @param bestSkeleton the best match skeleton which has interval pattern
1115 * @param differenceInfo the difference between skeleton and best skeleton
1116 * 0 means the best matched skeleton is the same as input skeleton
1121 * @param extendedSkeleton extended skeleton
1122 * @param extendedBestSkeleton extended best match skeleton
1124 * through extending skeleton or not.
1126 * extending skeleton, FALSE otherwise.
1131 const UnicodeString* skeleton,
1158 // else, looking for pattern when 'y' differ for 'dMMMM' skeleton,
1160 // since there is no pattern for 'y' differs for skeleton 'MMMd',
1161 // need to look for it from skeleton 'yMMMd',
1166 *extendedSkeleton = *skeleton;
1171 // skeleton "MMMM".
1174 // if there is no skeleton "yMMMM" defined,
1175 // look for the best match skeleton, for example: "yMMM"
1188 adjustFieldWidth(*skeleton, *bestSkeleton, pattern, differenceInfo,
1312 const UnicodeString& skeleton)
1315 return ( (skeleton.indexOf(fieldChar) == -1)?FALSE:TRUE ) ;
1373 // there is no "L" (always be "M") in skeleton,
1375 // for skeleton "M+", the pattern might be "...L..."
1412 // there is no "L" (always be "M") in skeleton,
1414 // for skeleton "M+", the pattern might be "...L..."