Class ByEClassRecursively

java.lang.Object
com.dassault_systemes.modeler.kerml.find.AbstractFinder
com.dassault_systemes.modeler.kerml.find.ByEClassRecursively

@OpenApiAll public class ByEClassRecursively extends com.dassault_systemes.modeler.kerml.find.AbstractFinder
Finder implementation that locates elements by their EClass.

This finder searches through the contents of a Project/IProject or given context Elements, visiting all nested elements and returning those that match the specified EClass or filtering criteria.

  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    <T extends Element>
    Stream<T>
    exactFind(ModelElementProject project, Set<org.eclipse.emf.ecore.EClass> eClasses)
    Finds elements whose EClass exactly matches one of the given EClasses in project and all modules Subclasses are not included.
    <T extends Element>
    Stream<T>
    exactFind(Element context, Set<org.eclipse.emf.ecore.EClass> eClasses)
    Finds elements whose EClass exactly matches one of the given EClasses in Element context
    <T extends Element>
    Stream<T>
    exactFind(Collection<? extends Element> contexts, Set<org.eclipse.emf.ecore.EClass> eClasses)
    Finds elements whose EClass exactly matches one of the given EClasses in Element contexts
    <T extends Element>
    Stream<T>
    exactFindInIProject(com.nomagic.ci.persistence.IProject contextIProject, Set<org.eclipse.emf.ecore.EClass> eClasses)
    Finds elements whose EClass exactly matches one of the given EClasses in the provided IProject Subclasses are not included.
    <T extends Element>
    Stream<T>
    exactFindInIProjects(Collection<? extends com.nomagic.ci.persistence.IProject> contextIProjects, Set<org.eclipse.emf.ecore.EClass> eClasses)
    Finds elements whose EClass exactly matches one of the given EClasses in the provided IProjects Subclasses are not included.
    <T extends Element>
    Stream<T>
    find(ModelElementProject project, org.eclipse.emf.ecore.EClass eClass)
    Finds elements matching the given EClass within the project.
    <T extends Element>
    Stream<T>
    find(Element context, org.eclipse.emf.ecore.EClass elementEClass)
    Finds elements matching the given EClass starting from the provided context.
    <T extends Element>
    Stream<T>
    find(Collection<? extends Element> contexts, org.eclipse.emf.ecore.EClass elementEClass)
    Finds elements matching the given EClass starting from the provided contexts.
    <T extends Element>
    Stream<T>
    findInIProject(com.nomagic.ci.persistence.IProject contextIProject, org.eclipse.emf.ecore.EClass eClass)
    Finds elements whose EClass matches one of the given EClasses in the provided IProject
    <T extends Element>
    Stream<T>
    findInIProjects(Collection<? extends com.nomagic.ci.persistence.IProject> contextIProjects, org.eclipse.emf.ecore.EClass eClass)
    Finds elements whose EClass matches one of the given EClasses in the provided IProjects

    Methods inherited from class com.dassault_systemes.modeler.kerml.find.AbstractFinder

    find, streamOf

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • ByEClassRecursively

      public ByEClassRecursively()
  • Method Details

    • exactFind

      public <T extends Element> Stream<T> exactFind(ModelElementProject project, Set<org.eclipse.emf.ecore.EClass> eClasses)
      Finds elements whose EClass exactly matches one of the given EClasses in project and all modules Subclasses are not included.
      Type Parameters:
      T - element type
      Parameters:
      project - the project to search in
      eClasses - set of exact EClasses to match
      Returns:
      stream of matching elements
    • exactFind

      public <T extends Element> Stream<T> exactFind(Element context, Set<org.eclipse.emf.ecore.EClass> eClasses)
      Finds elements whose EClass exactly matches one of the given EClasses in Element context
      Type Parameters:
      T - element type
      Parameters:
      context - the context to search in
      eClasses - set of exact EClasses to match
      Returns:
      stream of matching elements
    • exactFind

      public <T extends Element> Stream<T> exactFind(Collection<? extends Element> contexts, Set<org.eclipse.emf.ecore.EClass> eClasses)
      Finds elements whose EClass exactly matches one of the given EClasses in Element contexts
      Type Parameters:
      T - element type
      Parameters:
      contexts - the contexts to search in
      eClasses - set of exact EClasses to match
      Returns:
      stream of matching elements
    • exactFindInIProject

      public <T extends Element> Stream<T> exactFindInIProject(com.nomagic.ci.persistence.IProject contextIProject, Set<org.eclipse.emf.ecore.EClass> eClasses)
      Finds elements whose EClass exactly matches one of the given EClasses in the provided IProject Subclasses are not included.
      Type Parameters:
      T - element type
      Parameters:
      contextIProject - the context IProject to search in
      eClasses - set of exact EClasses to match
      Returns:
      stream of matching elements
    • exactFindInIProjects

      public <T extends Element> Stream<T> exactFindInIProjects(Collection<? extends com.nomagic.ci.persistence.IProject> contextIProjects, Set<org.eclipse.emf.ecore.EClass> eClasses)
      Finds elements whose EClass exactly matches one of the given EClasses in the provided IProjects Subclasses are not included.
      Type Parameters:
      T - element type
      Parameters:
      contextIProjects - the context IProjects to search in
      eClasses - set of exact EClasses to match
      Returns:
      stream of matching elements
    • find

      public <T extends Element> Stream<T> find(ModelElementProject project, org.eclipse.emf.ecore.EClass eClass)
      Finds elements matching the given EClass within the project.
      Type Parameters:
      T - element type
      Parameters:
      project - the project to search in
      eClass - the EClass to match
      Returns:
      stream of matching elements
    • find

      public <T extends Element> Stream<T> find(Element context, org.eclipse.emf.ecore.EClass elementEClass)
      Finds elements matching the given EClass starting from the provided context.
      Type Parameters:
      T - element type
      Parameters:
      context - context object to start search in
      elementEClass - the EClass to match
      Returns:
      stream of matching elements
    • find

      public <T extends Element> Stream<T> find(Collection<? extends Element> contexts, org.eclipse.emf.ecore.EClass elementEClass)
      Finds elements matching the given EClass starting from the provided contexts.
      Type Parameters:
      T - element type
      Parameters:
      contexts - contexts object to start search in
      elementEClass - the EClass to match
      Returns:
      stream of matching elements
    • findInIProject

      public <T extends Element> Stream<T> findInIProject(com.nomagic.ci.persistence.IProject contextIProject, org.eclipse.emf.ecore.EClass eClass)
      Finds elements whose EClass matches one of the given EClasses in the provided IProject
      Type Parameters:
      T - element type
      Parameters:
      contextIProject - the context IProject to search in
      eClass - the EClass to match
      Returns:
      stream of matching elements
    • findInIProjects

      public <T extends Element> Stream<T> findInIProjects(Collection<? extends com.nomagic.ci.persistence.IProject> contextIProjects, org.eclipse.emf.ecore.EClass eClass)
      Finds elements whose EClass matches one of the given EClasses in the provided IProjects
      Type Parameters:
      T - element type
      Parameters:
      contextIProjects - the context IProjects to search in
      eClass - the EClass to match
      Returns:
      stream of matching elements