Package org.eclipse.epsilon.emc.jdt
Class SearchableTypeCollection
- All Implemented Interfaces:
Iterable<Object>
,Collection<Object>
,IAbstractOperationContributor
public class SearchableTypeCollection
extends AbstractCollection<Object>
implements IAbstractOperationContributor
Variant of
TypeDeclaration.all
that integrates case sensitive
pattern matching into its .select(td|pattern='...')
method.-
Field Summary
Modifier and TypeFieldDescriptionprotected org.eclipse.jdt.core.IJavaProject[]
protected ReflectiveASTVisitor
The visitor is only used if the script tries to iterate through the entire TypeDeclaration.all list. -
Constructor Summary
ConstructorDescriptionSearchableTypeCollection
(org.eclipse.jdt.core.IJavaProject[] javaProjects, ReflectiveASTVisitor visitor) -
Method Summary
Modifier and TypeMethodDescriptiongetAbstractOperation
(String name) protected boolean
isSearchByName
(String iteratorName, Expression condition) iterator()
protected Object
performSearch
(IEolContext context, Expression nameExpression, List<Object> results, org.eclipse.jdt.core.search.SearchRequestor requestor) int
size()
Methods inherited from class java.util.AbstractCollection
add, addAll, clear, contains, containsAll, isEmpty, remove, removeAll, retainAll, toArray, toArray, toString
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface java.util.Collection
equals, hashCode, parallelStream, removeIf, spliterator, stream, toArray
-
Field Details
-
javaProjects
protected org.eclipse.jdt.core.IJavaProject[] javaProjects -
visitor
The visitor is only used if the script tries to iterate through the entire TypeDeclaration.all list.
-
-
Constructor Details
-
SearchableTypeCollection
public SearchableTypeCollection(org.eclipse.jdt.core.IJavaProject[] javaProjects, ReflectiveASTVisitor visitor)
-
-
Method Details
-
isSearchByName
-
performSearch
protected Object performSearch(IEolContext context, Expression nameExpression, List<Object> results, org.eclipse.jdt.core.search.SearchRequestor requestor) throws EolRuntimeException - Throws:
EolRuntimeException
-
getAbstractOperation
- Specified by:
getAbstractOperation
in interfaceIAbstractOperationContributor
-
iterator
- Specified by:
iterator
in interfaceCollection<Object>
- Specified by:
iterator
in interfaceIterable<Object>
- Specified by:
iterator
in classAbstractCollection<Object>
-
size
public int size()- Specified by:
size
in interfaceCollection<Object>
- Specified by:
size
in classAbstractCollection<Object>
-