Examples of eContainer()


Examples of org.eclipse.emf.ecore.EObject.eContainer()

        }

        if (getData() instanceof EObject) {
            EObject eobj = (EObject) getData();
            while( eobj != null && !(eobj instanceof ProjectElement) )
                eobj = eobj.eContainer();

            if (eobj instanceof ProjectElement)
                return Collections.singleton((ProjectElement) eobj);

            return null;
View Full Code Here

Examples of org.eclipse.emf.ecore.EObject.eContainer()

            while (parent != null) {
                if (parent instanceof Project) {
                    return (Project) parent;
                }

                parent = parent.eContainer();
            }
        }
        return genResult;
    }
View Full Code Here

Examples of org.eclipse.emf.ecore.EObject.eContainer()

      
        // we want to open the project element if one of it children is dragged
        if (getData() instanceof EObject && !(getDestination() instanceof ILayer)) {
            EObject eobj = (EObject) getData();
            while (eobj!=null && !(eobj instanceof IProjectElement) ){
                eobj=eobj.eContainer();
            }
           
            if (eobj == null)
                return false;
           
View Full Code Here

Examples of org.eclipse.emf.ecore.EObject.eContainer()

    @Override
    public void perform( IProgressMonitor monitor ) {
        if (getData() instanceof EObject && !(getDestination() instanceof ILayer)) {
            EObject eobj = (EObject) getData();
            while (eobj!=null && !(eobj instanceof IProjectElement) ){
                eobj=eobj.eContainer();
            }
            ApplicationGIS.openProjectElement((IProjectElement) eobj,false);
        }
        URL url = null;
        if (getData() instanceof IProjectElement) {
View Full Code Here

Examples of org.eclipse.emf.ecore.EObject.eContainer()

        if (name == null) {
          return EMPTY_NAMES;
        }
        QualifiedName qualifiedName = qualifiedNameConverter.toQualifiedName(name.getSecond());
        allNames.add(qualifiedName);
        while (current.eContainer() != null) {
          current = current.eContainer();
          String containerName = nameResolver.nameOf(current);
          if (isEmpty(containerName)) {
            continue;
          }
View Full Code Here

Examples of org.eclipse.emf.ecore.EObject.eContainer()

          return EMPTY_NAMES;
        }
        QualifiedName qualifiedName = qualifiedNameConverter.toQualifiedName(name.getSecond());
        allNames.add(qualifiedName);
        while (current.eContainer() != null) {
          current = current.eContainer();
          String containerName = nameResolver.nameOf(current);
          if (isEmpty(containerName)) {
            continue;
          }
          qualifiedName = qualifiedNameConverter.toQualifiedName(containerName).append(qualifiedName);
View Full Code Here

Examples of org.eclipse.emf.ecore.EObject.eContainer()

        Pair<NameType, String> name = namingStrategy.nameOf(e);
        if (name == null) {
          return EMPTY_NAME;
        }
        QualifiedName qualifiedName = converter.toQualifiedName(name.getSecond());
        while (current.eContainer() != null) {
          current = current.eContainer();
          QualifiedName parentsQualifiedName = getFullyQualifiedName(current, namingStrategy);
          if (parentsQualifiedName != null) {
            return pair(name.getFirst(), parentsQualifiedName.append(qualifiedName));
          }
View Full Code Here

Examples of org.eclipse.emf.ecore.EObject.eContainer()

        if (name == null) {
          return EMPTY_NAME;
        }
        QualifiedName qualifiedName = converter.toQualifiedName(name.getSecond());
        while (current.eContainer() != null) {
          current = current.eContainer();
          QualifiedName parentsQualifiedName = getFullyQualifiedName(current, namingStrategy);
          if (parentsQualifiedName != null) {
            return pair(name.getFirst(), parentsQualifiedName.append(qualifiedName));
          }
        }
View Full Code Here

Examples of org.eclipse.emf.ecore.EObject.eContainer()

   *         options available.
   */
  public Collection<MessageField> availableOptionsFor(EObject o) {
    EObject target = o;
    if (target instanceof NativeOption) {
      target = target.eContainer();
    }
    OptionType type = findOptionTypeForLevelOf(target);
    if (type == null) {
      return emptyList();
    }
View Full Code Here

Examples of org.eclipse.emf.ecore.EObject.eContainer()

  private <T> Collection<IEObjectDescription> local(EObject start, FinderStrategy<T> strategy, T criteria) {
    UniqueDescriptions descriptions = new UniqueDescriptions();
    EObject current = start.eContainer();
    while (current != null) {
      descriptions.addAll(local(current, strategy, criteria, 0));
      current = current.eContainer();
    }
    return descriptions.values();
  }

  <T> Collection<IEObjectDescription> find(Protobuf start, FinderStrategy<T> strategy, T criteria) {
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.