共用方式為


_Format.FormatToCharacterIterator(Object) Method

Definition

Formats an Object producing an AttributedCharacterIterator.

[Android.Runtime.Register("formatToCharacterIterator", "(Ljava/lang/Object;)Ljava/text/AttributedCharacterIterator;", "GetFormatToCharacterIterator_Ljava_lang_Object_Handler")]
public virtual Java.Text.IAttributedCharacterIterator? FormatToCharacterIterator (Java.Lang.Object? obj);
[<Android.Runtime.Register("formatToCharacterIterator", "(Ljava/lang/Object;)Ljava/text/AttributedCharacterIterator;", "GetFormatToCharacterIterator_Ljava_lang_Object_Handler")>]
abstract member FormatToCharacterIterator : Java.Lang.Object -> Java.Text.IAttributedCharacterIterator
override this.FormatToCharacterIterator : Java.Lang.Object -> Java.Text.IAttributedCharacterIterator

Parameters

obj
Object

The object to format

Returns

AttributedCharacterIterator describing the formatted value.

Attributes

Exceptions

if the object cannot be formatted by this format.

Remarks

Formats an Object producing an AttributedCharacterIterator. You can use the returned AttributedCharacterIterator to build the resulting String, as well as to determine information about the resulting String.

Each attribute key of the AttributedCharacterIterator will be of type Field. It is up to each Format implementation to define what the legal values are for each attribute in the AttributedCharacterIterator, but typically the attribute key is also used as the attribute value.

The default implementation creates an AttributedCharacterIterator with no attributes. Subclasses that support fields should override this and create an AttributedCharacterIterator with meaningful attributes.

Added in 1.4.

Java documentation for java.text.Format.formatToCharacterIterator(java.lang.Object).

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