I have a Enum class with rights.
public enum UserRight {
SYSTEMMANAGEMENT, USERADMINISTRATION, ROLEADMINISTRATION,
STRUCTUREADMINISTRATION, DOCUMENTADMINISTRATION;
}
Run Code Online (Sandbox Code Playgroud)
Now i want to load all my rights into a list except SYSTEMMANAGEMENT. I do it now like this:
availrightslist.addAll(Arrays.asList(UserRight.values()));
Run Code Online (Sandbox Code Playgroud)
How can I load all rights without the SYSTEMMANAGEMENT right?
我在 Vaadin 使用国际化 I18N。我有一个带有 getText 方法的国际化类。
public static String getText(String key) {
String returnValue = "";
String value = "";
String space = " ";
Locale locale = new Locale("de", "DE");
try {
// session specific locale stored in attribute "locale"
// if you want add a new language then add a new else if with the
// new Locale like ("fr", "FR").
if (VaadinServletService.getCurrentRequest() != null) {
if ((Locale) VaadinServletService.getCurrentServletRequest().getSession().getAttribute("locale") != null) {
if (VaadinServletService.getCurrentServletRequest().getSession().getAttribute("locale").toString().equals("en_EN")) {
locale = new …
Run Code Online (Sandbox Code Playgroud) 我们正在使用 Vaadin 14. 我们应该将项目中的哪些文件夹提交给版本控制?文件夹 node_modules 非常大,非常耗时,我们应该提交这个吗?