// DO NOT EDIT THIS FILE - it is machine generated -*- c++ -*-

#ifndef __gnu_java_net_protocol_http_Connection__
#define __gnu_java_net_protocol_http_Connection__

#pragma interface

#include <java/net/HttpURLConnection.h>

extern "Java"
{
  namespace gnu
  {
    namespace java
    {
      namespace net
      {
        namespace protocol
        {
          namespace http
          {
            class Connection;
          }
        }
        class HeaderFieldHelper;
      }
    }
  }
  namespace java
  {
    namespace net
    {
      class URL;
      class Socket;
    }
  }
}

class gnu::java::net::protocol::http::Connection : public ::java::net::HttpURLConnection
{
public:  // actually protected
  Connection (::java::net::URL *);
public:
  void connect ();
  void disconnect ();
public: // actually package-private
  void sendRequest ();
private:
  void receiveReply ();
public:
  jboolean usingProxy ();
  ::java::io::InputStream *getInputStream ();
  ::java::io::OutputStream *getOutputStream ();
  void setRequestMethod (::java::lang::String *);
  void addRequestProperty (::java::lang::String *, ::java::lang::String *);
  ::java::lang::String *getRequestProperty (::java::lang::String *);
  void setRequestProperty (::java::lang::String *, ::java::lang::String *);
  ::java::util::Map *getRequestProperties ();
  ::java::lang::String *getHeaderField (::java::lang::String *);
  ::java::util::Map *getHeaderFields ();
  ::java::lang::String *getHeaderField (jint);
  ::java::lang::String *getHeaderFieldKey (jint);
private:
  ::java::net::Socket * __attribute__((aligned(__alignof__( ::java::net::HttpURLConnection )))) socket;
  static jint proxyPort;
  static jboolean proxyInUse;
  static ::java::lang::String *proxyHost;
  ::java::io::DataInputStream *inputStream;
  ::java::io::OutputStream *outputStream;
  ::java::io::ByteArrayOutputStream *bufferedOutputStream;
  ::java::util::HashMap *requestProperties;
  ::gnu::java::net::HeaderFieldHelper *headers;
public:

  static ::java::lang::Class class$;
};

#endif /* __gnu_java_net_protocol_http_Connection__ */
