Out
Source: lib/Out.cs
This page is generated from the source by scripts/gen-reference.py.
Buffered stdout writer for zero mode.
zerocore has no Console, and bflat's zerolib has one that makes a syscall per character. This writer buffers output, encodes it as UTF-8, prints numbers, bools and spans, and hands each line to libc write() in one call.
Out.Line($"x = , name = {name,-8}, ratio = ") formats every hole straight into the buffer: no string is built. See Fmt (lib/Str.cs) for the format strings.
Members
Write
public static void Write(ReadOnlySpan<char> text)
public static void Write(string text)
WriteUtf8
public static void WriteUtf8(ReadOnlySpan<byte> bytes)
Writes bytes that are already UTF-8 (or any bytes), as they are.
Write
public static void Write(char value)
public static void Write(long value)
public static void Write(double value, string format = null)
Default: up to 6 decimals, trailing zeros removed. "F2" etc. gives fixed decimals.
public static void Write(bool value)
public static void Write(ref InterpolatedHandler handler)
Writes $"..." straight into the buffer.
Line
public static void Line()
public static void Line(ReadOnlySpan<char> text)
public static void Line(string text)
public static void Line(ref InterpolatedHandler handler)
Writes $"..." straight into the buffer, then a newline.
public static void Line(string text, long value)
public static void Line(string text1, long value, string text2)
public static void Line(string text1, long value1, string text2, long value2)
Flush
public static void Flush()