text = firstJoin.getDestinationAttribute().getName();
EOAttribute destinationAttribute = firstJoin.getDestinationAttribute(); if (destinationAttribute != null) { text = destinationAttribute.getName(); }
  public String getColumnText(Object _element, String _property) {    EORelationship relationship = (EORelationship) _element;    String text = null;    if (_property == EORelationshipsConstants.TO_MANY) {      text = null;    }    else if (_property == EORelationshipsConstants.CLASS_PROPERTY) {      text = null;    }    else if (_property == EORelationshipsConstants.NAME) {      text = relationship.getName();    }    else if (_property == EORelationshipsConstants.DESTINATION) {      EOEntity destination = relationship.getDestination();      if (destination != null) {        text = destination.getName();      }    }    else if (_property == EORelationshipsConstants.SOURCE_ATTRIBUTE) {      EOJoin firstJoin = relationship.getFirstJoin();      if (firstJoin != null) {        text = firstJoin.getSourceAttribute().getName();      }    }    else if (_property == EORelationshipsConstants.DESTINATION_ATTRIBUTE) {      EOJoin firstJoin = relationship.getFirstJoin();      if (firstJoin != null) {        text = firstJoin.getDestinationAttribute().getName();      }    }    else {      throw new IllegalArgumentException("Unknown property '" + _property + "'");    }    return text;  }