Example usage for org.springframework.boot.cli.command.init ProjectType getName

List of usage examples for org.springframework.boot.cli.command.init ProjectType getName

Introduction

In this page you can find the example usage for org.springframework.boot.cli.command.init ProjectType getName.

Prototype

String getName() 

Source Link

Usage

From source file:org.springframework.boot.cli.command.init.ServiceCapabilitiesReportGenerator.java

private void reportAvilableProjectTypes(InitializrServiceMetadata metadata, StringBuilder report) {
    report.append("Available project types:" + NEW_LINE);
    report.append("------------------------" + NEW_LINE);
    List<String> typeIds = new ArrayList<String>(metadata.getProjectTypes().keySet());
    Collections.sort(typeIds);//from w w  w .  j av  a  2  s .co  m
    for (String typeId : typeIds) {
        ProjectType type = metadata.getProjectTypes().get(typeId);
        report.append(typeId + " -  " + type.getName());
        if (!type.getTags().isEmpty()) {
            reportTags(report, type);
        }
        if (type.isDefaultType()) {
            report.append(" (default)");
        }
        report.append(NEW_LINE);
    }
}