Partager via


MeasureFormat.Format(Object, StringBuffer, FieldPosition) Method

Definition

Able to format Collection<? extends Measure>, Measure[], and Measure by delegating to formatMeasures.

[Android.Runtime.Register("format", "(Ljava/lang/Object;Ljava/lang/StringBuffer;Ljava/text/FieldPosition;)Ljava/lang/StringBuffer;", "GetFormat_Ljava_lang_Object_Ljava_lang_StringBuffer_Ljava_text_FieldPosition_Handler", ApiSince=24)]
public override Java.Lang.StringBuffer? Format (Java.Lang.Object? obj, Java.Lang.StringBuffer? toAppendTo, Java.Text.FieldPosition? fpos);
[<Android.Runtime.Register("format", "(Ljava/lang/Object;Ljava/lang/StringBuffer;Ljava/text/FieldPosition;)Ljava/lang/StringBuffer;", "GetFormat_Ljava_lang_Object_Ljava_lang_StringBuffer_Ljava_text_FieldPosition_Handler", ApiSince=24)>]
override this.Format : Java.Lang.Object * Java.Lang.StringBuffer * Java.Text.FieldPosition -> Java.Lang.StringBuffer

Parameters

obj
Object

must be a Collection&lt;? extends Measure&gt;, Measure[], or Measure object.

toAppendTo
StringBuffer

Formatted string appended here.

fpos
FieldPosition

Identifies a field in the formatted text.

Returns

Attributes

Remarks

Able to format Collection&lt;? extends Measure&gt;, Measure[], and Measure by delegating to formatMeasures. If the pos argument identifies a NumberFormat field, then its indices are set to the beginning and end of the first such field encountered. MeasureFormat itself does not supply any fields.

Calling a formatMeasures method is preferred over calling this method as they give better performance.

Java documentation for android.icu.text.MeasureFormat.format(java.lang.Object, java.lang.StringBuffer, java.text.FieldPosition).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to