public class KnoxShellTable extends Object
| Constructor and Description |
|---|
KnoxShellTable() |
| Modifier and Type | Method and Description |
|---|---|
KnoxShellTableAggregator |
aggregate() |
KnoxShellTable |
apply(org.apache.knox.gateway.shell.table.KnoxShellTableCell<? extends Comparable<? extends Object>> cell) |
static KnoxShellTableBuilder |
builder() |
org.apache.knox.gateway.shell.table.KnoxShellTableCell<? extends Comparable<? extends Object>> |
cell(int colIndex,
int rowIndex) |
KnoxShellTableFilter |
filter() |
String |
getCallHistory() |
List<org.apache.knox.gateway.shell.table.KnoxShellTableCall> |
getCallHistoryList() |
List<String> |
getHeaders() |
long |
getId() |
List<List<Comparable<? extends Object>>> |
getRows() |
String |
getTitle() |
KnoxShellTable |
header(String header) |
double |
max(int colIndex)
Calculates the max of specified column
|
double |
max(String colName)
Calculates the max of specified column
|
double |
mean(int colIndex)
Calculates the mean of specified column
|
double |
mean(String colName)
Calculates the mean of specified column
|
double |
median(int colIndex)
Calculates the median of specified column
|
double |
median(String colName)
Calculates the median of specified column
|
double |
min(int colIndex)
Calculates the min of specified column
|
double |
min(String colName)
Calculates the min of specified column
|
double |
mode(int colIndex)
Calculates the mode of specified column
|
double |
mode(String colName)
Calculates the mode of specified column
|
KnoxShellTable |
replay(int step) |
static KnoxShellTable |
replay(long id,
int step) |
KnoxShellTable |
replayAll() |
String |
rollback() |
KnoxShellTable |
row() |
KnoxShellTable |
select(String cols) |
KnoxShellTable |
sort(List<Comparable<? extends Object>> col,
SortOrder order) |
KnoxShellTable |
sort(String colName) |
KnoxShellTable |
sort(String colName,
SortOrder order) |
KnoxShellTable |
sortNumeric(String colName) |
double |
sum(int colIndex)
Calculates the sum of specified column
|
double |
sum(String colName)
Calculates the sum of specified column
|
KnoxShellTable |
title(String title) |
String |
toCSV() |
String |
toCSV(String filePath) |
String |
toJSON() |
String |
toJSON(boolean data) |
String |
toJSON(boolean data,
String path) |
String |
toJSON(String path) |
String |
toString() |
KnoxShellTable |
value(Comparable<? extends Object> value) |
List<Comparable<? extends Object>> |
values(int colIndex) |
List<Comparable<? extends Object>> |
values(String colName) |
public KnoxShellTable title(String title)
public KnoxShellTable header(String header)
public KnoxShellTable row()
public KnoxShellTable value(Comparable<? extends Object> value)
public org.apache.knox.gateway.shell.table.KnoxShellTableCell<? extends Comparable<? extends Object>> cell(int colIndex, int rowIndex)
public List<Comparable<? extends Object>> values(int colIndex)
public List<Comparable<? extends Object>> values(String colName)
public double mean(String colName)
colName - the column for which the mean will be calculatedpublic double mean(int colIndex)
colIndex - the column for which the mean will be calculatedpublic double median(String colName)
colName - the column for which the median will be calculatedpublic double median(int colIndex)
colIndex - the column for which the median will be calculatedpublic double mode(String colName)
colName - the column for which the mode will be calculatedpublic double mode(int colIndex)
colIndex - the column for which the mode will be calculatedpublic double sum(String colName)
colName - the column for which the sum will be calculatedpublic double sum(int colIndex)
colIndex - the column for which the sum will be calculatedpublic double max(String colName)
colName - the column for which the max will be calculatedpublic double max(int colIndex)
colIndex - the column for which the max will be calculatedpublic double min(String colName)
colName - the column for which the min will be calculatedpublic double min(int colIndex)
colIndex - the column for which the min will be calculatedpublic KnoxShellTable apply(org.apache.knox.gateway.shell.table.KnoxShellTableCell<? extends Comparable<? extends Object>> cell)
public List<List<Comparable<? extends Object>>> getRows()
public String getTitle()
public long getId()
public static KnoxShellTableBuilder builder()
public List<org.apache.knox.gateway.shell.table.KnoxShellTableCall> getCallHistoryList()
public String getCallHistory()
public String rollback()
public KnoxShellTable replayAll()
public KnoxShellTable replay(int step)
public static KnoxShellTable replay(long id, int step)
public KnoxShellTableFilter filter()
public KnoxShellTableAggregator aggregate()
public KnoxShellTable select(String cols)
public KnoxShellTable sort(String colName)
public KnoxShellTable sortNumeric(String colName)
public KnoxShellTable sort(String colName, SortOrder order)
public KnoxShellTable sort(List<Comparable<? extends Object>> col, SortOrder order)
public String toJSON()
public String toJSON(boolean data)
public String toCSV()
Copyright © 2020 The Apache Software Foundation. All rights reserved.