表格格式化程序
public class TableFormatter
extends Object
java.lang.Object | |
↳ | com.android.tradefed.util.TableFormatter |
用於顯示 String 元素矩陣的幫助程序類,因此每個元素列都排成一行
概括
公共構造函數 | |
---|---|
TableFormatter () |
公共方法 | |
---|---|
void | displayTable ( table, PrintWriter writer) displayTable ( table, PrintWriter writer) 將給定的 String 元素顯示為具有對齊列的表格。 |
TableFormatter | setColumnSpacing (int spacing) 設置每列之間的空白字符數。 |
公共構造函數
表格格式化程序
public TableFormatter ()
公共方法
顯示表
public void displayTable (table, PrintWriter writer)
將給定的 String 元素顯示為具有對齊列的表格。
參數 | |
---|---|
table | |
writer | PrintWriter :將輸出轉儲到的ERROR(/PrintWriter) |
設置列間距
public TableFormatter setColumnSpacing (int spacing)
設置每列之間的空白字符數。
參數 | |
---|---|
spacing | int : 空白字符的數量 |
退貨 | |
---|---|
TableFormatter | TableFormatter |