diff --git a/java-client/barrage/src/main/java/io/deephaven/client/impl/BarrageSnapshot.java b/java-client/barrage/src/main/java/io/deephaven/client/impl/BarrageSnapshot.java index df605e9f32e..ab1f1759c26 100644 --- a/java-client/barrage/src/main/java/io/deephaven/client/impl/BarrageSnapshot.java +++ b/java-client/barrage/src/main/java/io/deephaven/client/impl/BarrageSnapshot.java @@ -5,6 +5,7 @@ import io.deephaven.engine.rowset.RowSet; import io.deephaven.engine.table.Table; +import io.deephaven.engine.table.TableDefinition; import io.deephaven.extensions.barrage.BarrageSnapshotOptions; import io.deephaven.qst.table.TableSpec; import org.jetbrains.annotations.Nullable; @@ -55,6 +56,11 @@ BarrageSnapshot snapshot(TableSpec tableSpec, BarrageSnapshotOptions options) BarrageSnapshot snapshot(TableHandle tableHandle, BarrageSnapshotOptions options); } + /** + * @return the {@link TableDefinition} of the subscribed table + */ + TableDefinition getTableDefinition(); + /** * Request a full snapshot of the data and populate a {@link Table} with the data that is received. The returned * future will block until all rows for the snapshot table are available. diff --git a/java-client/barrage/src/main/java/io/deephaven/client/impl/BarrageSnapshotImpl.java b/java-client/barrage/src/main/java/io/deephaven/client/impl/BarrageSnapshotImpl.java index 3965540ad01..d2f06c720dd 100644 --- a/java-client/barrage/src/main/java/io/deephaven/client/impl/BarrageSnapshotImpl.java +++ b/java-client/barrage/src/main/java/io/deephaven/client/impl/BarrageSnapshotImpl.java @@ -176,6 +176,11 @@ public void onCompleted() { } } + @Override + public TableDefinition getTableDefinition() { + return resultTable.getDefinition(); + } + @Override public Future entireTable() { return partialTable(null, null, false); diff --git a/java-client/barrage/src/main/java/io/deephaven/client/impl/BarrageSubscription.java b/java-client/barrage/src/main/java/io/deephaven/client/impl/BarrageSubscription.java index 69814c78899..3fe80623688 100644 --- a/java-client/barrage/src/main/java/io/deephaven/client/impl/BarrageSubscription.java +++ b/java-client/barrage/src/main/java/io/deephaven/client/impl/BarrageSubscription.java @@ -7,6 +7,7 @@ import io.deephaven.engine.liveness.LivenessScopeStack; import io.deephaven.engine.rowset.RowSet; import io.deephaven.engine.table.Table; +import io.deephaven.engine.table.TableDefinition; import io.deephaven.extensions.barrage.BarrageSubscriptionOptions; import io.deephaven.qst.table.TableSpec; import io.deephaven.util.SafeCloseable; @@ -60,6 +61,11 @@ BarrageSubscription subscribe(TableSpec tableSpec, BarrageSubscriptionOptions op BarrageSubscription subscribe(TableHandle tableHandle, BarrageSubscriptionOptions options); } + /** + * @return the {@link TableDefinition} of the subscribed table + */ + TableDefinition getTableDefinition(); + /** * Request a full subscription of the data and populate a {@link Table} with the incrementally updating data that is * received. The returned future will block until all rows for the subscribed table are available. diff --git a/java-client/barrage/src/main/java/io/deephaven/client/impl/BarrageSubscriptionImpl.java b/java-client/barrage/src/main/java/io/deephaven/client/impl/BarrageSubscriptionImpl.java index 69d05206b16..5ee5a8bb841 100644 --- a/java-client/barrage/src/main/java/io/deephaven/client/impl/BarrageSubscriptionImpl.java +++ b/java-client/barrage/src/main/java/io/deephaven/client/impl/BarrageSubscriptionImpl.java @@ -170,6 +170,11 @@ public void onCompleted() { } } + @Override + public TableDefinition getTableDefinition() { + return resultTable.getDefinition(); + } + @Override public Future
entireTable() { return partialTable(null, null, false);