Examples of EOAttribute


Examples of org.objectstyle.wolips.eomodeler.core.model.EOAttribute

    super.disposeBindings();
  }

  public void setInput(IWorkbenchPart part, ISelection selection) {
    if (!ComparisonUtils.equals(selection, getSelection())) {
      EOAttribute attribute = null;
      Object selectedObject = ((IStructuredSelection) selection).getFirstElement();
      super.setInput(part, selection);
      if (selectedObject instanceof EOAttribute) {
        attribute = (EOAttribute) selectedObject;
      } else if (selectedObject instanceof EOAttributePath) {
View Full Code Here

Examples of org.objectstyle.wolips.eomodeler.core.model.EOAttribute

    Object[] selectedAttributes = ((IStructuredSelection) _entityIndexListViewer.getSelection()).toArray();
    if (selectedAttributes.length > 0) {
      boolean confirmed = MessageDialog.openConfirm(getShell(), Messages.getString("EOEntityIndexBasicEditorSection.removeAttributesTitle"), Messages.getString("EOEntityIndexBasicEditorSection.removeAttributesMessage"));
      if (confirmed) {
        for (int attributeNum = 0; attributeNum < selectedAttributes.length; attributeNum++) {
          EOAttribute attribute = (EOAttribute) selectedAttributes[attributeNum];
          _entityIndex.removeAttribute(attribute, true);
        }
        updateAttributes();
      }
    }
View Full Code Here

Examples of org.objectstyle.wolips.eomodeler.core.model.EOAttribute

  public EOAttributesViewerSorter(String tableName) {
    super(tableName);
  }

  public Object getComparisonValue(Object obj, String property) {
    EOAttribute attribute = (EOAttribute) obj;
    Object value = null;
    if (EOAttribute.PROTOTYPE.equals(property)) {
      EOAttribute prototype = attribute.getPrototype();
      if (prototype != null) {
        value = prototype.getName();
      }
    /*
    } else if (AbstractEOArgument.NAME.equals(property)) {
      String sortPrefix;
      Boolean primaryKey = attribute.isPrimaryKey();
View Full Code Here

Examples of org.objectstyle.wolips.eomodeler.core.model.EOAttribute

    List<EOAttribute> attributes = new LinkedList<EOAttribute>();
    Iterator selectionIter = selection.iterator();
    while (selectionIter.hasNext()) {
      Object selectedObject = selectionIter.next();
      if (selectedObject instanceof EOAttribute) {
        EOAttribute selectedAttribute = (EOAttribute) selectedObject;
        if (selectedAttribute.getEntity().equals(parent)) {
          attributes.add(selectedAttribute);
        }
      }
    }
    EOEntityIndex entityIndex;
View Full Code Here

Examples of org.objectstyle.wolips.eomodeler.core.model.EOAttribute

      }
    } else if (_element instanceof EOEntity) {
      EOEntity entity = (EOEntity) _element;
      text = entity.getName();
    } else if (_element instanceof EOAttribute) {
      EOAttribute attribute = (EOAttribute) _element;
      text = attribute.getName();
    } else if (_element instanceof EORelationship) {
      EORelationship relationship = (EORelationship) _element;
      text = relationship.getName();
    } else if (_element instanceof EORelationshipPath) {
      EORelationshipPath relationshipPath = (EORelationshipPath) _element;
View Full Code Here

Examples of org.objectstyle.wolips.eomodeler.core.model.EOAttribute

        text = destination.getName();
      }
    } else if (EOJoin.SOURCE_ATTRIBUTE.equals(property)) {
      EOJoin firstJoin = relationship.getFirstJoin();
      if (firstJoin != null) {
        EOAttribute sourceAttribute = firstJoin.getSourceAttribute();
        if (sourceAttribute != null) {
          text = sourceAttribute.getName();
        }
      }
    } else if (EOJoin.DESTINATION_ATTRIBUTE.equals(property)) {
      EOJoin firstJoin = relationship.getFirstJoin();
      if (firstJoin != null) {
        EOAttribute destinationAttribute = firstJoin.getDestinationAttribute();
        if (destinationAttribute != null) {
          text = destinationAttribute.getName();
        }
      }
    } else {
      text = super.getColumnText(element, property);
    }
View Full Code Here

Examples of org.objectstyle.wolips.eomodeler.core.model.EOAttribute

          } else if (selectedObject instanceof EOEntity) {
            EOEntity selectedEntity = (EOEntity) selectedObject;
            setSelectedEntity(selectedEntity);
            // setActivePage(EOModelEditor.EOENTITY_PAGE);
          } else if (selectedObject instanceof EOAttribute) {
            EOAttribute selectedAttribute = (EOAttribute) selectedObject;
            setSelectedEntity(selectedAttribute.getEntity());
            getEntityEditor().setSelection(_selection);
            setActivePage(getPageNum(EOModelEditor.EOENTITY_PAGE));
          } else if (selectedObject instanceof EORelationship) {
            EORelationship selectedRelationship = (EORelationship) selectedObject;
            setSelectedEntity(selectedRelationship.getEntity());
View Full Code Here

Examples of org.objectstyle.wolips.eomodeler.core.model.EOAttribute

  }

  public String getText(Object _element) {
    String prototypeName = null;
    if (_element instanceof EOAttribute) {
      EOAttribute prototype = (EOAttribute) _element;
      prototypeName = prototype.getName();
    } else {
      prototypeName = Messages.getString("EOAttributesCellModifier.noPrototype");
    }
    return prototypeName;
  }
View Full Code Here

Examples of org.objectstyle.wolips.eomodeler.core.model.EOAttribute

      }
    } else if (_element instanceof EOEntity) {
      EOEntity entity = (EOEntity) _element;
      text = entity.getName();
    } else if (_element instanceof EOAttribute) {
      EOAttribute attribute = (EOAttribute) _element;
      text = attribute.getName();
    } else if (_element instanceof EORelationship) {
      EORelationship relationship = (EORelationship) _element;
      text = relationship.getName();
    } else if (_element instanceof EORelationshipPath) {
      EORelationshipPath relationshipPath = (EORelationshipPath) _element;
View Full Code Here

Examples of org.objectstyle.wolips.eomodeler.core.model.EOAttribute

  public void removePropertyChangeListener(String propertyName, PropertyChangeListener listener) {
    _propertyChangeSupport.removePropertyChangeListener(propertyName, listener);
  }

  public void setSelectedAttribute(EOAttribute selectedAttribute) {
    EOAttribute oldAttribute = _selectedAttribute;
    _selectedAttribute = selectedAttribute;
    _propertyChangeSupport.firePropertyChange("selectedAttribute", oldAttribute, selectedAttribute);
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.