Class JsonToImageTranslator
- java.lang.Object
-
- com.google.cloud.tools.jib.image.json.JsonToImageTranslator
-
public class JsonToImageTranslator extends java.lang.Object
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static Image
toImage(BuildableManifestTemplate manifestTemplate, ContainerConfigurationTemplate containerConfigurationTemplate)
TranslatesBuildableManifestTemplate
toImage
.static Image
toImage(V21ManifestTemplate manifestTemplate)
TranslatesV21ManifestTemplate
toImage
.
-
-
-
Method Detail
-
toImage
public static Image toImage(V21ManifestTemplate manifestTemplate) throws LayerPropertyNotFoundException, BadContainerConfigurationFormatException
TranslatesV21ManifestTemplate
toImage
.- Parameters:
manifestTemplate
- the template containing the image layers.- Returns:
- the translated
Image
. - Throws:
LayerPropertyNotFoundException
- if adding image layers fails.BadContainerConfigurationFormatException
- if the container configuration is in a bad format
-
toImage
public static Image toImage(BuildableManifestTemplate manifestTemplate, ContainerConfigurationTemplate containerConfigurationTemplate) throws LayerCountMismatchException, LayerPropertyNotFoundException, BadContainerConfigurationFormatException
TranslatesBuildableManifestTemplate
toImage
. Uses the correspondingContainerConfigurationTemplate
to get the layer diff IDs.- Parameters:
manifestTemplate
- the template containing the image layers.containerConfigurationTemplate
- the template containing the diff IDs and container configuration properties.- Returns:
- the translated
Image
. - Throws:
LayerCountMismatchException
- if the manifest and configuration contain conflicting layer information.LayerPropertyNotFoundException
- if adding image layers fails.BadContainerConfigurationFormatException
- if the container configuration is in a bad format
-
-