Example usage for org.springframework.boot.ansi AnsiOutput toString

List of usage examples for org.springframework.boot.ansi AnsiOutput toString

Introduction

In this page you can find the example usage for org.springframework.boot.ansi AnsiOutput toString.

Prototype

public static String toString(Object... elements) 

Source Link

Document

Create a new ANSI string from the specified elements.

Usage

From source file:org.agiso.tempel.starter.Bootstrap.java

public static void main(IParamReader paramReader, String[] args) throws Exception {
    // TODO: Utworzy interfejs IMappingAnsiProcessor
    setAnsiProcessor(new IWrappingAnsiProcessor() {
        //         private static final Map<Object, Object> elementMappings;
        //         static {
        //            elementMappings = new HashMap<Object, Object>();
        //            elementMappings.put(NORMAL, org.springframework.boot.ansi.AnsiElement.NORMAL);
        //            // ...
        //         }

        @Override//from   www.  j  a va2s .co  m
        public String ansiString(Object... elements) {
            return AnsiOutput.toString(elements);
        }
    }).withAnsiNormal(org.springframework.boot.ansi.AnsiElement.NORMAL)
            .withAnsiBold(org.springframework.boot.ansi.AnsiElement.BOLD)
            .withAnsiFaint(org.springframework.boot.ansi.AnsiElement.FAINT)
            .withAnsiItalic(org.springframework.boot.ansi.AnsiElement.ITALIC)
            .withAnsiUnderline(org.springframework.boot.ansi.AnsiElement.UNDERLINE)
            .withAnsiBlack(org.springframework.boot.ansi.AnsiElement.BLACK)
            .withAnsiRed(org.springframework.boot.ansi.AnsiElement.RED)
            .withAnsiGreen(org.springframework.boot.ansi.AnsiElement.GREEN)
            .withAnsiYellow(org.springframework.boot.ansi.AnsiElement.YELLOW)
            .withAnsiBlue(org.springframework.boot.ansi.AnsiElement.BLUE)
            .withAnsiMagenta(org.springframework.boot.ansi.AnsiElement.MAGENTA)
            .withAnsiCyan(org.springframework.boot.ansi.AnsiElement.CYAN)
            .withAnsiWhite(org.springframework.boot.ansi.AnsiElement.WHITE)
            .withAnsiDefault(org.springframework.boot.ansi.AnsiElement.DEFAULT);

    // Obsuga wywoania bezargumentowego:
    if (args.length == 0) {
        printTempelInfo();
        System.exit(0);
    }

    setParamReader(paramReader);

    SpringApplication application = new SpringApplication(Bootstrap.class);
    //      application.addInitializers(new LoggingInitializer());
    application.setShowBanner(false);
    application.run(args);
}