Package com.nomagic.magicdraw.uml
Class Finder.ByNameAllRecursivelyFinder
- java.lang.Object
-
- com.nomagic.magicdraw.uml.Finder.ByNameAllRecursivelyFinder
-
- Enclosing class:
- Finder
public static final class Finder.ByNameAllRecursivelyFinder extends java.lang.Object
Search for all elements by simple name among the given root element(s) and all(direct and indirect) children of root element(s)
-
-
Constructor Summary
Constructors Modifier Constructor Description private
ByNameAllRecursivelyFinder()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description private static com.nomagic.ci.persistence.local.query.IQuery<org.eclipse.emf.ecore.EObject>
createQuery(java.util.Collection<? extends Element> roots, java.lang.Class[] types, java.lang.String name, boolean includeAdditionalContents)
<T extends Element>
java.util.Collection<T>find(Project project, java.lang.Class[] type, java.lang.String name)
Find element by name.<T extends Element>
java.util.Collection<T>find(Project project, java.lang.Class[] type, java.lang.String name, boolean includeRoot)
Find element by name.<T extends Element>
java.util.Collection<T>find(Project project, java.lang.Class type, java.lang.String name)
Find element by name.<T extends Element>
java.util.Collection<T>find(Project project, java.lang.Class type, java.lang.String name, boolean includeRoot)
Find element by name.<T extends Element>
java.util.Collection<T>find(Element root, java.lang.Class[] type, java.lang.String name)
Find elements by name.<T extends Element>
java.util.Collection<T>find(Element root, java.lang.Class[] type, java.lang.String name, boolean includeRoot)
Find elements by name.<T extends Element>
java.util.Collection<T>find(Element root, java.lang.Class type, java.lang.String name)
Find elements by name.<T extends Element>
java.util.Collection<T>find(Element root, java.lang.Class type, java.lang.String name, boolean includeRoot)
Find elements by name.<T extends Element>
java.util.Collection<T>find(java.util.Collection<? extends Element> roots, java.lang.Class[] type, java.lang.String name)
Find elements by name.<T extends Element>
java.util.Collection<T>find(java.util.Collection<? extends Element> roots, java.lang.Class[] type, java.lang.String name, boolean includeRoot)
Find elements by name.<T extends Element>
java.util.Collection<T>find(java.util.Collection<? extends Element> roots, java.lang.Class type, java.lang.String name)
Find elements by name.<T extends Element>
java.util.Collection<T>find(java.util.Collection<? extends Element> roots, java.lang.Class type, java.lang.String name, boolean includeRoot)
Find elements by name.private static org.eclipse.core.runtime.IProgressMonitor
getMonitor(org.eclipse.core.runtime.IProgressMonitor monitor)
private static <T extends Element>
java.util.Collection<T>internalFind(java.util.Collection<? extends Element> roots, java.lang.Class[] types, java.lang.String name, boolean includeRoots, boolean includeAdditionalContents, org.eclipse.core.runtime.IProgressMonitor monitor)
private static <T extends Element>
CloseableIterator<T>internalIterator(java.util.Collection<? extends Element> roots, java.lang.Class[] types, java.lang.String name, boolean includeRoot)
-
-
-
Method Detail
-
find
public <T extends Element> java.util.Collection<T> find(Element root, @CheckForNull java.lang.Class type, java.lang.String name)
Find elements by name. Include root(s) into a search.- Parameters:
root
- root elementtype
- strict class type of element. Nulls means any elementname
- Element name- Returns:
- found Elements
-
find
public <T extends Element> java.util.Collection<T> find(Element root, @CheckForNull java.lang.Class[] type, java.lang.String name)
Find elements by name. Include root(s) into a search.- Parameters:
root
- root elementtype
- strict class types of element. Nulls means any elementname
- Element name- Returns:
- found Elements
-
find
public <T extends Element> java.util.Collection<T> find(java.util.Collection<? extends Element> roots, @CheckForNull java.lang.Class type, java.lang.String name)
Find elements by name. Include root(s) into a search.- Parameters:
roots
- root elementtype
- strict class type of element. Nulls means any elementname
- Element name- Returns:
- found Elements
-
find
public <T extends Element> java.util.Collection<T> find(java.util.Collection<? extends Element> roots, @CheckForNull java.lang.Class[] type, java.lang.String name)
Find elements by name. Include root(s) into a search.- Parameters:
roots
- root elementtype
- strict class types of element. Nulls means any elementname
- Element name- Returns:
- found Elements
-
find
public <T extends Element> java.util.Collection<T> find(Project project, @CheckForNull java.lang.Class type, java.lang.String name)
Find element by name. Include all project models into a search.- Parameters:
project
- project (Project.getModels() will be used as roots)type
- strict class type of element. Nulls means any elementname
- Element name- Returns:
- found Element or null
-
find
public <T extends Element> java.util.Collection<T> find(Project project, @CheckForNull java.lang.Class[] type, java.lang.String name)
Find element by name. Include all project models into a search.- Parameters:
project
- project (Project.getModels() will be used as roots)type
- strict class types of element. Nulls means any elementname
- Element name- Returns:
- found Element or null
-
find
public <T extends Element> java.util.Collection<T> find(Element root, @CheckForNull java.lang.Class type, java.lang.String name, boolean includeRoot)
Find elements by name.- Parameters:
root
- root elementtype
- strict class type of element. Nulls means any elementname
- Element nameincludeRoot
- include root element(s) into a search- Returns:
- found Elements
-
find
public <T extends Element> java.util.Collection<T> find(Element root, @CheckForNull java.lang.Class[] type, java.lang.String name, boolean includeRoot)
Find elements by name.- Parameters:
root
- root elementtype
- strict class types of element. Nulls means any elementname
- Element nameincludeRoot
- include root element(s) into a search- Returns:
- found Elements
-
find
public <T extends Element> java.util.Collection<T> find(java.util.Collection<? extends Element> roots, @CheckForNull java.lang.Class type, java.lang.String name, boolean includeRoot)
Find elements by name.- Parameters:
roots
- root elementtype
- strict class type of element. Nulls means any elementname
- Element nameincludeRoot
- include root element(s) into a search- Returns:
- found Elements
-
find
public <T extends Element> java.util.Collection<T> find(java.util.Collection<? extends Element> roots, @CheckForNull java.lang.Class[] type, java.lang.String name, boolean includeRoot)
Find elements by name.- Parameters:
roots
- root elementtype
- strict class types of element. Nulls means any elementname
- Element nameincludeRoot
- include root element(s) into a search- Returns:
- found Elements
-
find
public <T extends Element> java.util.Collection<T> find(Project project, @CheckForNull java.lang.Class type, java.lang.String name, boolean includeRoot)
Find element by name.- Parameters:
project
- project (Project.getModels() will be used as roots)type
- strict class type of element. Nulls means any elementname
- Element nameincludeRoot
- include root element(s) into a search- Returns:
- found Element or null
-
find
public <T extends Element> java.util.Collection<T> find(Project project, @CheckForNull java.lang.Class[] type, java.lang.String name, boolean includeRoot)
Find element by name.- Parameters:
project
- project (Project.getModels() will be used as roots)type
- strict class types of element. Nulls means any elementname
- Element nameincludeRoot
- include root element(s) into a search- Returns:
- found Element or null
-
createQuery
private static com.nomagic.ci.persistence.local.query.IQuery<org.eclipse.emf.ecore.EObject> createQuery(java.util.Collection<? extends Element> roots, @CheckForNull java.lang.Class[] types, @CheckForNull java.lang.String name, boolean includeAdditionalContents)
-
internalFind
private static <T extends Element> java.util.Collection<T> internalFind(java.util.Collection<? extends Element> roots, @CheckForNull java.lang.Class[] types, @CheckForNull java.lang.String name, boolean includeRoots, boolean includeAdditionalContents, @CheckForNull org.eclipse.core.runtime.IProgressMonitor monitor)
-
internalIterator
private static <T extends Element> CloseableIterator<T> internalIterator(java.util.Collection<? extends Element> roots, @CheckForNull java.lang.Class[] types, @CheckForNull java.lang.String name, boolean includeRoot)
-
getMonitor
private static org.eclipse.core.runtime.IProgressMonitor getMonitor(@CheckForNull org.eclipse.core.runtime.IProgressMonitor monitor)
-
-