Returns all options visible to the current user. @return options (with names in lower-case)
()
| 312 | * @return options (with names in lower-case) |
| 313 | */ |
| 314 | public HashMap<String, Object> options() { |
| 315 | final HashMap<String, Object> map = new HashMap<>(); |
| 316 | if(user().has(Perm.ADMIN)) { |
| 317 | for(final Option<?> o : soptions) { |
| 318 | map.put(o.name().toLowerCase(Locale.ENGLISH), soptions.get(o)); |
| 319 | } |
| 320 | } |
| 321 | for(final Option<?> o : options) { |
| 322 | map.put(o.name().toLowerCase(Locale.ENGLISH), options.get(o)); |
| 323 | } |
| 324 | return map; |
| 325 | } |
| 326 | |
| 327 | /** |
| 328 | * Returns the value of an option visible to the current user. |