public abstract class SdkAbstractStaticMetadataResolver extends JavaTemplateEntity
| Modifier and Type | Field and Description |
|---|---|
protected Class<?> |
superclass |
connectorModel, NAME_MEMBER, outputDir, runConfiguration, VALUE_MEMBER| Constructor and Description |
|---|
SdkAbstractStaticMetadataResolver(Path outputDir,
com.mulesoft.connectivity.rest.sdk.internal.connectormodel.ConnectorModel connectorModel,
SdkConnector sdkConnector,
String internalName,
com.mulesoft.connectivity.rest.sdk.internal.connectormodel.type.TypeDefinition typeDefinition,
FileGenerationUtil.SchemaNameType schemaNameType,
String partName,
String classNameOverride,
RestSdkRunConfiguration runConfiguration)
Creates a type resolver that will generate a schema file in the resources directory if needed.
|
| Modifier and Type | Method and Description |
|---|---|
void |
applyTemplates() |
protected boolean |
buildRequiresMetadataResolver() |
protected abstract Class<?> |
buildSuperclass(com.mulesoft.connectivity.rest.sdk.internal.connectormodel.type.TypeDefinition typeDefinition) |
String |
getClassName() |
protected abstract String |
getClassNameSuffix() |
String |
getPackage() |
protected abstract String |
getQName() |
boolean |
getRequiresMetadataResolver() |
String |
getSchemaName() |
protected String |
getSchemaName(String internalName,
FileGenerationUtil.SchemaNameType schemaNameType,
com.mulesoft.connectivity.rest.sdk.internal.connectormodel.type.schema.TypeSchema source,
String partName) |
com.mulesoft.connectivity.rest.sdk.internal.connectormodel.type.TypeDefinition |
getTypeDefinition() |
protected boolean |
requiresCategoryNameMethod() |
protected abstract boolean |
requiresFormatMethod() |
protected abstract boolean |
requiresQNameMethod() |
protected abstract boolean |
requiresToWriteSchema() |
generateGetter, generateOptionalGetter, getArgumentsFromValueProvider, getArgumentsFromValueProviderDefinition, getConstantStringField, getJavaFileBuilderForClass, getJavaType, getResourcesPath, getSourcesPath, getValueProviderAnnotation, writeClassToFile, writeJavaFilegetTemplateEngineprotected Class<?> superclass
public SdkAbstractStaticMetadataResolver(Path outputDir, com.mulesoft.connectivity.rest.sdk.internal.connectormodel.ConnectorModel connectorModel, SdkConnector sdkConnector, String internalName, com.mulesoft.connectivity.rest.sdk.internal.connectormodel.type.TypeDefinition typeDefinition, FileGenerationUtil.SchemaNameType schemaNameType, String partName, String classNameOverride, RestSdkRunConfiguration runConfiguration) throws TemplatingException
sdkConnector - the parent SdkConnector for this typetypeDefinition - The type definition which this metadata will be created forinternalName - The internal name of the operation. It will be used to generate the schema name.schemaNameType - The type of name that this schema will get.partName - When this schema corresponds to a multipart part, this part name will be used to generate the schema name.
Must be an empty string if it he type definition does not correspond to a part.classNameOverride - When specified forces the class name to be generated based on this instead of using the operation
and part names.runConfiguration - The configuration for this execution of the connector generation.TemplatingExceptionprotected String getSchemaName(String internalName, FileGenerationUtil.SchemaNameType schemaNameType, com.mulesoft.connectivity.rest.sdk.internal.connectormodel.type.schema.TypeSchema source, String partName)
protected abstract Class<?> buildSuperclass(com.mulesoft.connectivity.rest.sdk.internal.connectormodel.type.TypeDefinition typeDefinition) throws TemplatingException
TemplatingExceptionprotected abstract String getClassNameSuffix()
public String getClassName()
public String getPackage()
public void applyTemplates()
throws TemplatingException
applyTemplates in class TemplateEntityTemplatingExceptionprotected boolean requiresCategoryNameMethod()
protected abstract boolean requiresQNameMethod()
protected abstract boolean requiresFormatMethod()
protected abstract String getQName()
protected boolean buildRequiresMetadataResolver()
public boolean getRequiresMetadataResolver()
protected abstract boolean requiresToWriteSchema()
public String getSchemaName()
public com.mulesoft.connectivity.rest.sdk.internal.connectormodel.type.TypeDefinition getTypeDefinition()
Copyright © 2021. All rights reserved.