@Test public void testMultipleStrongs() { final EsvXmlEnhancer esvXmlEnhancer = new EsvXmlEnhancer(null, null, null); Tagging t = new Tagging(); t.setRawStrongs("<07651> <03967> <08141> <07657> <07651>"); esvXmlEnhancer.splitStrong(t); assertEquals("07651 03967 08141 07657 07651", t.getStrongs()); }
void splitStrong(final Tagging t) { final String rawStrongs = t.getRawStrongs(); if (rawStrongs == null) { t.setStrongs(""); t.setGrammar(""); return; } final Matcher matcher = STRONGS_SPLITTING.matcher(rawStrongs); boolean matches; StringBuilder sb = new StringBuilder(); while (matches = matcher.find()) { if (matcher.groupCount() > 0) { if (sb.length() > 0) { sb.append(' '); } sb.append(matcher.group(1)); } } t.setStrongs(sb.toString()); if (t.getGrammar() == null) { t.setGrammar(""); } }
EsvXmlEnhancer { void splitStrong(final Tagging t) { final String rawStrongs = t.getRawStrongs(); if (rawStrongs == null) { t.setStrongs(""); t.setGrammar(""); return; } final Matcher matcher = STRONGS_SPLITTING.matcher(rawStrongs); boolean matches; StringBuilder sb = new StringBuilder(); while (matches = matcher.find()) { if (matcher.groupCount() > 0) { if (sb.length() > 0) { sb.append(' '); } sb.append(matcher.group(1)); } } t.setStrongs(sb.toString()); if (t.getGrammar() == null) { t.setGrammar(""); } } }
EsvXmlEnhancer { void splitStrong(final Tagging t) { final String rawStrongs = t.getRawStrongs(); if (rawStrongs == null) { t.setStrongs(""); t.setGrammar(""); return; } final Matcher matcher = STRONGS_SPLITTING.matcher(rawStrongs); boolean matches; StringBuilder sb = new StringBuilder(); while (matches = matcher.find()) { if (matcher.groupCount() > 0) { if (sb.length() > 0) { sb.append(' '); } sb.append(matcher.group(1)); } } t.setStrongs(sb.toString()); if (t.getGrammar() == null) { t.setGrammar(""); } } EsvXmlEnhancer(final File tagging, final File esvText, File outputPath); }
EsvXmlEnhancer { void splitStrong(final Tagging t) { final String rawStrongs = t.getRawStrongs(); if (rawStrongs == null) { t.setStrongs(""); t.setGrammar(""); return; } final Matcher matcher = STRONGS_SPLITTING.matcher(rawStrongs); boolean matches; StringBuilder sb = new StringBuilder(); while (matches = matcher.find()) { if (matcher.groupCount() > 0) { if (sb.length() > 0) { sb.append(' '); } sb.append(matcher.group(1)); } } t.setStrongs(sb.toString()); if (t.getGrammar() == null) { t.setGrammar(""); } } EsvXmlEnhancer(final File tagging, final File esvText, File outputPath); static void main(final String[] args); }
EsvXmlEnhancer { void splitStrong(final Tagging t) { final String rawStrongs = t.getRawStrongs(); if (rawStrongs == null) { t.setStrongs(""); t.setGrammar(""); return; } final Matcher matcher = STRONGS_SPLITTING.matcher(rawStrongs); boolean matches; StringBuilder sb = new StringBuilder(); while (matches = matcher.find()) { if (matcher.groupCount() > 0) { if (sb.length() > 0) { sb.append(' '); } sb.append(matcher.group(1)); } } t.setStrongs(sb.toString()); if (t.getGrammar() == null) { t.setGrammar(""); } } EsvXmlEnhancer(final File tagging, final File esvText, File outputPath); static void main(final String[] args);  }