question: void capture ( final Context context , final Request request , final CapturePoint mode ) { StringWriter out = new StringWriter ( ) ; PrintWriter writer = new PrintWriter ( out ) ; String id = context . getId ( ) ; switch ( mode ) { case REQUEST : captureRequest ( writer , request , id ) ; break ; case FILTERED_REQUEST : captureFilteredRequest ( writer , request , id ) ; break ; default : throw new IllegalArgumentException ( "The given mode is not accepted: " + mode . name ( ) ) ; } if ( captureContext ) { writer . println ( "Context's content as JSON:" ) ; captureContextAsJson ( writer , context ) ; } logger . info ( out . toString ( ) ) ; }
target:  Captures the given request, in the given mode.