equal
deleted
inserted
replaced
386 * @return a {@code Map<String, Object>} object containing all properties. |
386 * @return a {@code Map<String, Object>} object containing all properties. |
387 * If no properties are recognized, an empty map is returned. |
387 * If no properties are recognized, an empty map is returned. |
388 * @see #getProperty(String) |
388 * @see #getProperty(String) |
389 * @since 1.5 |
389 * @since 1.5 |
390 */ |
390 */ |
|
391 @SuppressWarnings("unchecked") // Cast of result of clone. |
391 public Map<String,Object> properties() { |
392 public Map<String,Object> properties() { |
392 Map<String,Object> ret; |
393 Map<String,Object> ret; |
393 if (properties == null) { |
394 if (properties == null) { |
394 ret = new HashMap<String,Object>(0); |
395 ret = new HashMap<>(0); |
395 } else { |
396 } else { |
396 ret = (Map<String,Object>) (properties.clone()); |
397 ret = (Map<String,Object>) (properties.clone()); |
397 } |
398 } |
398 return Collections.unmodifiableMap(ret); |
399 return Collections.unmodifiableMap(ret); |
399 } |
400 } |