A structure that can hold a prefix string and a root string. Prefixes mainly for defining the type of root data, for more accurate search results
예제 #1
0
 public void ToSplittedStringsTwoRoots()
 {
     // More than one item
     IndexString test = new IndexString("good:", "bad?ok");
     Assert.AreEqual("bad good:bad ok good:ok", String.Join(" ", test.ToSplittedStrings()));
 }
예제 #2
0
 public void ToSplittedStringsNoPrefix()
 {
     // No prefix
     IndexString test = new IndexString(null, "good-ok");
     Assert.AreEqual("good-ok", String.Join(" ", test.ToSplittedStrings()));
 }
예제 #3
0
 public void ToSplittedStringsNoRoot()
 {
     // No root
     IndexString test = new IndexString("good", null);
     Assert.AreEqual("", String.Join(" ", test.ToSplittedStrings()));
 }
예제 #4
0
 public void ToSplittedStringsBasic()
 {
     // One item
     IndexString test = new IndexString("good:", "bad");
     Assert.AreEqual("bad good:bad", String.Join(" ", test.ToSplittedStrings()));
 }