public void setFields ( XfdfReader xfdf ) throws IOException , DocumentException { HashMap fd = xfdf . getFields ( ) ; for ( Iterator i = fd . keySet ( ) . iterator ( ) ; i . hasNext ( ) ; ) { String f = ( String ) i . next ( ) ; String v = xfdf . getFieldValue ( f ) ; if ( v != null ) setField ( f , v ) ; List l = xfdf . getListValues ( f ) ; if ( l != null ) setListSelection ( v , ( String [ ] ) l . toArray ( new String [ l . size ( ) ] ) ) ; } }
Sets the fields by XFDF merging .