diff options
author | jmisinco | 2013-12-17 15:37:47 +0000 |
---|---|---|
committer | Gerrit Code Review @ Eclipse.org | 2013-12-18 20:33:37 +0000 |
commit | e3200c768c2983d2e36882ce8cb1ee4b41c6ecd6 (patch) | |
tree | 354f907b3e924be306ade30c8adf0e47bce3c82c /plugins/org.eclipse.osee.framework.jdk.core | |
parent | 59a104e254f2200dc7fa951ca8b105961cc246c7 (diff) | |
download | org.eclipse.osee-e3200c768c2983d2e36882ce8cb1ee4b41c6ecd6.tar.gz org.eclipse.osee-e3200c768c2983d2e36882ce8cb1ee4b41c6ecd6.tar.xz org.eclipse.osee-e3200c768c2983d2e36882ce8cb1ee4b41c6ecd6.zip |
bug: Fixes to search tagger
Change-Id: Ib13d00935e2b9c2bcf5cc4d75be86b83d5db529a
Diffstat (limited to 'plugins/org.eclipse.osee.framework.jdk.core')
-rw-r--r-- | plugins/org.eclipse.osee.framework.jdk.core/src/org/eclipse/osee/framework/jdk/core/util/io/xml/XmlTextInputStream.java | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/plugins/org.eclipse.osee.framework.jdk.core/src/org/eclipse/osee/framework/jdk/core/util/io/xml/XmlTextInputStream.java b/plugins/org.eclipse.osee.framework.jdk.core/src/org/eclipse/osee/framework/jdk/core/util/io/xml/XmlTextInputStream.java index 743608afb41..6273a9bbcd4 100644 --- a/plugins/org.eclipse.osee.framework.jdk.core/src/org/eclipse/osee/framework/jdk/core/util/io/xml/XmlTextInputStream.java +++ b/plugins/org.eclipse.osee.framework.jdk.core/src/org/eclipse/osee/framework/jdk/core/util/io/xml/XmlTextInputStream.java @@ -22,12 +22,12 @@ import org.eclipse.osee.framework.jdk.core.util.ReservedCharacters; * @author Roberto E. Escobar */ public class XmlTextInputStream extends BufferedInputStream { - private static final String START_PARAGRAPH = "<w:p"; - private static final String STOP_PARAGRAPH = "</w:p"; - private static final String START_WORDML_TEXT = "<w:t>"; + private static final String START_PARAGRAPH_REGEX = "<w:p( .+)?>"; + private static final String STOP_PARAGRAPH = "</w:p>"; + private static final String START_WORDML_TEXT_REGEX = "<w:t( .+)?>"; private static final String END_WORDML_TEXT = "</w:t>"; private static final String LINE_BREAK = "<w:br/>"; - private static final String TAB = "<w:tab/>"; + private static final String TAB_REGEX = "<w:tab( .+)?/>"; private IReadHelper readHelper; @@ -236,17 +236,17 @@ public class XmlTextInputStream extends BufferedInputStream { if ((char) value == '>') { partOfTag = false; String tag = buffer.toString(); - if (tag.equals(START_WORDML_TEXT)) { + if (tag.matches(START_WORDML_TEXT_REGEX)) { collect = true; } else if (tag.equals(END_WORDML_TEXT)) { collect = false; - } else if (tag.startsWith(START_PARAGRAPH)) { + } else if (tag.matches(START_PARAGRAPH_REGEX)) { isStartOfParagraph = true; } else if (tag.startsWith(STOP_PARAGRAPH)) { isStartOfParagraph = false; } else if (tag.startsWith(LINE_BREAK)) { isBreak = true; - } else if (tag.startsWith(TAB)) { + } else if (tag.matches(TAB_REGEX)) { isBreak = true; } |