ITypeHierarchy.getType
Code IndexAdd Codota to your IDE (free)

Best Java code snippets using org.eclipse.jdt.core.ITypeHierarchy.getType (Showing top 20 results out of 315)

  • Common ways to obtain ITypeHierarchy
private void myMethod () {
ITypeHierarchy i =
  • IType type;type.newSupertypeHierarchy(null)
  • CreateTypeHierarchyOperation op;op.getResult()
  • IType type;SuperTypeHierarchyCache.getTypeHierarchy(type)
  • Smart code suggestions by Codota
}
origin: org.eclipse/org.eclipse.jdt.ui

protected void getRootTypes(List res) {
  ITypeHierarchy hierarchy= getHierarchy();
  if (hierarchy != null) {
    IType input= hierarchy.getType();
    if (input != null) {
      res.add(input);
    }
    // opened on a region: dont show
  }
}

origin: org.eclipse.scout.sdk.deps/org.eclipse.jdt.ui

@Override
public Object[] getElements(Object element) {
  if (element instanceof ITypeHierarchy)
    return getChildren(((ITypeHierarchy) element).getType());
  return new Object[0];
}
origin: org.eclipse/org.eclipse.jdt.ui

public Object[] getElements(Object element) {
  if (element instanceof ITypeHierarchy)
    return getChildren(((ITypeHierarchy) element).getType());
  return new Object[0];
}
origin: org.eclipse.jdt/org.eclipse.jdt.ui

private static Set<IType> computeTypesToShow(final ITypeHierarchy hierarchy, final Map<IType, IMember[]> typeToMemberArray) {
  final Set<IType> typesToShow= new HashSet<>();
  typesToShow.add(hierarchy.getType());
  typesToShow.addAll(computeShowableSubtypesOfMainType(hierarchy, typeToMemberArray));
  return typesToShow;
}
origin: org.eclipse/org.eclipse.jdt.ui

private static Set computeTypesToShow(final ITypeHierarchy hierarchy, final Map typeToMemberArray) {
  final Set typesToShow= new HashSet();
  typesToShow.add(hierarchy.getType());
  typesToShow.addAll(computeShowableSubtypesOfMainType(hierarchy, typeToMemberArray));
  return typesToShow;
}
origin: org.eclipse.scout.sdk.deps/org.eclipse.jdt.ui

@Override
public Object[] getElements(final Object inputElement) {
  Assert.isTrue(inputElement == null || inputElement instanceof ITypeHierarchy);
  return new IType[] { fHierarchy.getType()};
}
origin: org.eclipse.jdt/org.eclipse.jdt.ui

@Override
public Object[] getElements(final Object inputElement) {
  Assert.isTrue(inputElement == null || inputElement instanceof ITypeHierarchy);
  return new IType[] { fHierarchy.getType()};
}
origin: org.eclipse.jdt/org.eclipse.jdt.ui

private static Set<IType> computeShowableSubtypesOfMainType(final ITypeHierarchy hierarchy, final Map<IType, IMember[]> typeToMemberArray) {
  final Set<IType> result= new HashSet<>();
  final IType[] subtypes= hierarchy.getAllSubtypes(hierarchy.getType());
  for (int i= 0; i < subtypes.length; i++) {
    final IType subtype= subtypes[i];
    if (canBeShown(subtype, typeToMemberArray, hierarchy))
      result.add(subtype);
  }
  return result;
}
origin: org.eclipse/org.eclipse.jdt.ui

private static Set computeShowableSubtypesOfMainType(final ITypeHierarchy hierarchy, final Map typeToMemberArray) {
  final Set result= new HashSet();
  final IType[] subtypes= hierarchy.getAllSubtypes(hierarchy.getType());
  for (int i= 0; i < subtypes.length; i++) {
    final IType subtype= subtypes[i];
    if (canBeShown(subtype, typeToMemberArray, hierarchy))
      result.add(subtype);
  }
  return result;
}
origin: org.eclipse.scout.sdk.deps/org.eclipse.jdt.ui

