diff options
author | 2016-12-12 19:37:38 +0700 | |
---|---|---|
committer | 2016-12-12 22:49:47 +0300 | |
commit | a100c61ee6786f9149770e21c22ee4adcef689ed (patch) | |
tree | 1e08df703c61de00888d0915939c5b8690893c85 /juick-spring-www/src/main/java/com/juick/www/settings | |
parent | d446ba75acc05ec331540d51348bdc2be5aecb42 (diff) |
using thymeleaf static variables for show settings
Diffstat (limited to 'juick-spring-www/src/main/java/com/juick/www/settings')
-rw-r--r-- | juick-spring-www/src/main/java/com/juick/www/settings/TemplateSettingsHolder.java | 35 |
1 files changed, 0 insertions, 35 deletions
diff --git a/juick-spring-www/src/main/java/com/juick/www/settings/TemplateSettingsHolder.java b/juick-spring-www/src/main/java/com/juick/www/settings/TemplateSettingsHolder.java deleted file mode 100644 index c6df73da..00000000 --- a/juick-spring-www/src/main/java/com/juick/www/settings/TemplateSettingsHolder.java +++ /dev/null @@ -1,35 +0,0 @@ -package com.juick.www.settings; - -import org.apache.commons.lang3.BooleanUtils; -import org.apache.commons.lang3.builder.ToStringBuilder; -import org.springframework.core.env.Environment; - -/** - * Created by aalexeev on 11/22/16. - */ -public class TemplateSettingsHolder { - private final boolean showSponsors; - private final boolean showSape; - - - public TemplateSettingsHolder(Environment settingsEnv) { - showSponsors = BooleanUtils.toBoolean(settingsEnv.getProperty("template.showSponsors", "false")); - showSape = BooleanUtils.toBoolean(settingsEnv.getProperty("template.showSape", "true")); - } - - @Override - public String toString() { - return new ToStringBuilder(this) - .append("showSponsors", showSponsors) - .append("showSape", showSape) - .toString(); - } - - public boolean isShowSponsors() { - return showSponsors; - } - - public boolean isShowSape() { - return showSape; - } -} |