SmartFormat by axuno gGmbH,Scott Rippey,SmartFormat Project maintainers and contributors.

<PackageReference Include="SmartFormat" Version="3.0.0" />

.NET API 390,144 bytes

 Utf8ValueStringBuilder

public static class FormatterCache<T>

public sealed delegate TryFormat<T> : MulticastDelegate

public int Length { get; }

Length of written buffer.

public Utf8ValueStringBuilder(bool disposeImmediately)

Initializes a new instance

public static void EnableNullableFormat<T>() where T : struct

Supports the Nullable type for a given struct type.

public static void RegisterTryFormat<T>(TryFormat<T> formatMethod)

Register custom formatter

public void Advance(int count)

IBufferWriter.Advance.

public void Append(char value)

Appends the string representation of a specified value to this instance.

public void Append(char value, int repeatCount)

public void Append(string value, int startIndex, int count)

public void Append(string value)

Appends the string representation of a specified value to this instance.

public void Append(ReadOnlySpan<char> value)

Appends a contiguous region of arbitrary memory to this instance.

public void Append<T>(T value)

Appends the string representation of a specified value to this instance.

public void Append(byte value)

Appends the string representation of a specified value to this instance.

public void Append(byte value, StandardFormat format)

Appends the string representation of a specified value to this instance with numeric format strings.

public void Append(DateTime value)

Appends the string representation of a specified value to this instance.

public void Append(DateTime value, StandardFormat format)

Appends the string representation of a specified value to this instance with numeric format strings.

public void Append(DateTimeOffset value)

Appends the string representation of a specified value to this instance.

public void Append(DateTimeOffset value, StandardFormat format)

Appends the string representation of a specified value to this instance with numeric format strings.

public void Append(decimal value)

Appends the string representation of a specified value to this instance.

public void Append(decimal value, StandardFormat format)

Appends the string representation of a specified value to this instance with numeric format strings.

public void Append(double value)

Appends the string representation of a specified value to this instance.

public void Append(double value, StandardFormat format)

Appends the string representation of a specified value to this instance with numeric format strings.

public void Append(short value)

Appends the string representation of a specified value to this instance.

public void Append(short value, StandardFormat format)

Appends the string representation of a specified value to this instance with numeric format strings.

public void Append(int value)

Appends the string representation of a specified value to this instance.

public void Append(int value, StandardFormat format)

Appends the string representation of a specified value to this instance with numeric format strings.

public void Append(long value)

Appends the string representation of a specified value to this instance.

public void Append(long value, StandardFormat format)

Appends the string representation of a specified value to this instance with numeric format strings.

public void Append(sbyte value)

Appends the string representation of a specified value to this instance.

public void Append(sbyte value, StandardFormat format)

Appends the string representation of a specified value to this instance with numeric format strings.

public void Append(float value)

Appends the string representation of a specified value to this instance.

public void Append(float value, StandardFormat format)

Appends the string representation of a specified value to this instance with numeric format strings.

public void Append(TimeSpan value)

Appends the string representation of a specified value to this instance.

public void Append(TimeSpan value, StandardFormat format)

Appends the string representation of a specified value to this instance with numeric format strings.

public void Append(ushort value)

Appends the string representation of a specified value to this instance.

public void Append(ushort value, StandardFormat format)

Appends the string representation of a specified value to this instance with numeric format strings.

public void Append(uint value)

Appends the string representation of a specified value to this instance.

public void Append(uint value, StandardFormat format)

Appends the string representation of a specified value to this instance with numeric format strings.

public void Append(ulong value)

Appends the string representation of a specified value to this instance.

public void Append(ulong value, StandardFormat format)

Appends the string representation of a specified value to this instance with numeric format strings.

public void Append(Guid value)

Appends the string representation of a specified value to this instance.

public void Append(Guid value, StandardFormat format)

Appends the string representation of a specified value to this instance with numeric format strings.

public void Append(bool value)

Appends the string representation of a specified value to this instance.

public void Append(bool value, StandardFormat format)

Appends the string representation of a specified value to this instance with numeric format strings.

public void AppendFormat<T1>(string format, T1 arg1)

Appends the string returned by processing a composite format string, each format item is replaced by the string representation of arguments.

public void AppendFormat<T1, T2>(string format, T1 arg1, T2 arg2)

Appends the string returned by processing a composite format string, each format item is replaced by the string representation of arguments.

public void AppendFormat<T1, T2, T3>(string format, T1 arg1, T2 arg2, T3 arg3)

Appends the string returned by processing a composite format string, each format item is replaced by the string representation of arguments.

public void AppendFormat<T1, T2, T3, T4>(string format, T1 arg1, T2 arg2, T3 arg3, T4 arg4)

