XliffImpl extends XliffElementImpl implements Xliff { public List<NonXliffElement> getNonXliffElements() { return Collections.unmodifiableList(nonXliffElements); } XliffImpl(Version version, List<File> files);  XliffImpl(org.w3c.dom.Element element); @Override List<? extends Node> getChildren(); List<File> getFiles(); Collection<NonXliffAttribute> getNonXliffAttributes(); List<NonXliffElement> getNonXliffElements(); Version getVersion(); XmlLang getXmlLang(); void setFiles(List<File> files); void setNonXliffAttributes(
			Collection<NonXliffAttribute> nonXliffAttributes); void setVersion(Version version); void setXmlLang(XmlLang xmlLang);  }
@Test public void testGetNonXliffElements() { Document doc = Utils.createDocument(); Element elem = doc.createElementNS(XLIFF_12_NAMESPACE, "xliff"); elem.setAttributeNS(null, "version", "1.2"); elem.appendChild(createDefaultFile().asXmlNode(doc)); try { XliffImpl xliff = new XliffImpl(elem); assertTrue(xliff.getNonXliffElements().isEmpty()); } catch (ConstraintViolationException e) { fail("Did not expect ConstraintViolationException"); } elem.appendChild(doc.createElementNS("ns", "name")); try { XliffImpl xliff = new XliffImpl(elem); NonXliffElement nxe = xliff.getNonXliffElements().get(0); assertEquals("ns", nxe.getNamespaceUri()); assertEquals("name", nxe.getName()); elem.removeChild(elem.getLastChild()); } catch (ConstraintViolationException e) { fail("Did not expect ConstraintViolationException"); } }