com.clickzetta.platform.client.MultiRowCreate Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of clickzetta-java Show documentation
Show all versions of clickzetta-java Show documentation
The java SDK for clickzetta's Lakehouse
package com.clickzetta.platform.client;
import com.clickzetta.platform.client.api.Row;
public interface MultiRowCreate extends RowCreate {
/**
* create InsertRow.
*
* @return
*/
Row createInsertRow(String schemaName, String tableName);
/**
* create InsertIgnoreRow.
*
* @return
*/
Row createInsertIgnoreRow(String schemaName, String tableName);
/**
* create UpdateRow.
*
* @return
*/
Row createUpdateRow(String schemaName, String tableName);
/**
* create UpsertRow.
*
* @return
*/
Row createUpsertRow(String schemaName, String tableName);
/**
* create DeleteRow.
*
* @return
*/
Row createDeleteRow(String schemaName, String tableName);
/**
* create DeleteIgnoreRow.
*
* @return
*/
Row createDeleteIgnoreRow(String schemaName, String tableName);
/**
* create stream row with target operator.
*
* @param operator
* @return
*/
default Row createRow(Operator operator, String schemaName, String tableName) {
Row row = null;
switch (operator) {
case INSERT:
row = createInsertRow(schemaName, tableName);
break;
case INSERT_IGNORE:
row = createInsertIgnoreRow(schemaName, tableName);
break;
case UPDATE:
row = createUpdateRow(schemaName, tableName);
break;
case UPSERT:
row = createUpsertRow(schemaName, tableName);
break;
case DELETE:
row = createDeleteRow(schemaName, tableName);
break;
case DELETE_IGNORE:
row = createDeleteIgnoreRow(schemaName, tableName);
break;
}
return row;
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy