@Component public class ScaffoldingImpl extends com.marklogic.client.ext.helper.LoggingObject implements Scaffolding
Modifier and Type | Class and Description |
---|---|
class |
ScaffoldingImpl.ContentPlugin |
Constructor and Description |
---|
ScaffoldingImpl() |
ScaffoldingImpl(HubConfig hubConfig) |
Modifier and Type | Method and Description |
---|---|
protected java.lang.String |
buildFlowFromDefaultFlow(java.util.Map<java.lang.String,java.lang.String> customTokens) |
void |
createCustomModule(java.lang.String stepName,
java.lang.String stepType)
Creates a custom module given a string stepName
|
void |
createCustomModule(java.lang.String stepName,
java.lang.String stepType,
java.lang.String format)
Creates a custom module given a string stepName
|
java.io.File |
createDefaultFlow(java.lang.String flowName)
Create default flow with all the default steps
|
void |
createEntity(java.lang.String entityName)
Creates an entity given a string name
|
void |
createLegacyFlow(java.lang.String entityName,
java.lang.String flowName,
FlowType flowType,
CodeFormat codeFormat,
DataFormat dataFormat)
Creates a flow for an entity with Entity Services model as default
|
void |
createLegacyFlow(java.lang.String entityName,
java.lang.String flowName,
FlowType flowType,
CodeFormat codeFormat,
DataFormat dataFormat,
boolean useEsModel)
Creates a flow for an entity with an additional option for using Entity Services
|
void |
createLegacyFlow(java.lang.String entityName,
java.lang.String flowName,
FlowType flowType,
CodeFormat codeFormat,
DataFormat dataFormat,
boolean useEsModel,
java.lang.String mappingNameWithVersion)
Creates a flow for an entity with an additional option for using Entity Services
|
void |
createLegacyMappingDir(java.lang.String mappingName)
Creates a legacy mapping given a string name
|
void |
createMappingDir(java.lang.String mappingName)
Creates a mapping given a string name
|
org.apache.commons.lang3.tuple.Pair<java.io.File,java.lang.String> |
createStepFile(java.lang.String stepName,
java.lang.String stepType,
java.lang.String stepDefName,
java.lang.String entityType)
Create a step file based on the given stepName, stepType, entityType (for non ingestion steps),
and stepDefName.
|
static java.lang.String |
getAbsolutePath(java.lang.String first,
java.lang.String... more) |
java.nio.file.Path |
getLegacyFlowDir(java.lang.String entityName,
java.lang.String flowName,
FlowType flowType)
Returns the directory of the flow
|
void |
updateLegacyEntity(java.lang.String entityName)
Update a specific entity that's legacy
|
public ScaffoldingImpl()
public ScaffoldingImpl(HubConfig hubConfig)
public static java.lang.String getAbsolutePath(java.lang.String first, java.lang.String... more)
public org.apache.commons.lang3.tuple.Pair<java.io.File,java.lang.String> createStepFile(java.lang.String stepName, java.lang.String stepType, java.lang.String stepDefName, java.lang.String entityType)
stepName
- stepType
- stepDefName
- entityType
- public java.nio.file.Path getLegacyFlowDir(java.lang.String entityName, java.lang.String flowName, FlowType flowType)
Scaffolding
getLegacyFlowDir
in interface Scaffolding
entityName
- - the entity nameflowName
- - the name of the flowflowType
- - FlowType (sjs or xqy)public void createEntity(java.lang.String entityName)
Scaffolding
createEntity
in interface Scaffolding
entityName
- - the name of the entity as stringpublic void createLegacyMappingDir(java.lang.String mappingName)
Scaffolding
createLegacyMappingDir
in interface Scaffolding
mappingName
- - the name of the mapping as stringpublic void createMappingDir(java.lang.String mappingName)
Scaffolding
createMappingDir
in interface Scaffolding
mappingName
- - the name of the mapping as stringpublic void createCustomModule(java.lang.String stepName, java.lang.String stepType)
Scaffolding
createCustomModule
in interface Scaffolding
stepName
- - the name of the step as stringstepType
- - the type of the step as stringpublic void createCustomModule(java.lang.String stepName, java.lang.String stepType, java.lang.String format)
Scaffolding
createCustomModule
in interface Scaffolding
stepName
- - the name of the step as stringstepType
- - the type of the step as stringformat
- - the format of the custom module (allowed values are xqy, sjs)public java.io.File createDefaultFlow(java.lang.String flowName)
Scaffolding
createDefaultFlow
in interface Scaffolding
flowName
- - the name of the flowprotected java.lang.String buildFlowFromDefaultFlow(java.util.Map<java.lang.String,java.lang.String> customTokens) throws java.io.IOException
java.io.IOException
public void createLegacyFlow(java.lang.String entityName, java.lang.String flowName, FlowType flowType, CodeFormat codeFormat, DataFormat dataFormat)
Scaffolding
createLegacyFlow
in interface Scaffolding
entityName
- - name of the entity to associate the flow withflowName
- - the name of the flow as a stringflowType
- - the type of flow as TypeFlow, eg: harmonize or ingestcodeFormat
- - the format of the code as CodeFormat enumdataFormat
- - the format of the data (json or xml)public void createLegacyFlow(java.lang.String entityName, java.lang.String flowName, FlowType flowType, CodeFormat codeFormat, DataFormat dataFormat, boolean useEsModel)
Scaffolding
createLegacyFlow
in interface Scaffolding
entityName
- - name of the entity to associate the flow withflowName
- - the name of the flow as a stringflowType
- - the type of flow as TypeFlow, eg: harmonize or ingestcodeFormat
- - the format of the code as CodeFormat enumdataFormat
- - the format of the data (json or xml)useEsModel
- - true to use Entity Services, false not topublic void createLegacyFlow(java.lang.String entityName, java.lang.String flowName, FlowType flowType, CodeFormat codeFormat, DataFormat dataFormat, boolean useEsModel, java.lang.String mappingNameWithVersion)
Scaffolding
createLegacyFlow
in interface Scaffolding
entityName
- - name of the entity to associate the flow withflowName
- - the name of the flow as a stringflowType
- - the type of flow as TypeFlow, eg: harmonize or ingestcodeFormat
- - the format of the code as CodeFormat enumdataFormat
- - the format of the data (json or xml)useEsModel
- - true to use Entity Services, false not tomappingNameWithVersion
- - the name of the mapping name and version together (name-version) you wish to use to generate the content pluginpublic void updateLegacyEntity(java.lang.String entityName)
Scaffolding
updateLegacyEntity
in interface Scaffolding
entityName
- - name of the entity