how do i download doc from google insight in java
<p>i was able to get this code for c# which works perfectly fine..but due to dependancy issues i need the java/ python equivalent of it.. </p>

<pre><code>class Program
{
    static void Main(string[] args)
    {
        var client = new WebClient();
        String userName = "*******";
        String password = "*******";
        var response =        client.DownloadString("https://www.google.com/accounts/ClientLogin?accountType=GOOGLE&amp;Email="+userName+"@gmail.com&amp;Passwd="+password+"&amp;service=trendspro&amp;source=test-test-v1");
        var sid = response.Split('\n')[0];
        client.Headers.Add("Cookie", sid);
        String downloadURL = "http://www.google.com/insights/search/overviewReport?cat=0-7&amp;geo=BR&amp;date=today%207-d&amp;cmpt=geo&amp;content=1&amp;export=1";
        byte[] csv = client.DownloadData(downloadURL);
        Console.WriteLine(Encoding.Unicode.GetString(csv));
        Console.ReadLine();
    }
}
</code></pre>
