@Override public void marshal(Object source, HierarchicalStreamWriter writer, MarshallingContext context) { HeaderSource headerSource = (HeaderSource) source; writer.addAttribute("name", headerSource.getName()); writer.addAttribute("description", headerSource.getDescription()); writer.addAttribute("optional", Boolean.toString(headerSource.isOptional())); writer.setValue(headerSource.getLocation()); }
assertEquals("input2", sources.get(1).getName()); assertEquals(false, sources.get(1).isOptional()); assertEquals("C:\\data\\x.dim", sources.get(1).getLocation());