Search in sources :

Example 51 with IEntity

use of org.whole.lang.model.IEntity in project whole by wholeplatform.

the class BindingPart method refreshVisuals.

protected void refreshVisuals() {
    Binding binding = getModelEntity();
    Value valueEntity = binding.getValue();
    IEntity value = Matcher.matchImpl(EnvironmentEntityDescriptorEnum.Value, valueEntity) ? valueEntity.getValue() : valueEntity.wGetAdaptee(true);
    BidingFigure fig = (BidingFigure) getFigure();
    if (fig.getFoldingToggle(0).getModel().isSelected() == isShowValue(value))
        fig.clickFoldingToggle(0);
}
Also used : Binding(org.whole.lang.environment.model.Binding) BidingFigure(org.whole.lang.environment.ui.figures.BidingFigure) IEntity(org.whole.lang.model.IEntity) Value(org.whole.lang.environment.model.Value)

Example 52 with IEntity

use of org.whole.lang.model.IEntity in project whole by wholeplatform.

the class VariablesViewModelPart method getModelSpecificChildren.

@Override
protected List<IEntity> getModelSpecificChildren() {
    VariablesViewModel entity = getModelEntity();
    List<IEntity> list = new ArrayList<IEntity>(1);
    list.add(entity.getEnvironments());
    return list;
}
Also used : VariablesViewModel(org.whole.lang.environment.model.VariablesViewModel) IEntity(org.whole.lang.model.IEntity) ArrayList(java.util.ArrayList)

Example 53 with IEntity

use of org.whole.lang.model.IEntity in project whole by wholeplatform.

the class AbstractPhasedFragmentPart method getModelSpecificChildren.

protected List<IEntity> getModelSpecificChildren() {
    IEntity entity = getModelEntity();
    List<IEntity> children = new ArrayList<IEntity>(2);
    children.add(entity.wGet(CommonsFeatureDescriptorEnum.rootEntity));
    children.add(entity.wGet(CommonsFeatureDescriptorEnum.phase));
    return children;
}
Also used : IEntity(org.whole.lang.model.IEntity) ArrayList(java.util.ArrayList)

Example 54 with IEntity

use of org.whole.lang.model.IEntity in project whole by wholeplatform.

the class AbstractPhasedFragmentPart method refreshVisuals.

protected void refreshVisuals() {
    IEntity entity = getModelEntity();
    getFigure().showPhase(!EntityUtils.isResolver(entity.wGet(CommonsFeatureDescriptorEnum.phase)));
}
Also used : IEntity(org.whole.lang.model.IEntity)

Example 55 with IEntity

use of org.whole.lang.model.IEntity in project whole by wholeplatform.

the class VariablePart method getModelSpecificChildren.

protected List<IEntity> getModelSpecificChildren() {
    Variable entity = getModelEntity();
    List<IEntity> children = new ArrayList<IEntity>(3);
    children.add(entity.getVarType());
    children.add(entity.getVarName());
    children.add(entity.getQuantifier());
    return children;
}
Also used : Variable(org.whole.lang.commons.model.Variable) IEntity(org.whole.lang.model.IEntity) ArrayList(java.util.ArrayList)

Aggregations

IEntity (org.whole.lang.model.IEntity)1407 ArrayList (java.util.ArrayList)604 Test (org.junit.Test)241 IBindingManager (org.whole.lang.bindings.IBindingManager)141 PathExpression (org.whole.lang.queries.model.PathExpression)68 ITemplateManager (org.whole.lang.templates.ITemplateManager)61 Grammar (org.whole.lang.grammars.model.Grammar)50 TestXmlGrammar (org.whole.lang.grammars.util.TestXmlGrammar)46 FeatureDescriptor (org.whole.lang.reflect.FeatureDescriptor)43 Model (org.whole.lang.models.model.Model)40 InternalIEntity (org.whole.lang.model.InternalIEntity)38 VisitException (org.whole.lang.visitors.VisitException)35 IEntityPartViewer (org.whole.lang.ui.viewers.IEntityPartViewer)30 ModelsModel (org.whole.lang.models.codebase.ModelsModel)27 WholeIllegalArgumentException (org.whole.lang.exceptions.WholeIllegalArgumentException)26 StreamPersistenceProvider (org.whole.lang.codebase.StreamPersistenceProvider)24 ModelBuilderOperation (org.whole.lang.builders.ModelBuilderOperation)22 XmlModel (org.whole.lang.models.codebase.XmlModel)22 MissingVariableException (org.whole.lang.visitors.MissingVariableException)22 IEntityPart (org.whole.lang.ui.editparts.IEntityPart)21