Example usage for org.springframework.boot.builder SpringApplicationBuilder addCommandLineProperties

List of usage examples for org.springframework.boot.builder SpringApplicationBuilder addCommandLineProperties

Introduction

In this page you can find the example usage for org.springframework.boot.builder SpringApplicationBuilder addCommandLineProperties.

Prototype

public SpringApplicationBuilder addCommandLineProperties(boolean addCommandLineProperties) 

Source Link

Document

Flag to indicate that command line arguments should be added to the environment.

Usage

From source file:com.micro.security.SecurityTokenApp.java

/**
 * Main method.//from w  w  w.  j av a  2 s . c om
 *
 * @param args
 * @throws Exception
 */
public static void main(final String[] args) throws Exception {
    SpringApplicationBuilder application = new SpringApplicationBuilder();
    application //
            .addCommandLineProperties(true) //
            .sources(SecurityTokenApp.class) //
            .showBanner(true).main(SecurityTokenApp.class) //
            .registerShutdownHook(true).run(args);
}

From source file:org.sai.tools.fe.FeRestApp.java

/**
 * Main method./* ww  w  .j  a  v  a  2  s.com*/
 *
 * @param args
 * @throws Exception
 */
public static void main(final String[] args) throws Exception {

    SpringApplicationBuilder application = new SpringApplicationBuilder();
    application //
            .addCommandLineProperties(true) //
            .sources(FeRestApp.class) //
            .showBanner(true).main(FeRestApp.class) //
            .registerShutdownHook(true).run(args);
}