public class SdkValueProviderReference extends AbstractSdkValueProvider
| Modifier and Type | Field and Description |
|---|---|
static String |
RESOLVER_NAME_FIELD |
definition, ITEM_NAME_EXPRESSION_FIELD, ITEM_VALUE_EXPRESSION_FIELD, ITEMS_EXPRESSION_FIELD, parameter, PATH_TEMPLATE_FIELD, sdkOperationconnectorModel, NAME_MEMBER, outputDir, runConfiguration, VALUE_MEMBER| Constructor and Description |
|---|
SdkValueProviderReference(Path outputDir,
com.mulesoft.connectivity.rest.sdk.internal.connectormodel.ConnectorModel connectorModel,
SdkConnector sdkConnector,
com.mulesoft.connectivity.rest.sdk.internal.connectormodel.parameter.Parameter parameter,
SdkOperation operation,
RestSdkRunConfiguration runConfiguration) |
| Modifier and Type | Method and Description |
|---|---|
void |
applyTemplates() |
protected com.squareup.javapoet.CodeBlock |
generateBuildMethodBody()
Generates the 'build' method of the value provider that overrides the abstract one from
RestValueProvider. |
protected com.squareup.javapoet.TypeName |
getSuperClass()
Returns the super class the generated value provider will extend.
|
protected boolean |
isBoundParameter(com.mulesoft.connectivity.rest.sdk.internal.connectormodel.parameter.ParameterType parameterType,
SdkParameter sdkParameter)
Indicates if a
Parameter from the parent operation of the
value provider is necessary for this value provider to resolve the available values. |
protected boolean |
needsClassConstants() |
buildValueProviderClass, getBindingMethod, getJavaClassName, getPackage, getValueProviderExpressionBuilder, needsConfigureEvaluationContextMethodgenerateGetter, generateOptionalGetter, getConstantStringField, getJavaFileBuilderForClass, getJavaType, getResourcesPath, getSourcesPath, writeClassToFile, writeJavaFilegetTemplateEnginepublic static final String RESOLVER_NAME_FIELD
public SdkValueProviderReference(Path outputDir, com.mulesoft.connectivity.rest.sdk.internal.connectormodel.ConnectorModel connectorModel, SdkConnector sdkConnector, com.mulesoft.connectivity.rest.sdk.internal.connectormodel.parameter.Parameter parameter, SdkOperation operation, RestSdkRunConfiguration runConfiguration)
public void applyTemplates()
throws TemplatingException
applyTemplates in class AbstractSdkValueProviderTemplatingExceptionprotected com.squareup.javapoet.TypeName getSuperClass()
AbstractSdkValueProvidergetSuperClass in class AbstractSdkValueProviderprotected com.squareup.javapoet.CodeBlock generateBuildMethodBody()
AbstractSdkValueProviderRestValueProvider.
This method creates the actual provider expression, being it an inline definition
or a reference to a value provider expression defined in the global context depending on the case.
If the returned CodeBlock is null, no build method will be generated.generateBuildMethodBody in class AbstractSdkValueProviderprotected boolean isBoundParameter(com.mulesoft.connectivity.rest.sdk.internal.connectormodel.parameter.ParameterType parameterType,
SdkParameter sdkParameter)
AbstractSdkValueProviderParameter from the parent operation of the
value provider is necessary for this value provider to resolve the available values.
If this method says is necessary, a @Parameter will be generated in the value provider class.
When that @Parameter is generated in the value provider, it is mandatory for it to have an assigned value in the
DSL for the resolver to be executed.isBoundParameter in class AbstractSdkValueProviderparameterType - The kind of parameter that is being checkedsdkParameter - The parameter that is being checkedprotected boolean needsClassConstants()
needsClassConstants in class AbstractSdkValueProviderCopyright © 2023. All rights reserved.