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

stringByAddingPercentEscapesUsingEncoding:

Returns a representation of the receiver using a given encoding to determine the percent escapes necessary to convert the receiver into a legal URL string. レシーバのある表現を返します、レシーバを合法なURL文字列へ変換するのに必要なパーセントエスケープを決定するのに与えられた符号化を使います。

Declaration 宣言

- (NSString *)stringByAddingPercentEscapesUsingEncoding:(NSStringEncoding)enc;

Parameters パラメータ

encoding

The encoding to use for the returned string. If you are uncertain of the correct encoding you should use NSUTF8StringEncoding. 返される文字列に対して使われる符号化。あなたが正しい符号化に関心がないならばあなたはNSUTF8StringEncodingを使うべきです。

Return Value 戻り値

A representation of the receiver using encoding to determine the percent escapes necessary to convert the receiver into a legal URL string. Returns nil if encoding cannot encode a particular character. レシーバのある表現、レシーバを合法なURL文字列へと変換するのに必要なパーセントエスケープを決定するのにencodingを使っています。nilを返します、もしencodingが特定の文字を符号化できないならば。

Discussion 議論

It may be difficult to use this function to "clean up" unescaped or partially escaped URL strings where sequences are unpredictable. See CFURLCreateStringByAddingPercentEscapes for more information. この関数を使って、エスケープされないまたは部分的にエスケープされるURL文字列で、並びが予測できないものを "掃除" するのは、難しいかもしれません。CFURLCreateStringByAddingPercentEscapesをさらなる情報のために見てください。

See Also 参照

Deprecated 非推奨

Related Documentation 関連文書