org.netbeans.modules.java.sourceui/1 1.27.0 1

org.netbeans.api.java.source.ui
Class TypeElementFinder

java.lang.Object
  extended by org.netbeans.api.java.source.ui.TypeElementFinder

public final class TypeElementFinder
extends Object

Support for browsing of the Java types. Opens search dialog for the type name with possibility to filter possible results.

Since:
1.3

Nested Class Summary
static interface TypeElementFinder.Customizer
          Customization of search scope and results
 
Constructor Summary
TypeElementFinder()
           
 
Method Summary
static ElementHandle<TypeElement> find(ClasspathInfo cpInfo, String initialText, TypeElementFinder.Customizer customizer)
          Searches for classes on given classpath using defined restrictions.
static ElementHandle<TypeElement> find(ClasspathInfo cpInfo, TypeElementFinder.Customizer customizer)
          Searches for classes on given classpath using defined restrictions.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TypeElementFinder

public TypeElementFinder()
Method Detail

find

@CheckForNull
public static ElementHandle<TypeElement> find(@NullAllowed
                                                           ClasspathInfo cpInfo,
                                                           @NullAllowed
                                                           TypeElementFinder.Customizer customizer)
Searches for classes on given classpath using defined restrictions.

Parameters:
cpInfo - classpath used for search; optional, can be null, everything available will be searched
customizer - possibility to add restrictions to search result; optional, can be null, no restriction will be applied
Returns:
found type or null if dialog was canceled

find

@CheckForNull
public static ElementHandle<TypeElement> find(@NullAllowed
                                                           ClasspathInfo cpInfo,
                                                           @NullAllowed
                                                           String initialText,
                                                           @NullAllowed
                                                           TypeElementFinder.Customizer customizer)
Searches for classes on given classpath using defined restrictions.

Parameters:
cpInfo - classpath used for search; optional, can be null, everything available will be searched
initialText - text that should be prefilled in the type name text field, or null to prefill text automatically from the context
customizer - possibility to add restrictions to search result; optional, can be null, no restriction will be applied
Returns:
found type or null if dialog was canceled
Since:
1.24

org.netbeans.modules.java.sourceui/1 1.27.0 1

Built on May 22 2012.  |  Portions Copyright 1997-2012 Oracle. All rights reserved.