StreamWriter.WriteLine メソッド

定義

オーバーロード

WriteLine(String, Object, Object, Object)

Format(String, Object) と同じセマンティクスを使用して、書式設定された文字列と新しい行をストリームに書き込みます。

WriteLine(String, Object, Object)

Format(String, Object, Object) メソッドと同じセマンティクスを使用して、書式設定された文字列と新しい行をストリームに書き込みます。

WriteLine(String, Object[])

Format(String, Object) と同じセマンティクスを使用して、書式設定された文字列と新しい行をストリームに書き込みます。

WriteLine(String)

文字列を、続いて行終端記号をストリームに書き込みます。

WriteLine(ReadOnlySpan<Char>)

文字スパンのテキスト表現、続いて行終端記号をストリームに書き込みます。

WriteLine(String, Object)

Format(String, Object) メソッドと同じセマンティクスを使用して、書式設定された文字列と新しい行をストリームに書き込みます。

WriteLine(String, Object, Object, Object)

Format(String, Object) と同じセマンティクスを使用して、書式設定された文字列と新しい行をストリームに書き込みます。

public:
 override void WriteLine(System::String ^ format, System::Object ^ arg0, System::Object ^ arg1, System::Object ^ arg2);
public override void WriteLine (string format, object? arg0, object? arg1, object? arg2);
override this.WriteLine : string * obj * obj * obj -> unit
Public Overrides Sub WriteLine (format As String, arg0 As Object, arg1 As Object, arg2 As Object)

パラメーター

format
String

複合書式設定文字列。

arg0
Object

書式設定および書き込みをする最初のオブジェクト。

arg1
Object

書式設定および書き込みをする 2 番目のオブジェクト。

arg2
Object

書式設定および書き込みをする 3 番目のオブジェクト。

注釈

提供される複合書式設定機能の説明については、「」を参照してください WriteLine(String, Object, Object, Object)

適用対象

WriteLine(String, Object, Object)

Format(String, Object, Object) メソッドと同じセマンティクスを使用して、書式設定された文字列と新しい行をストリームに書き込みます。

public:
 override void WriteLine(System::String ^ format, System::Object ^ arg0, System::Object ^ arg1);
public override void WriteLine (string format, object? arg0, object? arg1);
override this.WriteLine : string * obj * obj -> unit
Public Overrides Sub WriteLine (format As String, arg0 As Object, arg1 As Object)

パラメーター

format
String

複合書式設定文字列。

arg0
Object

書式設定および書き込みをする最初のオブジェクト。

arg1
Object

書式設定および書き込みをする 2 番目のオブジェクト。

注釈

提供される複合書式設定機能の説明については、「」を参照してください WriteLine(String, Object, Object)

適用対象

WriteLine(String, Object[])

Format(String, Object) と同じセマンティクスを使用して、書式設定された文字列と新しい行をストリームに書き込みます。

public:
 override void WriteLine(System::String ^ format, ... cli::array <System::Object ^> ^ arg);
public override void WriteLine (string format, params object?[] arg);
override this.WriteLine : string * obj[] -> unit
Public Overrides Sub WriteLine (format As String, ParamArray arg As Object())

パラメーター

format
String

複合書式設定文字列。

arg
Object[]

書式設定および書き込みをする 0 個以上のオブジェクトを含むオブジェクト配列。

注釈

提供される複合書式設定機能の説明については、「」を参照してください WriteLine(String, Object[])

適用対象

WriteLine(String)

文字列を、続いて行終端記号をストリームに書き込みます。

public:
 override void WriteLine(System::String ^ value);
public override void WriteLine (string? value);
public override void WriteLine (string value);
override this.WriteLine : string -> unit
Public Overrides Sub WriteLine (value As String)

パラメーター

value
String

書き込む文字列。 valuenull の場合は、行終端記号だけを書き込みます。

注釈

このオーバーロードは、 オーバーロードと TextWriter.Write(Char[]) 同じです。

行終端記号は、CoreNewLine フィールドで定義されます。

このメソッドは、指定した文字列で個別の改行文字 (16 進数で 0x000a) を検索しないため、改行文字は NewLine に置き換えられません。

共通 I/O タスクの一覧は、 共通 I/O タスク を参照してください。

適用対象

WriteLine(ReadOnlySpan<Char>)

文字スパンのテキスト表現、続いて行終端記号をストリームに書き込みます。

public:
 override void WriteLine(ReadOnlySpan<char> buffer);
public override void WriteLine (ReadOnlySpan<char> buffer);
override this.WriteLine : ReadOnlySpan<char> -> unit
Public Overrides Sub WriteLine (buffer As ReadOnlySpan(Of Char))

パラメーター

buffer
ReadOnlySpan<Char>

ストリームに書き込む文字スパン。

注釈

指定した値のテキスト表現は、 ReadOnlySpan<Char を>呼び出すことによって生成されます。ToString メソッド。

行終端記号は、CoreNewLine フィールドで定義されます。

共通 I/O タスクの一覧は、 共通 I/O タスク を参照してください。

適用対象

WriteLine(String, Object)

Format(String, Object) メソッドと同じセマンティクスを使用して、書式設定された文字列と新しい行をストリームに書き込みます。

public:
 override void WriteLine(System::String ^ format, System::Object ^ arg0);
public override void WriteLine (string format, object? arg0);
override this.WriteLine : string * obj -> unit
Public Overrides Sub WriteLine (format As String, arg0 As Object)

パラメーター

format
String

複合書式設定文字列。

arg0
Object

書式設定および書き込みをするオブジェクト。

注釈

提供される複合書式設定機能の説明については、「」を参照してください WriteLine(String, Object)

適用対象