private static Set<IType> computeShowableSubtypesOfMainType(final ITypeHierarchy hierarchy, final Map<IType, IMember[]> typeToMemberArray) {
  final Set<IType> result= new HashSet<>();
  final IType[] subtypes= hierarchy.getAllSubtypes(hierarchy.getType());
  for (int i= 0; i < subtypes.length; i++) {
    final IType subtype= subtypes[i];
    if (canBeShown(subtype, typeToMemberArray, hierarchy))
      result.add(subtype);
  }
  return result;
}
origin: eclipse/eclipse.jdt.ls

private ITypeHierarchy getCachedHierarchy(IType declaring, IProgressMonitor monitor) throws JavaModelException {
  if (fCachedHierarchy != null && declaring.equals(fCachedHierarchy.getType())) {
    return fCachedHierarchy;
  }
  fCachedHierarchy= declaring.newTypeHierarchy(new SubProgressMonitor(monitor, 1));
  return fCachedHierarchy;
}
origin: org.eclipse.jdt/org.eclipse.jdt.ui

private ITypeHierarchy getCachedHierarchy(IType declaring, IProgressMonitor monitor) throws JavaModelException {
  if (fCachedHierarchy != null && declaring.equals(fCachedHierarchy.getType()))
    return fCachedHierarchy;
  fCachedHierarchy= declaring.newTypeHierarchy(new SubProgressMonitor(monitor, 1));
  return fCachedHierarchy;
}
origin: org.eclipse/org.eclipse.jdt.ui

private ITypeHierarchy getCachedHierarchy(IType declaring, IProgressMonitor monitor) throws JavaModelException {
  if (fCachedHierarchy != null && declaring.equals(fCachedHierarchy.getType()))
    return fCachedHierarchy;
  fCachedHierarchy= declaring.newTypeHierarchy(new SubProgressMonitor(monitor, 1));
  return fCachedHierarchy;
}
origin: org.eclipse.jdt/org.eclipse.jdt.ui

public int getExpandLevel() {
  ITypeHierarchy hierarchy= getHierarchy();
  if (hierarchy != null) {
    IType input= hierarchy.getType();
    if (input != null) {
      return getDepth(hierarchy, input) + 2;
    } else {
      return 5;
    }
  }
  return 2;
}
origin: org.eclipse.jdt/org.eclipse.jdt.ui

public ITypeHierarchy getDestinationTypeHierarchy(final IProgressMonitor monitor) throws JavaModelException {
  try {
    if (fCachedDestinationTypeHierarchy != null && fCachedDestinationTypeHierarchy.getType().equals(getDestinationType()))
      return fCachedDestinationTypeHierarchy;
    fCachedDestinationTypeHierarchy= getDestinationType().newTypeHierarchy(fOwner, monitor);
    return fCachedDestinationTypeHierarchy;
  } finally {
    monitor.done();
  }
}
origin: org.eclipse/org.eclipse.jdt.ui

public int getExpandLevel() {
  ITypeHierarchy hierarchy= getHierarchy();
  if (hierarchy != null) {
    IType input= hierarchy.getType();
    if (input != null) {
      return getDepth(hierarchy, input) + 2;
    } else {
      return 5;
    }
  }
  return 2;
}

origin: org.eclipse.scout.sdk.deps/org.eclipse.jdt.ui

public ITypeHierarchy getDestinationTypeHierarchy(final IProgressMonitor monitor) throws JavaModelException {
  try {
    if (fCachedDestinationTypeHierarchy != null && fCachedDestinationTypeHierarchy.getType().equals(getDestinationType()))
      return fCachedDestinationTypeHierarchy;
    fCachedDestinationTypeHierarchy= getDestinationType().newTypeHierarchy(fOwner, monitor);
    return fCachedDestinationTypeHierarchy;
  } finally {
    monitor.done();
  }
}
origin: org.eclipse.scout.sdk.deps/org.eclipse.jdt.ui

