Search in sources :

Example 1 with KsqlStdOut

use of io.confluent.ksql.metastore.KsqlStdOut in project ksql by confluentinc.

the class Analyzer method visitTable.

@Override
protected Node visitTable(final Table node, final AnalysisContext context) {
    StructuredDataSource into;
    if (node.isStdOut) {
        into = new KsqlStdOut(KsqlStdOut.KSQL_STDOUT_NAME, null, null, null, StructuredDataSource.DataSourceType.KSTREAM);
    } else if (context.getParentType() == AnalysisContext.ParentType.INTO) {
        into = analyzeNonStdOutTable(node);
    } else {
        throw new KsqlException("INTO clause is not set correctly!");
    }
    analysis.setInto(into);
    return null;
}
Also used : StructuredDataSource(io.confluent.ksql.metastore.StructuredDataSource) KsqlStdOut(io.confluent.ksql.metastore.KsqlStdOut) KsqlException(io.confluent.ksql.util.KsqlException)

Aggregations

KsqlStdOut (io.confluent.ksql.metastore.KsqlStdOut)1 StructuredDataSource (io.confluent.ksql.metastore.StructuredDataSource)1 KsqlException (io.confluent.ksql.util.KsqlException)1