java.lang.Object
org.mule.runtime.ast.api.util.BaseArtifactAst
- All Implemented Interfaces:
ArtifactAst
Base implementation of
ArtifactAst.
Extending classes need only implement ArtifactAst.topLevelComponents(), and the values returned by the other methods are derived
from it.
- Since:
- 1.0
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfilteredComponents(Predicate<ComponentAst> predicate) Given aPredicate, navigates the whole AST looking for allComponentAsts satisfied by the providedPredicateorg.mule.runtime.api.exception.ErrorTypeRepositoryrecursiveSpliterator(AstTraversalDirection direction) recursiveStream(AstTraversalDirection direction) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.mule.runtime.ast.api.ArtifactAst
dependencies, dependenciesDsl, getArtifactName, getArtifactType, getImportedResources, getParent, namespaceDefinition, topLevelComponents, updatePropertiesResolver
-
Constructor Details
-
BaseArtifactAst
public BaseArtifactAst()
-
-
Method Details
-
topLevelComponentsStream
- Specified by:
topLevelComponentsStreamin interfaceArtifactAst- Returns:
- a
Streamfor the top-level components (i.e.: configs, flows) of the artifact represented by this AST.
-
topLevelComponentsSpliterator
- Specified by:
topLevelComponentsSpliteratorin interfaceArtifactAst- Returns:
- a
Spliteratorfor the top-level components (i.e.: configs, flows) of the artifact represented by this AST.
-
recursiveSpliterator
- Specified by:
recursiveSpliteratorin interfaceArtifactAst- Parameters:
direction- the @{link AstTraversalDirection} used to navigate the whole AST.- Returns:
- a
Spliteratorfor this component and its children recursively that navigates the whole AST using the given @{code direction}.
-
recursiveSpliterator
- Specified by:
recursiveSpliteratorin interfaceArtifactAst- Returns:
- a
Spliteratorfor this component and its children recursively that navigates the whole AST usingTOP_DOWNdirection.
-
recursiveStream
- Specified by:
recursiveStreamin interfaceArtifactAst- Parameters:
direction- the @{link AstTraversalDirection} used to navigate the whole AST.- Returns:
- a
Streamfor this component and its children recursively that navigates the whole AST using the given @{code direction}.
-
recursiveStream
- Specified by:
recursiveStreamin interfaceArtifactAst- Returns:
- a
Streamfor this component and its children recursively that navigates the whole AST usingTOP_DOWNdirection.
-
filteredComponents
Description copied from interface:ArtifactAstGiven aPredicate, navigates the whole AST looking for allComponentAsts satisfied by the providedPredicateCheck
ComponentAstPredicatesFactory, there are severalPredicatealready defined.- Specified by:
filteredComponentsin interfaceArtifactAst- Parameters:
predicate- thePredicateto test.- Returns:
- a
StreamfilteringComponentAstthat satisfied thepredicate.
-
getErrorTypeRepository
public org.mule.runtime.api.exception.ErrorTypeRepository getErrorTypeRepository()- Specified by:
getErrorTypeRepositoryin interfaceArtifactAst- Returns:
- the error types
-