private void checkAllParents(final IType parent) {
  final ITypeHierarchy th= getTreeInput();
  final IType root= getTreeInput().getType();
  IType type= parent;
  while (!root.equals(type)) {
    fTreeViewer.setChecked(type, true);
    type= th.getSuperclass(type);
  }
  fTreeViewer.setChecked(root, true);
}
origin: org.eclipse.jdt/org.eclipse.jdt.ui

private void checkAllParents(final IType parent) {
  final ITypeHierarchy th= getTreeInput();
  final IType root= getTreeInput().getType();
  IType type= parent;
  while (!root.equals(type)) {
    fTreeViewer.setChecked(type, true);
    type= th.getSuperclass(type);
  }
  fTreeViewer.setChecked(root, true);
}
origin: org.eclipse/org.eclipse.jdt.ui

private void checkAllParents(final IType parent) {
  final ITypeHierarchy th= getTreeInput();
  final IType root= getTreeInput().getType();
  IType type= parent;
  while (!root.equals(type)) {
    fTreeViewer.setChecked(type, true);
    type= th.getSuperclass(type);
  }
  fTreeViewer.setChecked(root, true);
}
org.eclipse.jdt.coreITypeHierarchygetType

Javadoc

Returns the type this hierarchy was computed for. Returns null if this hierarchy was computed for a region.

Popular methods of ITypeHierarchy

  • getAllSubtypes
    Returns all resolved subtypes (direct and indirect) of the given type, in no particular order, limit
  • contains
    Returns whether the given type is part of this hierarchy.
  • getAllSupertypes
    Returns all resolved supertypes of the given type, in bottom-up order. An empty array is returned if
  • getAllClasses
    Returns all classes in this type hierarchy's graph, in no particular order. Any classes in the creat
  • getAllTypes
    Returns all types in this type hierarchy's graph, in no particular order. Any types in the creation
  • getSuperclass
    Returns the resolved superclass of the given class, or null if the given class has no superclass, th
  • getAllSuperclasses
    Returns all resolved superclasses of the given class, in bottom-up order. An empty array is returned
  • refresh
    Re-computes the type hierarchy reporting progress.
  • getCachedFlags
    Return the flags associated with the given type (would be equivalent to IMember.getFlags()), or -1
  • getSubclasses
    Returns the direct resolved subclasses of the given class, in no particular order, limited to the cl
  • getSubtypes
    Returns the direct resolved subtypes of the given type, in no particular order, limited to the types
  • getSuperInterfaces
    Returns the direct resolved interfaces that the given type implements or extends, in no particular o
  • getSubtypes,
  • getSuperInterfaces,
  • getAllInterfaces,
  • getAllSuperInterfaces,
  • addTypeHierarchyChangedListener,
  • exists,
  • getImplementingClasses,
  • getSupertypes,
  • removeTypeHierarchyChangedListener

Popular in Java

  • Creating JSON documents from java classes using gson
  • putExtra (Intent)
  • setContentView (Activity)
  • getSupportFragmentManager (FragmentActivity)
    Return the FragmentManager for interacting with fragments associated with this activity.
  • FlowLayout (java.awt)
    A flow layout arranges components in a left-to-right flow, much like lines of text in a paragraph. F
  • File (java.io)
    An "abstract" representation of a file system entity identified by a pathname. The pathname may be a
  • URLConnection (java.net)
    A connection to a URL for reading or writing. For HTTP connections, see HttpURLConnection for docume
  • TreeMap (java.util)
    Walk the nodes of the tree left-to-right or right-to-left. Note that in descending iterations, next
  • Stream (java.util.stream)
    A sequence of elements supporting sequential and parallel aggregate operations. The following exampl
  • Project (org.apache.tools.ant)
    Central representation of an Ant project. This class defines an Ant project with all of its targets,

For IntelliJ IDEA,
Android Studio or Eclipse

  • Search for JavaScript code betaCodota IntelliJ IDEA pluginCodota Android Studio pluginCode IndexSign in
  • EnterpriseFAQAboutBlogContact Us
  • Plugin user guideTerms of usePrivacy policyCodeboxFind Usages
Add Codota to your IDE (free)