TransactionXmlReader200 extends AbstractTransactionXmlReader { Replace readReplace( XMLStreamReader xmlStream ) throws NoSuchElementException, XMLStreamException { String handle = xmlStream.getAttributeValue( null, "handle" ); nextElement( xmlStream ); if ( !xmlStream.isStartElement() ) { throw new XMLParsingException( xmlStream, Messages.get( "WFS_REPLACE_MISSING_FEATURE_ELEMENT" ) ); } return new Replace( handle, xmlStream ); }  @Override Transaction read( XMLStreamReader xmlStream ); @Override TransactionAction readAction( XMLStreamReader xmlStream ); @Override Filter readFilter( XMLStreamReader xmlStream ); @Override PropertyReplacement readProperty( XMLStreamReader xmlStream );  }
@Test public void testReadReplaceWfs200SpecExample1() throws Exception { XMLStreamReader xmlStream = getXMLStreamReader( REPLACE_ACTION ); Replace action = reader.readReplace( xmlStream ); xmlStream.require( XMLStreamReader.START_ELEMENT, null, "BuiltUpA_1M" ); assertNull( action.getHandle() ); XMLStreamReader featureReader = action.getReplacementFeatureStream(); skipElement( featureReader ); Filter filter = action.getFilter(); assertNotNull( filter ); xmlStream.require( XMLStreamReader.END_ELEMENT, WFS_200_NS, "Replace" ); }