Package step.plans.parser.yaml
Class YamlPlanReader
java.lang.Object
step.plans.parser.yaml.YamlPlanReader
-
Field Summary
-
Constructor Summary
ConstructorDescriptionCreates the new Yaml plan reader with actual version and json schemaYamlPlanReader
(step.core.Version currentVersion, String jsonSchemaPath) Creates the new Yaml plan serializer for the specified current version and json schema -
Method Summary
Modifier and TypeMethodDescriptionvoid
convertFromPlainTextToYaml
(String planName, InputStream planTextInputStream, OutputStream yamlOutputStream) protected YamlRootArtefactDeserializer
protected YamlRootArtefactSerializer
protected com.fasterxml.jackson.databind.ObjectMapper
protected com.fasterxml.jackson.databind.ObjectMapper
protected step.migration.MigrationManager
Initializes the migration manager with specific migrations used for yaml plan formatprotected YamlPlan
planToYamlPlan
(Plan plan) protected String
readJsonSchema
(String jsonSchemaPath) readYamlPlan
(InputStream yamlPlanStream) Read the plan from Yamlvoid
writeYamlPlan
(OutputStream os, Plan plan) Writes the plan as YAMLprotected Plan
yamlPlanToPlan
(YamlPlan yamlPlan)
-
Field Details
-
YAML_PLANS_COLLECTION_NAME
- See Also:
-
-
Constructor Details
-
YamlPlanReader
Creates the new Yaml plan serializer for the specified current version and json schema -
YamlPlanReader
public YamlPlanReader()Creates the new Yaml plan reader with actual version and json schema
-
-
Method Details
-
readYamlPlan
public Plan readYamlPlan(InputStream yamlPlanStream) throws IOException, YamlPlanValidationException Read the plan from Yaml- Parameters:
yamlPlanStream
- yaml data- Throws:
IOException
YamlPlanValidationException
-
writeYamlPlan
Writes the plan as YAML- Throws:
IOException
-
convertFromPlainTextToYaml
public void convertFromPlainTextToYaml(String planName, InputStream planTextInputStream, OutputStream yamlOutputStream) throws IOException, StepsParser.ParsingException -
createYamlPlanObjectMapper
protected com.fasterxml.jackson.databind.ObjectMapper createYamlPlanObjectMapper() -
createRootArtefactSerializer
-
createRootArtefactDeserializer
-
getYamlMapper
protected com.fasterxml.jackson.databind.ObjectMapper getYamlMapper() -
readJsonSchema
-
initMigrationManager
protected step.migration.MigrationManager initMigrationManager()Initializes the migration manager with specific migrations used for yaml plan format -
yamlPlanToPlan
-
planToYamlPlan
-