FeedEntityParser parser = (FeedEntityParser) EntityParserFactory.getParser(EntityType.FEED);
Feed feed = parser.parse(stream);
Assert.assertNotNull(feed);
final LateArrival lateArrival = new LateArrival();
lateArrival.setCutOff(new Frequency("4", Frequency.TimeUnit.hours));
feed.setLateArrival(lateArrival);
StringWriter stringWriter = new StringWriter();
Marshaller marshaller = EntityType.FEED.getMarshaller();
marshaller.marshal(feed, stringWriter);