Instance Method インスタンスメソッド

initWithXMLString:options:error:

Initializes and returns an NSXMLDocument object created from a string containing XML markup text. あるNSXMLDocumentオブジェクトを初期化して返します、XMLマークアップテキストを含んでいる文字列から作成されます。

Declaration 宣言

- (instancetype)initWithXMLString:(NSString *)string 
                          options:(NSXMLNodeOptions)mask 
                            error:(NSError * _Nullable *)error;

Parameters パラメータ

string

A string object containing XML markup text. XMLマークアップテキストを含んでいる文字列オブジェクト。

mask

A bit mask for input options. You can specify multiple options by bit-OR'ing them. See Constants for a list of valid input options. 入力オプションに対するビットマスク。あなたは、複数のオプションを指定することが、それらをビットORすることによって可能です。定数を有効な入力オプションの一覧として見てください。

error

An error object that, on return, identifies any parsing errors and warnings or connection problems. あるエラーオブジェクト、それは、戻りでは、あらゆる構文解析エラーおよび警告または接続問題を識別します。

Return Value 戻り値

An initialized NSXMLDocument object, or nil if initialization fails because of parsing errors or other reasons. 初期化されたNSXMLDocumentオブジェクト、またはnil、もし初期化が構文解析エラーまたは他の理由のために失敗するならば。

Discussion 議論

The encoding of the document is set to UTF-8. 書類の符号化はUTF-8に設定されます。

See Also 参照

Initializing NSXMLDocument Objects NSXMLDocumentオブジェクトを初期化する