Appends the string returned by processing a composite format string, each format item is replaced by the string representation of arguments.

public void AppendFormat<T1, T2, T3, T4, T5>(string format, T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5)

Appends the string returned by processing a composite format string, each format item is replaced by the string representation of arguments.

public void AppendFormat<T1, T2, T3, T4, T5, T6>(string format, T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6)

Appends the string returned by processing a composite format string, each format item is replaced by the string representation of arguments.

public void AppendFormat<T1, T2, T3, T4, T5, T6, T7>(string format, T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7)

Appends the string returned by processing a composite format string, each format item is replaced by the string representation of arguments.

public void AppendFormat<T1, T2, T3, T4, T5, T6, T7, T8>(string format, T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8)

Appends the string returned by processing a composite format string, each format item is replaced by the string representation of arguments.

public void AppendFormat<T1, T2, T3, T4, T5, T6, T7, T8, T9>(string format, T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9)

Appends the string returned by processing a composite format string, each format item is replaced by the string representation of arguments.

public void AppendFormat<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10>(string format, T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10)

Appends the string returned by processing a composite format string, each format item is replaced by the string representation of arguments.

public void AppendFormat<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11>(string format, T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10, T11 arg11)

Appends the string returned by processing a composite format string, each format item is replaced by the string representation of arguments.

public void AppendFormat<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12>(string format, T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10, T11 arg11, T12 arg12)

Appends the string returned by processing a composite format string, each format item is replaced by the string representation of arguments.

public void AppendFormat<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13>(string format, T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10, T11 arg11, T12 arg12, T13 arg13)

Appends the string returned by processing a composite format string, each format item is replaced by the string representation of arguments.

public void AppendFormat<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14>(string format, T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10, T11 arg11, T12 arg12, T13 arg13, T14 arg14)

Appends the string returned by processing a composite format string, each format item is replaced by the string representation of arguments.

public void AppendFormat<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15>(string format, T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10, T11 arg11, T12 arg12, T13 arg13, T14 arg14, T15 arg15)

Appends the string returned by processing a composite format string, each format item is replaced by the string representation of arguments.

public void AppendFormat<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15, T16>(string format, T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9, T10 arg10, T11 arg11, T12 arg12, T13 arg13, T14 arg14, T15 arg15, T16 arg16)

Appends the string returned by processing a composite format string, each format item is replaced by the string representation of arguments.

public void AppendJoin<T>(char separator, T[] values)

Concatenates the string representations of the elements in the provided array of objects, using the specified char separator between each member, then appends the result to the current instance of the string builder.

public void AppendJoin<T>(char separator, List<T> values)

public void AppendJoin<T>(char separator, ReadOnlySpan<T> values)

public void AppendJoin<T>(char separator, IEnumerable<T> values)

Concatenates and appends the members of a collection, using the specified char separator between each member.

public void AppendJoin<T>(char separator, ICollection<T> values)

public void AppendJoin<T>(char separator, IList<T> values)

public void AppendJoin<T>(char separator, IReadOnlyList<T> values)

public void AppendJoin<T>(char separator, IReadOnlyCollection<T> values)

public void AppendJoin<T>(string separator, T[] values)

Concatenates the string representations of the elements in the provided array of objects, using the specified separator between each member, then appends the result to the current instance of the string builder.

public void AppendJoin<T>(string separator, List<T> values)

public void AppendJoin<T>(string separator, ReadOnlySpan<T> values)

public void AppendJoin<T>(string separator, IEnumerable<T> values)

Concatenates and appends the members of a collection, using the specified separator between each member.

public void AppendJoin<T>(string separator, ICollection<T> values)

public void AppendJoin<T>(string separator, IList<T> values)

public void AppendJoin<T>(string separator, IReadOnlyList<T> values)

public void AppendJoin<T>(string separator, IReadOnlyCollection<T> values)

public void AppendLine()

Appends the default line terminator to the end of this instance.

public void AppendLine(char value)

Appends the string representation of a specified value followed by the default line terminator to the end of this instance.

public void AppendLine(string value)

Appends the string representation of a specified value followed by the default line terminator to the end of this instance.

public void AppendLine(ReadOnlySpan<char> value)

public void AppendLine<T>(T value)

Appends the string representation of a specified value followed by the default line terminator to the end of this instance.

public void AppendLine(byte value)

Appends the string representation of a specified value followed by the default line terminator to the end of this instance.

public void AppendLine(byte value, StandardFormat format)

Appends the string representation of a specified value with numeric format strings followed by the default line terminator to the end of this instance.

public void AppendLine(DateTime value)

Appends the string representation of a specified value followed by the default line terminator to the end of this instance.

public void AppendLine(DateTime value, StandardFormat format)

