@Test public void testMap_ModsType() { String xml = "<mods xmlns='http: + "<titleInfo/>" + "<titleInfo/>" + "<identifier type='uuid'>1</identifier>" + "<identifier type='issn'>issn-1</identifier>" + "<recordInfo/>" + "<identifier type='issn'>issn-2</identifier>" + "</mods>"; ModsDefinition mods = ModsUtils.unmarshal(xml, ModsDefinition.class); IdentifierMapper instance = new IdentifierMapper(); IdentifierItem[] expResult = { new IdentifierItem(0, "uuid", "1"), new IdentifierItem(1, "issn", "issn-1"), new IdentifierItem(2, "issn", "issn-2") }; List result = instance.map(mods); assertArrayEquals(expResult, result.toArray()); }
public List<IdentifierItem> map(ModsDefinition mods) { List<IdentifierDefinition> identifiers = mods.getIdentifier(); return mapper.map(identifiers); }
IdentifierMapper { public List<IdentifierItem> map(ModsDefinition mods) { List<IdentifierDefinition> identifiers = mods.getIdentifier(); return mapper.map(identifiers); } }
IdentifierMapper { public List<IdentifierItem> map(ModsDefinition mods) { List<IdentifierDefinition> identifiers = mods.getIdentifier(); return mapper.map(identifiers); }  }
IdentifierMapper { public List<IdentifierItem> map(ModsDefinition mods) { List<IdentifierDefinition> identifiers = mods.getIdentifier(); return mapper.map(identifiers); }  List<IdentifierItem> map(ModsDefinition mods); ModsDefinition map(ModsDefinition mods, List<IdentifierItem> items); }
IdentifierMapper { public List<IdentifierItem> map(ModsDefinition mods) { List<IdentifierDefinition> identifiers = mods.getIdentifier(); return mapper.map(identifiers); }  List<IdentifierItem> map(ModsDefinition mods); ModsDefinition map(ModsDefinition mods, List<IdentifierItem> items);  }