renatoh commented on code in PR #3048: URL: https://github.com/apache/solr/pull/3048#discussion_r1928511029
########## solr/solrj/src/java/org/apache/solr/common/util/SimpleOrderedMap.java: ########## @@ -68,24 +74,153 @@ public SimpleOrderedMap(Map.Entry<String, T>[] nameValuePairs) { public SimpleOrderedMap<T> clone() { ArrayList<Object> newList = new ArrayList<>(nvPairs.size()); newList.addAll(nvPairs); - return new SimpleOrderedMap<>(newList); + return new SimpleOrderedMap<T>(newList); + } + + @Override + public boolean isEmpty() { + return nvPairs.isEmpty(); + } + + @Override + public boolean containsKey(final Object key) { + return this.indexOf((String) key) >= 0; } /** - * Returns a shared, empty, and immutable instance of SimpleOrderedMap. + * Returns {@code true} if this map maps one or more keys to the specified value. Review Comment: the java-doc is automatically inherited? isn't that only the case if I use the {@inheritDoc} tag in the java doc itself. And even then, it does not inherit the param, return and throw part of the java-doc, unless I tag them one by one. Nevertheless, I will move to {@inheritDoc} where possible, in order not to repeat java doc. With respect to "one or more", I did not come up with that phrasing, that is on Map#contains, and although it sounds strange, it is technically correct. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: issues-unsubscr...@solr.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@solr.apache.org For additional commands, e-mail: issues-h...@solr.apache.org