Appends the string representation of a specified value with numeric format strings followed by the default line terminator to the end of this instance.

public void AppendLine(DateTimeOffset value)

Appends the string representation of a specified value followed by the default line terminator to the end of this instance.

public void AppendLine(DateTimeOffset value, StandardFormat format)

Appends the string representation of a specified value with numeric format strings followed by the default line terminator to the end of this instance.

public void AppendLine(decimal value)

Appends the string representation of a specified value followed by the default line terminator to the end of this instance.

public void AppendLine(decimal value, StandardFormat format)

Appends the string representation of a specified value with numeric format strings followed by the default line terminator to the end of this instance.

public void AppendLine(double value)

Appends the string representation of a specified value followed by the default line terminator to the end of this instance.

public void AppendLine(double value, StandardFormat format)

Appends the string representation of a specified value with numeric format strings followed by the default line terminator to the end of this instance.

public void AppendLine(short value)

Appends the string representation of a specified value followed by the default line terminator to the end of this instance.

public void AppendLine(short value, StandardFormat format)

Appends the string representation of a specified value with numeric format strings followed by the default line terminator to the end of this instance.

public void AppendLine(int value)

Appends the string representation of a specified value followed by the default line terminator to the end of this instance.

public void AppendLine(int value, StandardFormat format)

Appends the string representation of a specified value with numeric format strings followed by the default line terminator to the end of this instance.

public void AppendLine(long value)

Appends the string representation of a specified value followed by the default line terminator to the end of this instance.

public void AppendLine(long value, StandardFormat format)

Appends the string representation of a specified value with numeric format strings followed by the default line terminator to the end of this instance.

public void AppendLine(sbyte value)

Appends the string representation of a specified value followed by the default line terminator to the end of this instance.

public void AppendLine(sbyte value, StandardFormat format)

Appends the string representation of a specified value with numeric format strings followed by the default line terminator to the end of this instance.

public void AppendLine(float value)

Appends the string representation of a specified value followed by the default line terminator to the end of this instance.

public void AppendLine(float value, StandardFormat format)

Appends the string representation of a specified value with numeric format strings followed by the default line terminator to the end of this instance.

public void AppendLine(TimeSpan value)

Appends the string representation of a specified value followed by the default line terminator to the end of this instance.

public void AppendLine(TimeSpan value, StandardFormat format)

Appends the string representation of a specified value with numeric format strings followed by the default line terminator to the end of this instance.

public void AppendLine(ushort value)

Appends the string representation of a specified value followed by the default line terminator to the end of this instance.

public void AppendLine(ushort value, StandardFormat format)

Appends the string representation of a specified value with numeric format strings followed by the default line terminator to the end of this instance.

public void AppendLine(uint value)

Appends the string representation of a specified value followed by the default line terminator to the end of this instance.

public void AppendLine(uint value, StandardFormat format)

Appends the string representation of a specified value with numeric format strings followed by the default line terminator to the end of this instance.

public void AppendLine(ulong value)

Appends the string representation of a specified value followed by the default line terminator to the end of this instance.

public void AppendLine(ulong value, StandardFormat format)

Appends the string representation of a specified value with numeric format strings followed by the default line terminator to the end of this instance.

public void AppendLine(Guid value)

Appends the string representation of a specified value followed by the default line terminator to the end of this instance.

public void AppendLine(Guid value, StandardFormat format)

Appends the string representation of a specified value with numeric format strings followed by the default line terminator to the end of this instance.

public void AppendLine(bool value)

Appends the string representation of a specified value followed by the default line terminator to the end of this instance.

public void AppendLine(bool value, StandardFormat format)

Appends the string representation of a specified value with numeric format strings followed by the default line terminator to the end of this instance.

public void AppendLiteral(ReadOnlySpan<byte> value)

Get the written buffer data.

public ReadOnlyMemory<byte> AsMemory()

Get the written buffer data.

public ReadOnlySpan<byte> AsSpan()

Get the written buffer data.

public void Clear()

public void CopyTo(IBufferWriter<byte> bufferWriter)

Copy inner buffer to the bufferWriter.

public void Dispose()

Return the inner buffer to pool.

public Memory<byte> GetMemory(int sizeHint)

IBufferWriter.GetMemory.

public Span<byte> GetSpan(int sizeHint)

IBufferWriter.GetSpan.

public void Grow(int sizeHint)

public bool TryCopyTo(Span<byte> destination, out int bytesWritten)

Copy inner buffer to the destination span.

public void TryGrow(int sizeHint)

public Task WriteToAsync(Stream stream)

Write inner buffer to stream.

public Task WriteToAsync(Stream stream, CancellationToken cancellationToken)

Write inner buffer to stream.