Class Inspect

  • All Implemented Interfaces:
    com.oracle.bedrock.runtime.MetaClass<com.oracle.bedrock.runtime.Application>

    public class Inspect
    extends CommandWithArgumentList<Inspect>
    A representation of the Docker inspect command.

    Instances of Inspect are immutable, methods that add options and configuration to this Inspect command return a new instance of a Inspect command with the modifications applied.

    Copyright (c) 2016. All Rights Reserved. Oracle Corporation.
    Oracle is a registered trademark of Oracle Corporation and/or its affiliates.

    Author:
    Jonathan Knight
    • Method Detail

      • format

        public Inspect format​(String format)
        Format the output using the given go template.
        Parameters:
        format - the template to use to format the output.
        Returns:
        a copy of this Inspect command with the specified format
      • includeSizes

        public Inspect includeSizes​(boolean include)
        Display total file sizes if the type is container.
        Parameters:
        include - true to include sizes
        Returns:
        a copy of this Inspect command with the specified size argument
      • image

        public static Inspect image​(List<?> names)
        Create an Inspect command to inspect the image with the specified name.
        Parameters:
        names - the name of the image to inspect
        Returns:
        an Inspect command to inspect the image with the specified name
      • image

        public static Inspect image​(Object... names)
        Create an Inspect command to inspect the images with the specified names.
        Parameters:
        names - the names of the image to inspect
        Returns:
        an Inspect command to inspect the images with the specified name
      • container

        public static Inspect container​(List<?> names)
        Create an Inspect command to inspect the container with the specified name.
        Parameters:
        names - the name of the container to inspect
        Returns:
        an Inspect command to inspect the container with the specified name
      • container

        public static Inspect container​(Object... names)
        Create an Inspect command to inspect the images with the specified names.
        Parameters:
        names - the names of the image to inspect
        Returns:
        an Inspect command to inspect the images with the specified name
      • run

        public javax.json.JsonValue run​(com.oracle.bedrock.runtime.Platform platform,
                                        Docker environment)
        Execute this Inspect command on the specified Platform using the specified Docker environment.
        Parameters:
        platform - the Platform to use to execute the command
        environment - the Docker environment to use
        Returns:
        a JsonArray containing the results of the inspect command