use of org.talend.core.model.process.IExternalData.ExternalDataType in project tdi-studio-se by Talend.
the class MapDataDelegateHelper method getExpressionColumns.
/**
*
* ggu Comment method "getExpressionColumns".
*
* @param expression -> if null, will return the all table for type
* @param types ->
* @return
*/
public Map<IExternalMapTable, List<IExternalMapEntry>> getExpressionColumns(String expression, ExternalDataType... types) {
Map<IExternalMapTable, List<IExternalMapEntry>> tableMap = new HashMap<IExternalMapTable, List<IExternalMapEntry>>();
if (types != null && types.length > 0) {
for (ExternalDataType type : types) {
switch(type) {
case INPUT:
return getExpressionColumns(getInputTables(), expression);
case OUTPUT:
return getExpressionColumns(getOutputTables(), expression);
case VAR:
return getExpressionColumns(getVarsTables(), expression);
default:
}
}
} else {
addAll(tableMap, getExpressionColumns(getInputTables(), expression));
addAll(tableMap, getExpressionColumns(getOutputTables(), expression));
addAll(tableMap, getExpressionColumns(getVarsTables(), expression));
}
return tableMap;
}
Aggregations