Various small fixes

This commit is contained in:
Christopher Schnick
2022-02-19 02:53:58 +01:00
parent a9ee9c1bdc
commit bcc581c0bd
10 changed files with 74 additions and 22 deletions

View File

@@ -17,6 +17,22 @@ import java.util.Map;
*/
public interface DataSource {
/**
* Creates a new supplier data source that will be interpreted as the generated data source.
* In case this program should be a data source generator, this method has to be called at
* least once to register that it actually generates a data source.
*
* All content that is written to this data source until the generator program terminates is
* will be available later on when the data source is used as a supplier later on.
*
* In case this method is called multiple times, the same data source is returned.
*
* @return the generator data source
*/
static DataSource supplySource() {
return null;
}
/**
* Wrapper for {@link #get(DataSourceId)}.
*

View File

@@ -9,6 +9,13 @@ import java.util.stream.Stream;
public interface DataTable extends Iterable<TupleNode>, DataSource {
/**
* @see DataSource#supplySource()
*/
static DataTable supplySource() {
return null;
}
Stream<TupleNode> stream();
int getRowCount();