java.util.function.Function



Project stanfordnlp/CoreNLP in file ...a/src.edu.stanford.nlp.util.TwoDimensionalMap.java (2015-03-14)
@@ -2,7 +2,6 @@ package edu.stanford.nlp.util;
 
 import java.util.*;
 import java.io.Serializable;
-import java.util.function.Function;
 
 import edu.stanford.nlp.util.MapFactory;
 
@@ -88,7 +87,6 @@ public class TwoDimensionalMap<K1, K2, V> implements Serializable, Iterable<TwoD
   }
 
   public Collection<V> values() {
-    // TODO: Should return a specialized class
     List<V> s = Generics.newArrayList();
     for (Map<K2, V> innerMap : map.values()) {
       s.addAll(innerMap.values());
Project stanfordnlp/CoreNLP in file ...a/src.edu.stanford.nlp.util.BijectiveFunction.java (2015-03-14)
@@ -1,9 +1,7 @@
 package edu.stanford.nlp.util;
 
-import java.util.function.Function;
-
 /**
- * A {@link java.util.function.Function} that is invertible, and so has the unapply method.
+ * A {@link Function} that is invertible, and so has the unapply method.
  * 
  *
  * @author David Hall
Project stanfordnlp/CoreNLP in file ...9/src.edu.stanford.nlp.util.BijectiveFunction.java (2015-02-18)
@@ -1,9 +1,7 @@
 package edu.stanford.nlp.util;
 
-import java.util.function.Function;
-
 /**
- * A {@link java.util.function.Function} that is invertible, and so has the unapply method.
+ * A {@link Function} that is invertible, and so has the unapply method.
  * 
  *
  * @author David Hall
Project stanfordnlp/CoreNLP in file ...7/src.edu.stanford.nlp.util.BijectiveFunction.java (2014-09-08)
@@ -1,9 +1,7 @@
 package edu.stanford.nlp.util;
 
-import java.util.function.Function;
-
 /**
- * A {@link java.util.function.Function} that is invertible, and so has the unapply method.
+ * A {@link Function} that is invertible, and so has the unapply method.
  * 
  *
  * @author David Hall
Project stanfordnlp/CoreNLP in file ...ord.nlp.parser.lexparser.ChineseMaxentLexicon.java (2014-09-09)
@@ -16,7 +16,6 @@ import edu.stanford.nlp.stats.*;
 
 import java.io.*;
 import java.util.*;
-import java.util.function.Function;
 import java.util.regex.Pattern;
 
 /**
@@ -168,7 +167,7 @@ public class ChineseMaxentLexicon implements Lexicon {
   }
 
   private String getTag(String word) {
-    int iW = wordIndex.addToIndex(word);
+    int iW = wordIndex.indexOf(word, true);
     ensureProbs(iW, false);
     return Counters.argmax(logProbs);
   }