Пример #1
0
 /** @see NumberFormat#parseObject(String, ParsePosition) */
 public Object parseObject(Locale locale, String source, ParsePosition pos) throws ParseException {
   try (BlockingQueueTaker<NumberFormat> formatTaker = numberFormatTaker(locale)) {
     return formatTaker.take().parseObject(source, pos);
   }
 }
Пример #2
0
 /** @see NumberFormat#parse(String) */
 public Number parse(Locale locale, String source) throws ParseException {
   try (BlockingQueueTaker<NumberFormat> formatTaker = numberFormatTaker(locale)) {
     return formatTaker.take().parse(source);
   }
 }
Пример #3
0
 /** @see NumberFormat#format(Object) */
 public String format(Locale locale, Object object) {
   try (BlockingQueueTaker<NumberFormat> formatTaker = numberFormatTaker(locale)) {
     return formatTaker.take().format(object);
   }
 }
Пример #4
0
 /** @see NumberFormat#format(Object, StringBuffer, FieldPosition) */
 public StringBuffer format(
     Locale locale, Object object, StringBuffer toAppendTo, FieldPosition pos) {
   try (BlockingQueueTaker<NumberFormat> formatTaker = numberFormatTaker(locale)) {
     return formatTaker.take().format(object, toAppendTo, pos);
   }
 }
Пример #5
0
 /** @see NumberFormat#format(long) */
 public String format(Locale locale, long number) {
   try (BlockingQueueTaker<NumberFormat> formatTaker = numberFormatTaker(locale)) {
     return formatTaker.take().format(number);
   }
 }