Package org.eclipse.wb.core.model.association

Examples of org.eclipse.wb.core.model.association.AssociationObject


      @Override
      void create(ColumnConfigInfo column, ColumnConfigInfo nextColumn) throws Exception {
        SimpleName columnsList = ensureColumnsList();
        ColumnConfigAssociation association = new ColumnConfigAssociation(columnsList);
        AssociationObject associationObject = new AssociationObject(association, true);
        if (nextColumn == null) {
          Statement columnsListUsageStatement = AstNodeUtils.getEnclosingStatement(columnsList);
          StatementTarget target = new StatementTarget(columnsListUsageStatement, true);
          JavaInfoUtils.addTarget(column, associationObject, GridInfo.this, target);
        } else {
          JavaInfoUtils.add(column, associationObject, GridInfo.this, nextColumn);
        }
      }

      @Override
      void move(ColumnConfigInfo column, ColumnConfigInfo nextColumn) throws Exception {
        SimpleName columnsList = ensureColumnsList();
        ColumnConfigAssociation association = new ColumnConfigAssociation(columnsList);
        AssociationObject associationObject = new AssociationObject(association, true);
        if (nextColumn == null) {
          Statement columnsListUsageStatement = AstNodeUtils.getEnclosingStatement(columnsList);
          StatementTarget target = new StatementTarget(columnsListUsageStatement, true);
          JavaInfoUtils.moveTarget(column, associationObject, GridInfo.this, null, target);
        } else {
View Full Code Here


  public boolean hasTopComponent() {
    return ReflectionUtils.invokeMethodEx(getObject(), "getTopComponent()") != null;
  }

  public void setTopComponent(ComponentInfo component) throws Exception {
    AssociationObject associationObject =
        AssociationObjects.invocationChild("%parent%.setTopComponent(%child%)", true);
    if (component.getParent() == null) {
      JavaInfoUtils.add(component, associationObject, this, null);
    } else {
      JavaInfoUtils.move(component, associationObject, this, null);
View Full Code Here

  public boolean hasBottomComponent() {
    return ReflectionUtils.invokeMethodEx(getObject(), "getBottomComponent()") != null;
  }

  public void setBottomComponent(ComponentInfo component) throws Exception {
    AssociationObject associationObject =
        AssociationObjects.invocationChild("%parent%.setBottomComponent(%child%)", true);
    if (component.getParent() == null) {
      JavaInfoUtils.add(component, associationObject, this, null);
    } else {
      JavaInfoUtils.move(component, associationObject, this, null);
View Full Code Here

  /**
   * Adds new {@link WidgetInfo} using <code>Container.add(Widget,LayoutData)</code>.
   */
  public void command_CREATE(WidgetInfo component, WidgetInfo nextComponent) throws Exception {
    ContainerInfo container = getContainer();
    AssociationObject association = getAssociation_();
    JavaInfoUtils.add(component, association, container, nextComponent);
  }
View Full Code Here

   * Moves {@link WidgetInfo} in/to this container using
   * <code>Container.add(Widget,LayoutData)</code>.
   */
  public void command_MOVE(WidgetInfo component, WidgetInfo nextComponent) throws Exception {
    ContainerInfo container = getContainer();
    AssociationObject association = getAssociation_();
    JavaInfoUtils.move(component, association, container, nextComponent);
  }
View Full Code Here

    TreeNodeInfo rootNode =
        (TreeNodeInfo) JavaInfoUtils.createJavaInfo(
            getEditor(),
            "com.gwtext.client.widgets.tree.TreeNode",
            new ConstructorCreationSupport());
    AssociationObject association =
        AssociationObjects.invocationChild("%parent%.setRootNode(%child%)", true);
    JavaInfoUtils.add(rootNode, association, m_this, null);
    rootNode.getPropertyByTitle("text").setValue("(Root)");
  }
View Full Code Here

  //
  // Commands
  //
  ////////////////////////////////////////////////////////////////////////////
  public void command_CREATE(WidgetInfo item, WidgetInfo nextItem) throws Exception {
    AssociationObject associationObject =
        AssociationObjects.invocationChild("%parent%.setField(%child%)", true);
    StatementTarget target = getTargetForNewItem(item, nextItem);
    JavaInfoUtils.addTarget(item, associationObject, this, target);
  }
View Full Code Here

    WidgetInfo field =
        (WidgetInfo) JavaInfoUtils.createJavaInfo(
            getEditor(),
            "com.gwtext.client.widgets.form.TextField",
            new ConstructorCreationSupport());
    AssociationObject association =
        AssociationObjects.invocationChild("%parent%.add(%child%)", true);
    JavaInfoUtils.add(field, association, m_this, null);
  }
View Full Code Here

  /**
   * Adds new {@link WidgetInfo} using <code>LayoutContainer.add(Widget,LayoutData)</code>.
   */
  public void command_CREATE(WidgetInfo widget, WidgetInfo nextWidget) throws Exception {
    LayoutContainerInfo container = getContainer();
    AssociationObject association = getAssociation_();
    JavaInfoUtils.add(widget, association, container, nextWidget);
  }
View Full Code Here

   * Moves {@link WidgetInfo} in/to this container using
   * <code>LayoutContainer.add(Widget,LayoutData)</code>.
   */
  public void command_MOVE(WidgetInfo widget, WidgetInfo nextWidget) throws Exception {
    LayoutContainerInfo container = getContainer();
    AssociationObject association = getAssociation_();
    JavaInfoUtils.move(widget, association, container, nextWidget);
  }
View Full Code Here

TOP

Related Classes of org.eclipse.wb.core.model.association.AssociationObject

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.