edu.stanford.nlp.util.Genericsjava.util.LinkedHashSet



Project stanfordnlp/CoreNLP in file ...c9e1c/src.edu.stanford.nlp.dcoref.SpeakerInfo.java (2014-06-10)
@@ -2,8 +2,8 @@ package edu.stanford.nlp.dcoref;
 
 import edu.stanford.nlp.ling.CoreAnnotations;
 import edu.stanford.nlp.math.NumberMatchingRegex;
-import edu.stanford.nlp.util.Generics;
 
+import java.util.LinkedHashSet;
 import java.util.Set;
 import java.util.regex.Pattern;
 
@@ -17,7 +17,8 @@ public class SpeakerInfo {
   private String speakerName;
   private String[] speakerNameStrings; // tokenized speaker name
   private String speakerDesc;
-  private Set<Mention> mentions = Generics.newHashSet();  // Mentions that corresponds to the speaker...
+  private Set<Mention> mentions = new LinkedHashSet<Mention>();  // Mentions that corresponds to the speaker...
+  private Mention originalMention;            // the mention used when creating this SpeakerInfo
   private boolean speakerIdIsNumber;          // speaker id is a number (probably mention id)
   private boolean speakerIdIsAutoDetermined;  // speaker id was auto determined by system
   private Mention mainMention;
@@ -95,4 +96,8 @@ public class SpeakerInfo {
     return corefClusterId;
   }
 
+  public String toString() {
+    return speakerId;
+  }
+
 }
Project stanfordnlp/CoreNLP in file ...16c7b/src.edu.stanford.nlp.dcoref.SpeakerInfo.java (2014-06-10)
@@ -2,8 +2,8 @@ package edu.stanford.nlp.dcoref;
 
 import edu.stanford.nlp.ling.CoreAnnotations;
 import edu.stanford.nlp.math.NumberMatchingRegex;
-import edu.stanford.nlp.util.Generics;
 
+import java.util.LinkedHashSet;
 import java.util.Set;
 import java.util.regex.Pattern;
 
@@ -17,7 +17,8 @@ public class SpeakerInfo {
   private String speakerName;
   private String[] speakerNameStrings; // tokenized speaker name
   private String speakerDesc;
-  private Set<Mention> mentions = Generics.newHashSet();  // Mentions that corresponds to the speaker...
+  private Set<Mention> mentions = new LinkedHashSet<Mention>();  // Mentions that corresponds to the speaker...
+  private Mention originalMention;            // the mention used when creating this SpeakerInfo
   private boolean speakerIdIsNumber;          // speaker id is a number (probably mention id)
   private boolean speakerIdIsAutoDetermined;  // speaker id was auto determined by system
   private Mention mainMention;
@@ -95,4 +96,8 @@ public class SpeakerInfo {
     return corefClusterId;
   }
 
+  public String toString() {
+    return speakerId;
+  }
+
 }
Project stanfordnlp/CoreNLP in file ...6b1b1/src.edu.stanford.nlp.dcoref.SpeakerInfo.java (2013-10-26)
@@ -2,8 +2,8 @@ package edu.stanford.nlp.dcoref;
 
 import edu.stanford.nlp.ling.CoreAnnotations;
 import edu.stanford.nlp.math.NumberMatchingRegex;
-import edu.stanford.nlp.util.Generics;
 
+import java.util.LinkedHashSet;
 import java.util.Set;
 import java.util.regex.Pattern;
 
@@ -17,7 +17,8 @@ public class SpeakerInfo {
   private String speakerName;
   private String[] speakerNameStrings; // tokenized speaker name
   private String speakerDesc;
-  private Set<Mention> mentions = Generics.newHashSet();  // Mentions that corresponds to the speaker...
+  private Set<Mention> mentions = new LinkedHashSet<Mention>();  // Mentions that corresponds to the speaker...
+  private Mention originalMention;            // the mention used when creating this SpeakerInfo
   private boolean speakerIdIsNumber;          // speaker id is a number (probably mention id)
   private boolean speakerIdIsAutoDetermined;  // speaker id was auto determined by system
   private Mention mainMention;
@@ -95,4 +96,8 @@ public class SpeakerInfo {
     return corefClusterId;
   }
 
+  public String toString() {
+    return speakerId;
+  }
+
 }
Project stanfordnlp/CoreNLP in file ...bf879/src.edu.stanford.nlp.dcoref.SpeakerInfo.java (2013-10-26)
@@ -2,8 +2,8 @@ package edu.stanford.nlp.dcoref;
 
 import edu.stanford.nlp.ling.CoreAnnotations;
 import edu.stanford.nlp.math.NumberMatchingRegex;
-import edu.stanford.nlp.util.Generics;
 
+import java.util.LinkedHashSet;
 import java.util.Set;
 import java.util.regex.Pattern;
 
@@ -17,7 +17,8 @@ public class SpeakerInfo {
   private String speakerName;
   private String[] speakerNameStrings; // tokenized speaker name
   private String speakerDesc;
-  private Set<Mention> mentions = Generics.newHashSet();  // Mentions that corresponds to the speaker...
+  private Set<Mention> mentions = new LinkedHashSet<Mention>();  // Mentions that corresponds to the speaker...
+  private Mention originalMention;            // the mention used when creating this SpeakerInfo
   private boolean speakerIdIsNumber;          // speaker id is a number (probably mention id)
   private boolean speakerIdIsAutoDetermined;  // speaker id was auto determined by system
   private Mention mainMention;
@@ -95,4 +96,8 @@ public class SpeakerInfo {
     return corefClusterId;
   }
 
+  public String toString() {
+    return speakerId;
+  }
+
 }
Project stanfordnlp/CoreNLP in file ...c88ec/src.edu.stanford.nlp.dcoref.SpeakerInfo.java (2013-10-27)
@@ -2,8 +2,8 @@ package edu.stanford.nlp.dcoref;
 
 import edu.stanford.nlp.ling.CoreAnnotations;
 import edu.stanford.nlp.math.NumberMatchingRegex;
-import edu.stanford.nlp.util.Generics;
 
+import java.util.LinkedHashSet;
 import java.util.Set;
 import java.util.regex.Pattern;
 
@@ -17,7 +17,8 @@ public class SpeakerInfo {
   private String speakerName;
   private String[] speakerNameStrings; // tokenized speaker name
   private String speakerDesc;
-  private Set<Mention> mentions = Generics.newHashSet();  // Mentions that corresponds to the speaker...
+  private Set<Mention> mentions = new LinkedHashSet<Mention>();  // Mentions that corresponds to the speaker...
+  private Mention originalMention;            // the mention used when creating this SpeakerInfo
   private boolean speakerIdIsNumber;          // speaker id is a number (probably mention id)
   private boolean speakerIdIsAutoDetermined;  // speaker id was auto determined by system
   private Mention mainMention;
@@ -95,4 +96,8 @@ public class SpeakerInfo {
     return corefClusterId;
   }
 
+  public String toString() {
+    return speakerId;
+  }
+
 }