@Test void getMap() { Map<String, String> result = this.tool.getMap(); assertNotNull(result, "Returned null instead of a map"); assertTrue(result.isEmpty(), "Returned map wasn't initially empty"); assertFalse(result.containsKey("nullvalue"), "null value already present in the empty map"); assertFalse(result.containsValue(null), "null value already present in the empty map"); result.put("nullvalue", null); assertNull(result.get("nullvalue")); assertTrue(result.containsKey("nullvalue"), "Failed to insert null value in the map"); assertTrue(result.containsValue(null), "Failed to insert null value in the map"); assertFalse(result.containsKey(null), "null key already present in the empty map"); assertFalse(result.containsValue("nullkey"), "null key already present in the empty map"); result.put(null, "nullkey"); assertEquals("nullkey", result.get(null), "Failed to insert null key in the map"); assertTrue(result.containsKey(null), "Failed to insert null key in the map"); assertTrue(result.containsValue("nullkey"), "Failed to insert null key in the map"); }
public <K, V> Map<K, V> getMap() { return new HashMap<>(); }
CollectionTool extends org.apache.velocity.tools.generic.CollectionTool { public <K, V> Map<K, V> getMap() { return new HashMap<>(); } }
CollectionTool extends org.apache.velocity.tools.generic.CollectionTool { public <K, V> Map<K, V> getMap() { return new HashMap<>(); }  }
CollectionTool extends org.apache.velocity.tools.generic.CollectionTool { public <K, V> Map<K, V> getMap() { return new HashMap<>(); }  List<E> getArrayList(); List<E> getLinkedList(); Map<K, V> getMap(); SortedMap<K, V> getSortedMap(); Map<K, V> getOrderedMap(); Set<E> getSet(); SortedSet<E> getSortedSet(); Set<E> getOrderedSet(); Queue<E> getQueue(); BlockingQueue<E> getBlockingQueue(); Queue<E> getPriorityQueue(); List<E> unmodifiable(List<E> input); Map<K, V> unmodifiable(Map<K, V> input); Set<E> unmodifiable(Set<E> input); Collection<E> unmodifiable(Collection<E> input); Collection<E> union(Collection<E> a, Collection<E> b); Collection<E> intersection(Collection<E> a, Collection<E> b); Collection<E> disjunction(Collection<E> a, Collection<E> b); boolean reverseModifiable(List<E> input); boolean sortModifiable(List<E> input); }
CollectionTool extends org.apache.velocity.tools.generic.CollectionTool { public <K, V> Map<K, V> getMap() { return new HashMap<>(); }  List<E> getArrayList(); List<E> getLinkedList(); Map<K, V> getMap(); SortedMap<K, V> getSortedMap(); Map<K, V> getOrderedMap(); Set<E> getSet(); SortedSet<E> getSortedSet(); Set<E> getOrderedSet(); Queue<E> getQueue(); BlockingQueue<E> getBlockingQueue(); Queue<E> getPriorityQueue(); List<E> unmodifiable(List<E> input); Map<K, V> unmodifiable(Map<K, V> input); Set<E> unmodifiable(Set<E> input); Collection<E> unmodifiable(Collection<E> input); Collection<E> union(Collection<E> a, Collection<E> b); Collection<E> intersection(Collection<E> a, Collection<E> b); Collection<E> disjunction(Collection<E> a, Collection<E> b); boolean reverseModifiable(List<E> input); boolean sortModifiable(List<E> input);  }