-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Locale Handler #126
Locale Handler #126
Changes from 3 commits
3f48bec
c924ba4
86f384e
34cecbf
0c6c077
705b7f2
1e4c1d0
a431da3
ab781c1
9969892
f979bba
8f50c4f
323ddcc
8e9cec0
c514324
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,86 +4,88 @@ | |
* Default application values | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Why did you re-order the Default enums? Makes it hard so seet, what was changed. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I can undo it, but there seemed to be no particularly logical order. If you want I can put them back There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Would be nice to only see, what you have changed. |
||
* | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. would you mind reverting your changes and only commiting a new file with your new changes? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Done |
||
* @author svenkubiak | ||
* @author williamdunne | ||
* | ||
*/ | ||
public enum Default { | ||
LANGUAGE("en"), | ||
DATA_DELIMITER("#"), | ||
DELIMITER("|"), | ||
FLASH_COOKIE_NAME("MANGOOIO-FLASH"), | ||
AUTH_COOKIE_NAME("MANGOOIO-AUTH"), | ||
COOKIE_EXPIRES("86400"), | ||
LOCALHOST("127.0.0.1"), //NOSONAR | ||
APPLICATION_ADMIN_CACHE("false"), | ||
APPLICATION_ADMIN_CONFIG("false"), | ||
APPLICATION_ADMIN_HEALTH("false"), | ||
APPLICATION_ADMIN_MEMORY("false"), | ||
APPLICATION_ADMIN_METRICS("false"), | ||
APPLICATION_ADMIN_ROUTES("false"), | ||
APPLICATION_ADMIN_SCHEDULER("false"), | ||
APPLICATION_ADMIN_SYSTEM("false"), | ||
APPLICATION_CONTROLLER("controllers."), | ||
APPLICATION_HOST("127.0.0.1"), //NOSONAR | ||
JBCRYPT_ROUNDS("12"), | ||
APPLICATION_PORT("8080"), | ||
BUNDLE_NAME("translations/messages"), | ||
ASSETS_PATH("src/main/resources/files/assets/"), | ||
CONFIG_PATH("/src/main/resources/application.yaml"), | ||
STYLESHEET_FOLDER("stylesheets"), | ||
JAVSCRIPT_FOLDER("javascripts"), | ||
CONFIGURATION_FILE("application.yaml"), | ||
DEFAULT_CONFIGURATION("default"), | ||
VERSION_PROPERTIES("version.properties"), | ||
LOGO_FILE("logo.txt"), | ||
CONTENT_TYPE("text/html; charset=UTF-8"), | ||
SCHEDULER_PREFIX("org.quartz."), | ||
APPLICATION_SECRET_MIN_LENGTH("16"), | ||
SERVER("Undertow"), | ||
CACHE_NAME("mangooio"), | ||
TEMPLATES_FOLDER("/templates/"), | ||
TEMPLATE_SUFFIX(".ftl"), | ||
AUTH_COOKIE_EXPIRES("3600"), | ||
COOKIE_NAME("MANGOOIO-SESSION"), | ||
SPLITTER("&"), | ||
SEPERATOR(":"), | ||
NOSNIFF("nosniff"), | ||
SAMEORIGIN("SAMEORIGIN"), | ||
FILTER_METHOD("execute"), | ||
APPLICATION_TIMER("false"), | ||
ASSETS_PATH("src/main/resources/files/assets/"), | ||
AUTHENTICATION("@authentication"), | ||
AUTHENTICITY_TOKEN("authenticityToken"), | ||
XSS_PROTECTION("1"), | ||
FILES_FOLDER("files"), | ||
MODULE_CLASS("conf.Module"), | ||
VERSION("unknown"), | ||
LOGBACK_PROD_FILE("logback.prod.xml"), | ||
NUMBER_FORMAT("0.######"), | ||
EXCEPTION_TEMPLATE_NAME("exception.ftl"), | ||
DEFAULT_TEMPLATES_DIR("/templates/defaults/"), | ||
X_XSS_PPROTECTION("1"), | ||
COOKIE_SECURE("false"), //NOSONAR | ||
AUTH_COOKIE_ENCRYPT("false"), | ||
AUTH_COOKIE_EXPIRES("3600"), | ||
AUTH_COOKIE_NAME("MANGOOIO-AUTH"), | ||
AUTH_COOKIE_REMEMBER_EXPIRES("1209600"), | ||
AUTH_COOKIE_SECURE("false"), //NOSONAR | ||
CACHE_MAX_SIZE("5000"), | ||
AUTH_COOKIE_VERSION("0"), | ||
BASICAUTH_CREDENTIALS_LENGTH("2"), | ||
BLOCKING("@blocking"), | ||
BUNDLE_NAME("translations/messages"), | ||
CACHE_CLASS("io.mangoo.cache.Cache"), | ||
CACHE_EXPIRES("afterAccess"), | ||
CACHE_EXPIRES_ACCESS("3600"), | ||
CACHE_EXPIRES_WRITE("3600"), | ||
APPLICATION_ADMIN_HEALTH("false"), | ||
APPLICATION_ADMIN_CACHE("false"), | ||
APPLICATION_ADMIN_CONFIG("false"), | ||
APPLICATION_ADMIN_ROUTES("false"), | ||
APPLICATION_ADMIN_SYSTEM("false"), | ||
APPLICATION_ADMIN_METRICS("false"), | ||
APPLICATION_ADMIN_MEMORY("false"), | ||
APPLICATION_ADMIN_SCHEDULER("false"), | ||
APPLICATION_TIMER("false"), | ||
AUTH_COOKIE_ENCRYPT("false"), | ||
AUTH_COOKIE_VERSION("0"), | ||
AUTH_COOKIE_REMEMBER_EXPIRES("1209600"), | ||
CACHE_MAX_SIZE("5000"), | ||
CACHE_NAME("mangooio"), | ||
CONFIGURATION_FILE("application.yaml"), | ||
CONFIG_PATH("/src/main/resources/application.yaml"), | ||
CONTENT_TYPE("text/html; charset=UTF-8"), | ||
COOKIE_ENCRYPTION("false"), | ||
COOKIE_EXPIRES("86400"), | ||
COOKIE_NAME("MANGOOIO-SESSION"), | ||
COOKIE_SECURE("false"), //NOSONAR | ||
COOKIE_VERSION("0"), | ||
DATA_DELIMITER("#"), | ||
DEFAULT_CONFIGURATION("default"), | ||
DEFAULT_TEMPLATES_DIR("/templates/defaults/"), | ||
DELIMITER("|"), | ||
EXCEPTION_TEMPLATE_NAME("exception.ftl"), | ||
EXECUTION_THREADPOOL("10"), | ||
FILES_FOLDER("files"), | ||
FILTER_METHOD("execute"), | ||
FLASH_COOKIE_NAME("MANGOOIO-FLASH"), | ||
JAVSCRIPT_FOLDER("javascripts"), | ||
JBCRYPT_ROUNDS("12"), | ||
LANGUAGE("en"), | ||
LOCALE_COOKIE_NAME("lang"), | ||
LOCALHOST("127.0.0.1"), //NOSONAR | ||
LOGBACK_PROD_FILE("logback.prod.xml"), | ||
LOGO_FILE("logo.txt"), | ||
MODULE_CLASS("conf.Module"), | ||
NOSNIFF("nosniff"), | ||
NUMBER_FORMAT("0.######"), | ||
OAUTH_REQUEST_PARAMETER("oauth"), | ||
ROUTES_FILE("routes.yaml"), | ||
SAMEORIGIN("SAMEORIGIN"), | ||
SCHEDULER_AUTOSTART("true"), | ||
SCHEDULER_JOB_GROUP("MangooSchedulerJobGroup"), | ||
SCHEDULER_TRIGGER_GROUP("MangooSchedulerTriggerGroup"), | ||
BASICAUTH_CREDENTIALS_LENGTH("2"), | ||
OAUTH_REQUEST_PARAMETER("oauth"), | ||
SCHEDULER_PACKAGE("jobs"), | ||
COOKIE_ENCRYPTION("false"), | ||
EXECUTION_THREADPOOL("10"), | ||
ROUTES_FILE("routes.yaml"), | ||
APPLICATION_CONTROLLER("controllers."), | ||
SCHEDULER_PREFIX("org.quartz."), | ||
SCHEDULER_TRIGGER_GROUP("MangooSchedulerTriggerGroup"), | ||
SEPERATOR(":"), | ||
SERVER("Undertow"), | ||
SPLITTER("&"), | ||
SSE_CACHE_PREFIX("MANGOOIO-SSE-"), | ||
STYLESHEET_FOLDER("stylesheets"), | ||
TEMPLATES_FOLDER("/templates/"), | ||
TEMPLATE_SUFFIX(".ftl"), | ||
VERSION("unknown"), | ||
VERSION_PROPERTIES("version.properties"), | ||
WSS_CACHE_PREFIX("MANGOOIO-WSS-"), | ||
AUTHENTICATION("@authentication"), | ||
BLOCKING("@blocking"), | ||
CACHE_CLASS("io.mangoo.cache.Cache"); | ||
XSS_PROTECTION("1"), | ||
X_XSS_PPROTECTION("1"); | ||
|
||
private final String value; | ||
|
||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -47,6 +47,7 @@ public enum Key { | |
COOKIE_VERSION("cookie.version"), | ||
ERROR("error"), | ||
WARNING("warning"), | ||
LOCALE_COOKIE_NAME("i18n.cookie.name"), | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Would imho be nicer to have this under application and not open a new subtree with i18n with atm only one entry. |
||
SUCCESS("success"), | ||
VALIDATION_REQUIRED("validation.required"), | ||
VALIDATION_MIN("validation.min"), | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
would be application.i18n.cookie.name, right?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done