private static string BasisBladesInformationTable(IEnumerable<AstFrameBasisBlade> basisBladesList) { var composer = new TextColumnsComposer(7) { ColumnSeparator = " ", DefaultRowAlignment = TextRowAlignment.Top, DefaultColumnAlignment = TextColumnAlignment.Left }; composer.AppendToColumns("Grade", "Index", "ID", "Name", "Indexed Name", "Binary Name", "Grade+Index Name"); composer.AppendToColumns("-----", "-----", "--", "----", "------------", "-----------", "----------------"); foreach (var basisBlade in basisBladesList) composer.AppendToColumns( basisBlade.Grade.ToString(), basisBlade.Index.ToString(), basisBlade.BasisBladeId.ToString(), basisBlade.Name, basisBlade.IndexedName, basisBlade.BinaryIndexedName, basisBlade.GradeIndexName ); return composer.GenerateText(); }
private static TextColumnsComposer CreateColumnsComposer() { var composer = new TextColumnsComposer(2) { ColumnSeparator = " ", DefaultRowAlignment = TextRowAlignment.Top, DefaultColumnAlignment = TextColumnAlignment.Left }; composer.SetColumnAlignment(TextColumnAlignment.Right, 0); return composer; }