// GuidedDecisionTableUtils also handles data-types, enums etc and hence requires a DataModelOracle to function. Loading
// a DataModelOracle just to determine whether the model has DSLs is an expensive operation and not needed here.
public static boolean hasDSLSentences( final GuidedDecisionTable52 model ) {
for ( CompositeColumn<? extends BaseColumn> column : model.getConditions() ) {
if ( column instanceof BRLConditionColumn ) {
final BRLConditionColumn brlColumn = (BRLConditionColumn) column;
for ( IPattern pattern : brlColumn.getDefinition() ) {
if ( pattern instanceof DSLSentence ) {
return true;
}
}
}
}
for ( ActionCol52 column : model.getActionCols() ) {
if ( column instanceof BRLActionColumn ) {
final BRLActionColumn brlColumn = (BRLActionColumn) column;
for ( IAction action : brlColumn.getDefinition() ) {
if ( action instanceof DSLSentence ) {
return true;
}
}
}