private InputStream getInputStream()

in src/main/java/org/apache/sling/tracer/internal/JSONRecording.java [232:246]


    private InputStream getInputStream(boolean compressed) throws IOException {
        InputStream is = new ByteArrayInputStream(json);

        if (compressed) {
            if (!compress) {
                throw new IllegalArgumentException("Cannot provide compressed response with compression disabled");
            }
            return is;
        }

        if (compress) {
            is = new GZIPInputStream(is);
        }
        return is;
    }