Package com.github.dockerjava.api.command

Examples of com.github.dockerjava.api.command.ListContainersCmd


     */
    private ListContainersCmd executeListContainersRequest(DockerClient client, Message message) throws DockerException {
 
        LOGGER.debug("Executing Docker List Container Request");
       
        ListContainersCmd listContainersCmd = client.listContainersCmd();
        Boolean showSize = DockerHelper.getProperty(DockerConstants.DOCKER_SHOW_SIZE, configuration, message, Boolean.class);
        if (showSize != null && showSize) {
            listContainersCmd.withShowSize(showSize);
        }
       
        Boolean showAll = DockerHelper.getProperty(DockerConstants.DOCKER_SHOW_ALL, configuration, message, Boolean.class);
        if (showAll != null && showAll) {
            listContainersCmd.withShowAll(showAll);
        }
      
        String before = DockerHelper.getProperty(DockerConstants.DOCKER_BEFORE, configuration, message, String.class);
        if (before != null) {
            listContainersCmd.withBefore(before);
        }
       
        Integer limit = DockerHelper.getProperty(DockerConstants.DOCKER_LIMIT, configuration, message, Integer.class);
        if (limit != null) {
            listContainersCmd.withLimit(limit);
        }
       
        String since = DockerHelper.getProperty(DockerConstants.DOCKER_SINCE, configuration, message, String.class);
        if (since != null) {
            listContainersCmd.withSince(since);
        }

        return listContainersCmd;

    }
View Full Code Here

TOP

Related Classes of com.github.dockerjava.api.command.ListContainersCmd

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.