Source:
<code>private void buildEntry(Element entryElement, XmlEntry parentEntry, int baseQuark) { String path = entryElement.getAttribute(TmfXmlUiStrings.PATH); <START> if (path.equals(EMPTY_STRING)) { <END> path = TmfXmlStrings.WILDCARD; } List<Element> displayElements = XmlUtils.getChildElements(entryElement, TmfXmlUiStrings.DISPLAY_ELEMENT); List<Element> entryElements = XmlUtils.getChildElements(entryElement, TmfXmlUiStrings.ENTRY_ELEMENT); if ((displayElements.size() == 0) && (entryElements.size() == 0)) { Activator.logWarning(String.format("XML view: entry for %s should have either a display element or entry elements", path)); return; } ITmfStateSystem ss = parentEntry.getStateSystem(); String[] paths = path.split(SPLIT_STRING); int i = 0; List<Integer> quarks = new ArrayList<>(); quarks.add(baseQuark); try { while (i < paths.length) { List<Integer> subQuarks = new ArrayList<>(); String name = paths[i].replaceAll("\\*", ".*"); for (int relativeQuark : quarks) { for (int quark : ss.getSubAttributes(relativeQuark, false, name)) { subQuarks.add(quark); } } quarks = subQuarks; i++; } XmlEntry currentEntry = parentEntry; Element displayElement = null; List<XmlEntry> entryList = new ArrayList<>(); if (displayElements.size() > 0) { displayElement = displayElements.get(0); } for (int quark : quarks) { currentEntry = parentEntry; if (displayElement != null) { currentEntry = processEntry(entryElement, displayElement, parentEntry, quark, ss); entryList.add(currentEntry); } for (Element subEntryEl : entryElements) { buildEntry(subEntryEl, currentEntry, quark); } } if (!entryList.isEmpty()) { buildTree(entryList, parentEntry); } } catch (AttributeNotFoundException e) { } }</code><technical_language>path.isEmpty()</technical_language>

Target:
private void buildEntry(Element entryElement, XmlEntry parentEntry, int baseQuark) { String path = entryElement.getAttribute(TmfXmlUiStrings.PATH); if (path.isEmpty()) { path = TmfXmlStrings.WILDCARD; } List<Element> displayElements = XmlUtils.getChildElements(entryElement, TmfXmlUiStrings.DISPLAY_ELEMENT); List<Element> entryElements = XmlUtils.getChildElements(entryElement, TmfXmlUiStrings.ENTRY_ELEMENT); if (displayElements.isEmpty() && entryElements.isEmpty()) { Activator.logWarning(String.format("XML view: entry for %s should have either a display element or entry elements", path)); return; } ITmfStateSystem ss = parentEntry.getStateSystem(); String[] paths = path.split(SPLIT_STRING); int i = 0; List<Integer> quarks = Collections.singletonList(baseQuark); try { while (i < paths.length) { List<Integer> subQuarks = new LinkedList<>(); String name = paths[i].replaceAll("\\*", ".*"); for (int relativeQuark : quarks) { for (int quark : ss.getSubAttributes(relativeQuark, false, name)) { subQuarks.add(quark); } } quarks = subQuarks; i++; } XmlEntry currentEntry = parentEntry; Element displayElement = null; Set<XmlEntry> entryList = new TreeSet<>(getEntryComparator()); if (!displayElements.isEmpty()) { displayElement = displayElements.get(0); } for (int quark : quarks) { currentEntry = parentEntry; if (displayElement != null) { currentEntry = processEntry(entryElement, displayElement, parentEntry, quark, ss); entryList.add(currentEntry); } for (Element subEntryEl : entryElements) { buildEntry(subEntryEl, currentEntry, quark); } } if (!entryList.isEmpty()) { buildTree(entryList, parentEntry); } } catch (AttributeNotFoundException e) { } }