Jason, I’m glad you mentioned this, because we had neglected to ask
for compressed data in TalkingPuffin.

For others wanting to do this (in Java/Scala):

import java.util.zip.GZIPInputStream

    conn.setRequestProperty("Accept-Encoding", "gzip")

    ...

    val is = conn.getInputStream
    val ce = conn.getHeaderField("Content-Encoding")
    XML.load(if (ce == "gzip") new GZIPInputStream(is) else is)

Reply via email to