public StreamingOutput getResource ( final String resourceName , final long nodeId , final Map < QueryParameter , String > queryParams ) throws JaxRxException { final StreamingOutput sOutput = new StreamingOutput ( ) { @ Override public void write ( final OutputStream output ) throws IOException , JaxRxException { // final String xPath = queryParams.get(QueryParameter.QUERY); final String revision = queryParams . get ( QueryParameter . REVISION ) ; final String wrap = queryParams . get ( QueryParameter . WRAP ) ; final String doNodeId = queryParams . get ( QueryParameter . OUTPUT ) ; final boolean wrapResult = ( wrap == null ) ? false : wrap . equalsIgnoreCase ( YESSTRING ) ; final boolean nodeid = ( doNodeId == null ) ? false : doNodeId . equalsIgnoreCase ( YESSTRING ) ; final Long rev = revision == null ? null : Long . valueOf ( revision ) ; serialize ( resourceName , nodeId , rev , nodeid , output , wrapResult ) ; } } ; return sOutput ; }
This method is responsible to deliver the whole XML resource addressed by a unique node id .