NanoByte.Common  2.7.5
NanoByte.Common.AnsiCli Class Reference

Helper methods for ANSI console rendering. More...

Static Public Member Functions

static IRenderable Title (string title)
 Formats text as a title. More...
 
static IRenderable Table< T > (IEnumerable< T > data)
 Formats data as a table. More...
 
static IRenderable Tree< T > (NamedCollection< T > data, char separator=Named.TreeSeparator)
 Formats data as a tree. More...
 

Properties

static IAnsiConsole Error = AnsiConsole.Create(new AnsiConsoleSettings {Out = Console.Error}) [get]
 Used to write to the standard error stream. More...
 

Detailed Description

Helper methods for ANSI console rendering.

Member Function Documentation

◆ Table< T >()

static IRenderable NanoByte.Common.AnsiCli.Table< T > ( IEnumerable< T >  data)
inlinestatic

Formats data as a table.

Parameters
dataThe data to format.

◆ Title()

static IRenderable NanoByte.Common.AnsiCli.Title ( string  title)
static

Formats text as a title.

◆ Tree< T >()

static IRenderable NanoByte.Common.AnsiCli.Tree< T > ( NamedCollection< T >  data,
char  separator = Named.TreeSeparator 
)
inlinestatic

Formats data as a tree.

Parameters
dataThe data to show as nodes in the tree.
separatorThe character used to split INamed.Names into tree levels.
Type Constraints
T :INamed 

Property Documentation

◆ Error

IAnsiConsole NanoByte.Common.AnsiCli.Error = AnsiConsole.Create(new AnsiConsoleSettings {Out = Console.Error})
staticget

Used to write to the standard error stream.


The documentation for this class was generated from the following file: