UnicodeTranscode.Options
コレクションでコンテンツを整理
必要に応じて、コンテンツの保存と分類を行います。
継承されたメソッド
クラスjava.lang.Objectからブール値 | 等しい(オブジェクト arg0) |
最終クラス<?> | getクラス() |
整数 | ハッシュコード() |
最後の空白 | 通知する() |
最後の空白 | すべて通知() |
弦 | toString () |
最後の空白 | wait (long arg0, int arg1) |
最後の空白 | 待機(長い引数0) |
最後の空白 | 待って() |
パブリックメソッド
パラメーター
エラー | 入力に無効な形式が見つかった場合のエラー処理ポリシー。 'strict' の値を指定すると、無効な入力形式に対して操作で InvalidArgument エラーが生成されます。値「replace」(デフォルト) を指定すると、入力内の無効な書式設定が「replacement_char」コードポイントで置き換えられます。値が「ignore」の場合、操作では入力内の無効な書式設定がスキップされ、対応する出力文字は生成されません。 |
---|
public UnicodeTranscode.Options replaceControlCharacters (ブール値 replaceControlCharacters)
パラメーター
制御文字を置き換える | C0 制御文字 (00 ~ 1F) を `replacement_char` に置き換えるかどうか。デフォルトは false です。 |
---|
パラメーター
置換文字 | `errors='replace'` の場合に、入力内の無効な書式設定の代わりに使用される置換文字コードポイント。任意の有効な Unicode コードポイントを使用できます。デフォルト値は、デフォルトの Unicode 置換文字 0xFFFD または U+65533 です。) UTF-8 の場合、「 」などの 1 バイトで表現可能な置換文字を渡すと、無効なバイトが 1 バイトの置換文字に置き換えられるため、ソースとの文字列の位置合わせが維持されることに注意してください。 UTF-16-BE および UTF-16-LE の場合、1 バイトまたは 2 バイトの置換文字はソースへのバイト アラインメントを保持します。 |
---|
特に記載のない限り、このページのコンテンツはクリエイティブ・コモンズの表示 4.0 ライセンスにより使用許諾されます。コードサンプルは Apache 2.0 ライセンスにより使用許諾されます。詳しくは、Google Developers サイトのポリシーをご覧ください。Java は Oracle および関連会社の登録商標です。
最終更新日 2025-07-25 UTC。
[null,null,["最終更新日 2025-07-25 UTC。"],[],[],null,["# UnicodeTranscode.Options\n\npublic static class **UnicodeTranscode.Options** \nOptional attributes for [UnicodeTranscode](/jvm/api_docs/java/org/tensorflow/op/strings/UnicodeTranscode) \n\n### Public Methods\n\n|---------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| [UnicodeTranscode.Options](/jvm/api_docs/java/org/tensorflow/op/strings/UnicodeTranscode.Options) | [errors](/jvm/api_docs/java/org/tensorflow/op/strings/UnicodeTranscode.Options#errors(java.lang.String))(String errors) |\n| [UnicodeTranscode.Options](/jvm/api_docs/java/org/tensorflow/op/strings/UnicodeTranscode.Options) | [replaceControlCharacters](/jvm/api_docs/java/org/tensorflow/op/strings/UnicodeTranscode.Options#replaceControlCharacters(java.lang.Boolean))(Boolean replaceControlCharacters) |\n| [UnicodeTranscode.Options](/jvm/api_docs/java/org/tensorflow/op/strings/UnicodeTranscode.Options) | [replacementChar](/jvm/api_docs/java/org/tensorflow/op/strings/UnicodeTranscode.Options#replacementChar(java.lang.Long))(Long replacementChar) |\n\n### Inherited Methods\n\nFrom class java.lang.Object \n\n|------------------|---------------------------|\n| boolean | equals(Object arg0) |\n| final Class\\\u003c?\\\u003e | getClass() |\n| int | hashCode() |\n| final void | notify() |\n| final void | notifyAll() |\n| String | toString() |\n| final void | wait(long arg0, int arg1) |\n| final void | wait(long arg0) |\n| final void | wait() |\n\nPublic Methods\n--------------\n\n#### public [UnicodeTranscode.Options](/jvm/api_docs/java/org/tensorflow/op/strings/UnicodeTranscode.Options)\n**errors**\n(String errors)\n\n\u003cbr /\u003e\n\n##### Parameters\n\n| errors | Error handling policy when there is invalid formatting found in the input. The value of 'strict' will cause the operation to produce a InvalidArgument error on any invalid input formatting. A value of 'replace' (the default) will cause the operation to replace any invalid formatting in the input with the \\`replacement_char\\` codepoint. A value of 'ignore' will cause the operation to skip any invalid formatting in the input and produce no corresponding output character. |\n|--------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n\n#### public [UnicodeTranscode.Options](/jvm/api_docs/java/org/tensorflow/op/strings/UnicodeTranscode.Options)\n**replaceControlCharacters**\n(Boolean replaceControlCharacters)\n\n\u003cbr /\u003e\n\n##### Parameters\n\n| replaceControlCharacters | Whether to replace the C0 control characters (00-1F) with the \\`replacement_char\\`. Default is false. |\n|--------------------------|-------------------------------------------------------------------------------------------------------|\n\n#### public [UnicodeTranscode.Options](/jvm/api_docs/java/org/tensorflow/op/strings/UnicodeTranscode.Options)\n**replacementChar**\n(Long replacementChar)\n\n\u003cbr /\u003e\n\n##### Parameters\n\n| replacementChar | The replacement character codepoint to be used in place of any invalid formatting in the input when \\`errors='replace'\\`. Any valid unicode codepoint may be used. The default value is the default unicode replacement character is 0xFFFD or U+65533.) Note that for UTF-8, passing a replacement character expressible in 1 byte, such as ' ', will preserve string alignment to the source since invalid bytes will be replaced with a 1-byte replacement. For UTF-16-BE and UTF-16-LE, any 1 or 2 byte replacement character will preserve byte alignment to the source. |\n|-----------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|"]]