public class MuleSdkOptionalParameterModelParser extends MuleSdkParameterModelParser implements ParameterModelParser
ParameterModelParser implementation for Mule SDK (optional parameters).| Modifier and Type | Field and Description |
|---|---|
protected static String |
DEPRECATED_CONSTRUCT_NAME |
parameterAst| Constructor and Description |
|---|
MuleSdkOptionalParameterModelParser(org.mule.runtime.ast.api.ComponentAst parameter,
org.mule.metadata.api.TypeLoader typeLoader,
org.mule.runtime.ast.internal.model.ExtensionModelHelper extensionModelHelper) |
| Modifier and Type | Method and Description |
|---|---|
protected org.mule.runtime.api.meta.model.deprecated.DeprecationModel |
buildDeprecationModel(org.mule.runtime.ast.api.ComponentAst deprecationAst)
Builds a deprecation model by parsing the content of the
deprecated parameter AST. |
protected Stream<org.mule.runtime.ast.api.ComponentAst> |
getChildren(org.mule.runtime.ast.api.ComponentAst component,
String childName) |
Object |
getDefaultValue() |
protected <T> Optional<T> |
getOptionalParameter(org.mule.runtime.ast.api.ComponentAst ast,
String paramName)
Returns the value of an optional parameter in the give
ast. |
protected <T> T |
getParameter(org.mule.runtime.ast.api.ComponentAst ast,
String paramName)
Returns the value of a parameter in the given
ast. |
protected org.mule.runtime.ast.api.ComponentAst |
getRequiredTopLevelComponent(org.mule.runtime.ast.api.ArtifactAst ast,
org.mule.runtime.api.component.ComponentIdentifier childIdentifier) |
protected Optional<org.mule.runtime.ast.api.ComponentAst> |
getSingleChild(org.mule.runtime.ast.api.ComponentAst component,
String childName) |
boolean |
isRequired() |
getAdditionalModelProperties, getAllowedStereotypes, getDeprecationModel, getDescription, getDisplayModel, getDslConfiguration, getExpressionSupport, getLayoutModel, getName, getOAuthParameterModelProperty, getRole, getSemanticTerms, getType, isComponentId, isConfigOverride, isExcludedFromConnectivitySchemaclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetAdditionalModelProperties, getDeprecationModel, getDescription, getDisplayModel, getDslConfiguration, getExpressionSupport, getLayoutModel, getName, getOAuthParameterModelProperty, getRole, getType, isComponentId, isConfigOverride, isExcludedFromConnectivitySchemagetSemanticTermsgetAllowedStereotypesprotected static final String DEPRECATED_CONSTRUCT_NAME
public MuleSdkOptionalParameterModelParser(org.mule.runtime.ast.api.ComponentAst parameter,
org.mule.metadata.api.TypeLoader typeLoader,
org.mule.runtime.ast.internal.model.ExtensionModelHelper extensionModelHelper)
public boolean isRequired()
isRequired in interface ParameterModelParserisRequired in class MuleSdkParameterModelParserpublic Object getDefaultValue()
getDefaultValue in interface ParameterModelParsergetDefaultValue in class MuleSdkParameterModelParserprotected <T> T getParameter(org.mule.runtime.ast.api.ComponentAst ast,
String paramName)
ast. The parameter is assumed to either be required or have a default
defined.T - the param's generic typeast - a ComponentAstparamName - the name of the parameterprotected <T> Optional<T> getOptionalParameter(org.mule.runtime.ast.api.ComponentAst ast, String paramName)
ast.T - the param's generic typeast - a ComponentAstparamName - the name of the parameterOptional for the parameter's valueprotected Stream<org.mule.runtime.ast.api.ComponentAst> getChildren(org.mule.runtime.ast.api.ComponentAst component, String childName)
component - a ComponentAstchildName - the child element nameStream with all the direct children with the given childNameprotected Optional<org.mule.runtime.ast.api.ComponentAst> getSingleChild(org.mule.runtime.ast.api.ComponentAst component, String childName)
component - a ComponentAstchildName - the child element namechildNameprotected org.mule.runtime.ast.api.ComponentAst getRequiredTopLevelComponent(org.mule.runtime.ast.api.ArtifactAst ast,
org.mule.runtime.api.component.ComponentIdentifier childIdentifier)
ast - a ComponentAstchildIdentifier - the child ComponentIdentifierchildIdentifierorg.mule.runtime.api.exception.MuleRuntimeException - if not found.protected org.mule.runtime.api.meta.model.deprecated.DeprecationModel buildDeprecationModel(org.mule.runtime.ast.api.ComponentAst deprecationAst)
deprecated parameter AST.deprecationAst - The deprecation parameter AST.DeprecationModel.Copyright © 2003–2023 MuleSoft, Inc.. All rights reserved.