@Test public void valueTable1() { VDouble value1 = newVDouble(3.1); VDouble value2 = newVDouble(3.2, newAlarm(AlarmSeverity.MINOR, "HI"), timeNow(), displayNone()); VDouble value3 = newVDouble(3.3); VTable table = valueTable(Arrays.asList(value1, value2, value3)); assertThat(table.getColumnCount(), equalTo(3)); assertThat(table.getRowCount(), equalTo(3)); assertThat(table.getColumnName(0), equalTo("Value")); assertThat(table.getColumnName(1), equalTo("Severity")); assertThat(table.getColumnName(2), equalTo("Status")); assertThat(table.getColumnType(0), equalTo((Object) double.class)); assertThat(table.getColumnType(1), equalTo((Object) String.class)); assertThat(table.getColumnType(2), equalTo((Object) String.class)); assertThat(table.getColumnData(0), equalTo((Object) new ArrayDouble(3.1,3.2,3.3))); assertThat(table.getColumnData(1), equalTo((Object) Arrays.asList("NONE", "MINOR", "NONE"))); assertThat(table.getColumnData(2), equalTo((Object) Arrays.asList("NONE", "HI", "NONE"))); }
public static VTable valueTable(List<? extends VType> values) { return valueTable(null, values); }
VTableFactory { public static VTable valueTable(List<? extends VType> values) { return valueTable(null, values); } }
VTableFactory { public static VTable valueTable(List<? extends VType> values) { return valueTable(null, values); }  }
VTableFactory { public static VTable valueTable(List<? extends VType> values) { return valueTable(null, values); }  static VTable join(List<VTable> tables); static VTable join(VTable... tables); static VTable union(VString extraColumnName, final VStringArray extraColumnData, final VTable... tables); static VTable select(final VTable table, final ListInt indexes); static VTable newVTable(Column... columns); static Column column(String name, final VNumberArray numericArray); static Column column(String name, final VStringArray stringArray); static Column column(final String name, final ListNumberProvider dataProvider); static ListNumberProvider range(final double min, final double max); static ListNumberProvider step(final double initialValue, final double increment); static VTable extractRow(VTable vTable, int row); static List<String> columnNames(final VTable vTable); static List<Class<?>> columnTypes(final VTable vTable); static VTable valueTable(List<? extends VType> values); static VTable valueTable(List<String> names, List<? extends VType> values); static VTable tableValueFilter(VTable table, String columnName, Object value); static VTable tableStringMatchFilter(VTable table, String columnName, String substring); static VTable tableRangeFilter(VTable table, String columnName, Object min, Object max); static void validateTable(VTable vTable); }
VTableFactory { public static VTable valueTable(List<? extends VType> values) { return valueTable(null, values); }  static VTable join(List<VTable> tables); static VTable join(VTable... tables); static VTable union(VString extraColumnName, final VStringArray extraColumnData, final VTable... tables); static VTable select(final VTable table, final ListInt indexes); static VTable newVTable(Column... columns); static Column column(String name, final VNumberArray numericArray); static Column column(String name, final VStringArray stringArray); static Column column(final String name, final ListNumberProvider dataProvider); static ListNumberProvider range(final double min, final double max); static ListNumberProvider step(final double initialValue, final double increment); static VTable extractRow(VTable vTable, int row); static List<String> columnNames(final VTable vTable); static List<Class<?>> columnTypes(final VTable vTable); static VTable valueTable(List<? extends VType> values); static VTable valueTable(List<String> names, List<? extends VType> values); static VTable tableValueFilter(VTable table, String columnName, Object value); static VTable tableStringMatchFilter(VTable table, String columnName, String substring); static VTable tableRangeFilter(VTable table, String columnName, Object min, Object max); static void validateTable(VTable vTable);  }