com.xlrit.gears.server.frontend.FrontendProperties Maven / Gradle / Ivy
package com.xlrit.gears.server.frontend;
import java.util.List;
import java.util.Map;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.stereotype.Component;
import lombok.Data;
@Data
@Component
@ConfigurationProperties(prefix = "gears.frontend")
public class FrontendProperties {
private String name; // deprecated; use title instead
private String title;
private String theme;
private String routerMode;
private boolean enableHtml;
private List languages;
private Map additional;
@Override
public String toString() {
return "FrontendProperties[" +
"name='" + name + "'" +
"title='" + title + "'" +
"theme='" + theme + "'" +
"routerMode='" + routerMode + "'" +
"enableHtml='" + enableHtml + "'" +
']';
}
public String getLanguagesAsString() {
return languages == null || languages.isEmpty() ? "" : String.join(",", languages);
}
}