Package jetbrains.mps.smodel
Class BaseFastNodeFinder
- java.lang.Object
 - 
- jetbrains.mps.smodel.BaseFastNodeFinder
 
 
- 
- All Implemented Interfaces:
 FastNodeFinder
- Direct Known Subclasses:
 DefaultFastNodeFinder,TransientModelNodeFinder
public class BaseFastNodeFinder extends Object implements FastNodeFinder
Base implementation for FastNodeFinder, thread-aware and map update ready. Doesn't track model changes. Model implementation agnostic, doesn't rely on internal SModel implementation 
- 
- 
Nested Class Summary
Nested Classes Modifier and Type Class Description protected classBaseFastNodeFinder.ChangeTrackerHandy, ready-to use listener implementation to use.protected static classBaseFastNodeFinder.ConceptInstanceMapSimple wrap of Map('concept name' to concept instances).- 
Nested classes/interfaces inherited from interface jetbrains.mps.smodel.FastNodeFinder
FastNodeFinder.Factory 
 - 
 
- 
Constructor Summary
Constructors Constructor Description BaseFastNodeFinder(SModel model) 
- 
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidadded(SNode n)Subclasses shall invoke once model had changedprotected BaseFastNodeFinder.ConceptInstanceMapbuild(Computable<BaseFastNodeFinder.ConceptInstanceMap> b)Walk associated model and build concept instance map.voiddispose()List<SNode>getNodes(SAbstractConcept concept, boolean includeInherited)protected voidremoved(SNode n)Subclasses shall invoke once model had changedprotected voidreset()Subclasses shall invoke once model had changed 
 - 
 
- 
- 
Field Detail
- 
myModel
protected final SModel myModel
 
 - 
 
- 
Constructor Detail
- 
BaseFastNodeFinder
public BaseFastNodeFinder(SModel model)
 
 - 
 
- 
Method Detail
- 
build
protected BaseFastNodeFinder.ConceptInstanceMap build(Computable<BaseFastNodeFinder.ConceptInstanceMap> b)
Walk associated model and build concept instance map. Subclasses may override e.g. if they need to control read events during the walk. 
- 
added
protected void added(SNode n)
Subclasses shall invoke once model had changed 
- 
removed
protected void removed(SNode n)
Subclasses shall invoke once model had changed 
- 
reset
protected void reset()
Subclasses shall invoke once model had changed 
- 
dispose
public void dispose()
- Specified by:
 disposein interfaceFastNodeFinder
 
- 
getNodes
@NotNull public List<SNode> getNodes(@NotNull SAbstractConcept concept, boolean includeInherited)
- Specified by:
 getNodesin interfaceFastNodeFinder- Returns:
 - list of instances, or empty list, if none found
 
 
 - 
 
 -