Search in sources :

Example 1 with CommaSeparatedCompositeColumnPart

use of org.whole.lang.ui.editparts.CommaSeparatedCompositeColumnPart in project whole by wholeplatform.

the class QueriesPartFactoryVisitor method visit.

@Override
public void visit(Expressions entity) {
    IEntity parent = entity.wGetParent();
    if (EntityUtils.hasParent(entity)) {
        if (Matcher.match(QueriesEntityDescriptorEnum.EntityTemplate, parent)) {
            part = new CompositeColumnWithPlaceholderPart();
            return;
        } else if (Matcher.match(QueriesEntityDescriptorEnum.UnionAll, parent) || Matcher.isAssignableAsIsFrom(QueriesEntityDescriptorEnum.CollectByExpression, parent)) {
            part = new CommaSeparatedCompositeColumnPart();
            return;
        }
    }
    part = new CommaSeparatedCompositeFlowPart();
}
Also used : IEntity(org.whole.lang.model.IEntity) CommaSeparatedCompositeFlowPart(org.whole.lang.ui.editparts.CommaSeparatedCompositeFlowPart) CommaSeparatedCompositeColumnPart(org.whole.lang.ui.editparts.CommaSeparatedCompositeColumnPart) CompositeColumnWithPlaceholderPart(org.whole.lang.ui.editparts.CompositeColumnWithPlaceholderPart)

Aggregations

IEntity (org.whole.lang.model.IEntity)1 CommaSeparatedCompositeColumnPart (org.whole.lang.ui.editparts.CommaSeparatedCompositeColumnPart)1 CommaSeparatedCompositeFlowPart (org.whole.lang.ui.editparts.CommaSeparatedCompositeFlowPart)1 CompositeColumnWithPlaceholderPart (org.whole.lang.ui.editparts.CompositeColumnWithPlaceholderPart)1