You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@hc.apache.org by Mike Oliver <ol...@appsaspeers.com> on 2002/12/13 16:53:32 UTC
RE: Tutorial or examples or archive
Or an archive of this list....;-)
Michael Oliver
AppsAsPeers LLC
7391 S. Bullrider Ave.
Tucson, AZ 85747
Phone:(520)574-1150
Fax:(520)844-1036
-----Original Message-----
From: Thandra, Kiran [mailto:Extern.Kiran.Thandra@vw.com]
Sent: Friday, December 13, 2002 8:51 AM
To: 'Commons HttpClient Project'
Subject: RE: Tutorial or examples
It would help me too.
Thanks,
Thandra
-----Original Message-----
From: Mike Oliver [mailto:ollie@appsaspeers.com]
Sent: Friday, December 13, 2002 10:35 AM
To: commons-httpclient-dev@jakarta.apache.org
Subject: Tutorial or examples
I have been searching for either a tutorial or examples of the use of
commons-httpclient but have not had good success, any help would be
appreciated.
Michael Oliver
Chief Technology Officer
AppsAsPeers LLC
7391 S. Bullrider Ave.
Tucson, AZ 85747
520.574.1150 Voice
520.844.1036 Fax
520.270.8862 Cell
http://www.appsaspeers.com <http://www.appsaspeers.com/> Home Page
5202708862@voicestream.net SMS
http://www.ollie.ezpeer.net <http://www.ollie.ezpeer.net/> Personal
Home Page
http://www.ollie.im-live.com/im-live/ Instant Chat
MikeOliverAZ@hotmail.com MSN Messenger
MikeOliverAZ@yahoo.com Yahoo Instant Messenger
MikeOliverAZ Aol Instant Messenger
--
To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
For additional commands, e-mail:
<ma...@jakarta.apache.org>
Re: Tutorial or examples or archive
Posted by Ortwin Glück <or...@nose.ch>.
Yes, we have noticed that the samples have become out ouf date with the
latest changes. They will be updated soon.
Odi
Mike Oliver wrote:
> Ok thanks 20021213 down, I noticed there are examples in the source, but
> the TrivialApp.java uses deprecated methods between your example and
> that I should be able to get started.
>
> Michael Oliver
> AppsAsPeers LLC
> 7391 S. Bullrider Ave.
> Tucson, AZ 85747
> Phone:(520)574-1150
> Fax:(520)844-1036
RE: Tutorial or examples or archive
Posted by Mike Oliver <ol...@appsaspeers.com>.
Ok thanks 20021213 down, I noticed there are examples in the source, but
the TrivialApp.java uses deprecated methods between your example and
that I should be able to get started.
Michael Oliver
AppsAsPeers LLC
7391 S. Bullrider Ave.
Tucson, AZ 85747
Phone:(520)574-1150
Fax:(520)844-1036
-----Original Message-----
From: Chang Sau Sheong [mailto:cssheong@pacific.net.sg]
Sent: Friday, December 13, 2002 10:01 AM
To: 'Commons HttpClient Project'
Subject: Re: Tutorial or examples or archive
You have to get the latest from the CVS. A lot of changes since the
alpha1
release.
.sausheong
elipva Ltd
----- Original Message -----
From: "Mike Oliver" <ol...@appsaspeers.com>
To: "'Commons HttpClient Project'"
<co...@jakarta.apache.org>
Sent: Saturday, December 14, 2002 12:45 AM
Subject: RE: Tutorial or examples or archive
> HostConfiguration? What package is that in?
>
> Michael Oliver
> AppsAsPeers LLC
> 7391 S. Bullrider Ave.
> Tucson, AZ 85747
> Phone:(520)574-1150
> Fax:(520)844-1036
>
>
> -----Original Message-----
> From: Chang Sau Sheong [mailto:cssheong@pacific.net.sg]
> Sent: Friday, December 13, 2002 9:09 AM
> To: Commons HttpClient Project
> Subject: Re: Tutorial or examples or archive
>
> I'm planning to write a short tutorial for HttpClient sometime during
> the
> Christmas break (hopefully that's before the alpha2 release). In the
> meantime, check out the sample JUnit code in the codebase. This is a
> simple
> snippet of how I use HttpClient myself:
>
> <snippet>
>
> InputStream is = null;
>
> try {
> // 1. create httpclient object
> HttpClient client = new HttpClient();
>
> // 2. create config object
> HostConfiguration config = new HostConfiguration();
>
> // 3. set the configuration
> config.setHost(url, port, protocol);
>
> // 4. apply the configuration
> client.setHostConfiguration(config);
>
> // 5. create a post method
> UrlPostMethod post = new UrlPostMethod(url + page);
>
> // 6. set the query parameters you want to post to the page
> post.addParameter(key, value);
>
> // 7. execute the method through the client object
> client.executeMethod(post);
>
> // 8. get back the response as an input stream
> is = post.getResponseBodyAsStream();
>
> }
> catch (Exception e) {}
>
> // ... process your input stream
>
> </snippet>
>
> Hope it helps.
>
>
> .sausheong
> elipva Ltd
>
> ----- Original Message -----
> From: "Mike Oliver" <ol...@appsaspeers.com>
> To: "'Commons HttpClient Project'"
> <co...@jakarta.apache.org>
> Sent: Friday, December 13, 2002 11:53 PM
> Subject: RE: Tutorial or examples or archive
>
>
> > Or an archive of this list....;-)
> >
> > Michael Oliver
> > AppsAsPeers LLC
> > 7391 S. Bullrider Ave.
> > Tucson, AZ 85747
> > Phone:(520)574-1150
> > Fax:(520)844-1036
> >
> >
> > -----Original Message-----
> > From: Thandra, Kiran [mailto:Extern.Kiran.Thandra@vw.com]
> > Sent: Friday, December 13, 2002 8:51 AM
> > To: 'Commons HttpClient Project'
> > Subject: RE: Tutorial or examples
> >
> > It would help me too.
> >
> > Thanks,
> > Thandra
> >
> > -----Original Message-----
> > From: Mike Oliver [mailto:ollie@appsaspeers.com]
> > Sent: Friday, December 13, 2002 10:35 AM
> > To: commons-httpclient-dev@jakarta.apache.org
> > Subject: Tutorial or examples
> >
> >
> > I have been searching for either a tutorial or examples of the use
of
> > commons-httpclient but have not had good success, any help would be
> > appreciated.
> >
> >
> >
> > Michael Oliver
> > Chief Technology Officer
> > AppsAsPeers LLC
> > 7391 S. Bullrider Ave.
> > Tucson, AZ 85747
> > 520.574.1150 Voice
> > 520.844.1036 Fax
> > 520.270.8862 Cell
> > http://www.appsaspeers.com <http://www.appsaspeers.com/> Home Page
> > 5202708862@voicestream.net SMS
> > http://www.ollie.ezpeer.net <http://www.ollie.ezpeer.net/> Personal
> > Home Page
> > http://www.ollie.im-live.com/im-live/ Instant Chat
> > MikeOliverAZ@hotmail.com MSN Messenger
> > MikeOliverAZ@yahoo.com Yahoo Instant Messenger
> > MikeOliverAZ Aol Instant Messenger
> >
> >
> >
> >
> >
> >
> > --
> > To unsubscribe, e-mail:
> > <ma...@jakarta.apache.org>
> > For additional commands, e-mail:
> > <ma...@jakarta.apache.org>
> >
> >
> >
> >
> > --
> > To unsubscribe, e-mail:
> <ma...@jakarta.apache.org>
> > For additional commands, e-mail:
> <ma...@jakarta.apache.org>
> >
>
>
> --
> To unsubscribe, e-mail:
> <ma...@jakarta.apache.org>
> For additional commands, e-mail:
> <ma...@jakarta.apache.org>
>
>
>
> --
> To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
> For additional commands, e-mail:
<ma...@jakarta.apache.org>
>
--
To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
For additional commands, e-mail:
<ma...@jakarta.apache.org>
Re: Tutorial or examples or archive
Posted by Chang Sau Sheong <cs...@pacific.net.sg>.
You have to get the latest from the CVS. A lot of changes since the alpha1
release.
.sausheong
elipva Ltd
----- Original Message -----
From: "Mike Oliver" <ol...@appsaspeers.com>
To: "'Commons HttpClient Project'"
<co...@jakarta.apache.org>
Sent: Saturday, December 14, 2002 12:45 AM
Subject: RE: Tutorial or examples or archive
> HostConfiguration? What package is that in?
>
> Michael Oliver
> AppsAsPeers LLC
> 7391 S. Bullrider Ave.
> Tucson, AZ 85747
> Phone:(520)574-1150
> Fax:(520)844-1036
>
>
> -----Original Message-----
> From: Chang Sau Sheong [mailto:cssheong@pacific.net.sg]
> Sent: Friday, December 13, 2002 9:09 AM
> To: Commons HttpClient Project
> Subject: Re: Tutorial or examples or archive
>
> I'm planning to write a short tutorial for HttpClient sometime during
> the
> Christmas break (hopefully that's before the alpha2 release). In the
> meantime, check out the sample JUnit code in the codebase. This is a
> simple
> snippet of how I use HttpClient myself:
>
> <snippet>
>
> InputStream is = null;
>
> try {
> // 1. create httpclient object
> HttpClient client = new HttpClient();
>
> // 2. create config object
> HostConfiguration config = new HostConfiguration();
>
> // 3. set the configuration
> config.setHost(url, port, protocol);
>
> // 4. apply the configuration
> client.setHostConfiguration(config);
>
> // 5. create a post method
> UrlPostMethod post = new UrlPostMethod(url + page);
>
> // 6. set the query parameters you want to post to the page
> post.addParameter(key, value);
>
> // 7. execute the method through the client object
> client.executeMethod(post);
>
> // 8. get back the response as an input stream
> is = post.getResponseBodyAsStream();
>
> }
> catch (Exception e) {}
>
> // ... process your input stream
>
> </snippet>
>
> Hope it helps.
>
>
> .sausheong
> elipva Ltd
>
> ----- Original Message -----
> From: "Mike Oliver" <ol...@appsaspeers.com>
> To: "'Commons HttpClient Project'"
> <co...@jakarta.apache.org>
> Sent: Friday, December 13, 2002 11:53 PM
> Subject: RE: Tutorial or examples or archive
>
>
> > Or an archive of this list....;-)
> >
> > Michael Oliver
> > AppsAsPeers LLC
> > 7391 S. Bullrider Ave.
> > Tucson, AZ 85747
> > Phone:(520)574-1150
> > Fax:(520)844-1036
> >
> >
> > -----Original Message-----
> > From: Thandra, Kiran [mailto:Extern.Kiran.Thandra@vw.com]
> > Sent: Friday, December 13, 2002 8:51 AM
> > To: 'Commons HttpClient Project'
> > Subject: RE: Tutorial or examples
> >
> > It would help me too.
> >
> > Thanks,
> > Thandra
> >
> > -----Original Message-----
> > From: Mike Oliver [mailto:ollie@appsaspeers.com]
> > Sent: Friday, December 13, 2002 10:35 AM
> > To: commons-httpclient-dev@jakarta.apache.org
> > Subject: Tutorial or examples
> >
> >
> > I have been searching for either a tutorial or examples of the use of
> > commons-httpclient but have not had good success, any help would be
> > appreciated.
> >
> >
> >
> > Michael Oliver
> > Chief Technology Officer
> > AppsAsPeers LLC
> > 7391 S. Bullrider Ave.
> > Tucson, AZ 85747
> > 520.574.1150 Voice
> > 520.844.1036 Fax
> > 520.270.8862 Cell
> > http://www.appsaspeers.com <http://www.appsaspeers.com/> Home Page
> > 5202708862@voicestream.net SMS
> > http://www.ollie.ezpeer.net <http://www.ollie.ezpeer.net/> Personal
> > Home Page
> > http://www.ollie.im-live.com/im-live/ Instant Chat
> > MikeOliverAZ@hotmail.com MSN Messenger
> > MikeOliverAZ@yahoo.com Yahoo Instant Messenger
> > MikeOliverAZ Aol Instant Messenger
> >
> >
> >
> >
> >
> >
> > --
> > To unsubscribe, e-mail:
> > <ma...@jakarta.apache.org>
> > For additional commands, e-mail:
> > <ma...@jakarta.apache.org>
> >
> >
> >
> >
> > --
> > To unsubscribe, e-mail:
> <ma...@jakarta.apache.org>
> > For additional commands, e-mail:
> <ma...@jakarta.apache.org>
> >
>
>
> --
> To unsubscribe, e-mail:
> <ma...@jakarta.apache.org>
> For additional commands, e-mail:
> <ma...@jakarta.apache.org>
>
>
>
> --
> To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
> For additional commands, e-mail:
<ma...@jakarta.apache.org>
>
RE: Tutorial or examples or archive
Posted by Mike Oliver <ol...@appsaspeers.com>.
HostConfiguration? What package is that in?
Michael Oliver
AppsAsPeers LLC
7391 S. Bullrider Ave.
Tucson, AZ 85747
Phone:(520)574-1150
Fax:(520)844-1036
-----Original Message-----
From: Chang Sau Sheong [mailto:cssheong@pacific.net.sg]
Sent: Friday, December 13, 2002 9:09 AM
To: Commons HttpClient Project
Subject: Re: Tutorial or examples or archive
I'm planning to write a short tutorial for HttpClient sometime during
the
Christmas break (hopefully that's before the alpha2 release). In the
meantime, check out the sample JUnit code in the codebase. This is a
simple
snippet of how I use HttpClient myself:
<snippet>
InputStream is = null;
try {
// 1. create httpclient object
HttpClient client = new HttpClient();
// 2. create config object
HostConfiguration config = new HostConfiguration();
// 3. set the configuration
config.setHost(url, port, protocol);
// 4. apply the configuration
client.setHostConfiguration(config);
// 5. create a post method
UrlPostMethod post = new UrlPostMethod(url + page);
// 6. set the query parameters you want to post to the page
post.addParameter(key, value);
// 7. execute the method through the client object
client.executeMethod(post);
// 8. get back the response as an input stream
is = post.getResponseBodyAsStream();
}
catch (Exception e) {}
// ... process your input stream
</snippet>
Hope it helps.
.sausheong
elipva Ltd
----- Original Message -----
From: "Mike Oliver" <ol...@appsaspeers.com>
To: "'Commons HttpClient Project'"
<co...@jakarta.apache.org>
Sent: Friday, December 13, 2002 11:53 PM
Subject: RE: Tutorial or examples or archive
> Or an archive of this list....;-)
>
> Michael Oliver
> AppsAsPeers LLC
> 7391 S. Bullrider Ave.
> Tucson, AZ 85747
> Phone:(520)574-1150
> Fax:(520)844-1036
>
>
> -----Original Message-----
> From: Thandra, Kiran [mailto:Extern.Kiran.Thandra@vw.com]
> Sent: Friday, December 13, 2002 8:51 AM
> To: 'Commons HttpClient Project'
> Subject: RE: Tutorial or examples
>
> It would help me too.
>
> Thanks,
> Thandra
>
> -----Original Message-----
> From: Mike Oliver [mailto:ollie@appsaspeers.com]
> Sent: Friday, December 13, 2002 10:35 AM
> To: commons-httpclient-dev@jakarta.apache.org
> Subject: Tutorial or examples
>
>
> I have been searching for either a tutorial or examples of the use of
> commons-httpclient but have not had good success, any help would be
> appreciated.
>
>
>
> Michael Oliver
> Chief Technology Officer
> AppsAsPeers LLC
> 7391 S. Bullrider Ave.
> Tucson, AZ 85747
> 520.574.1150 Voice
> 520.844.1036 Fax
> 520.270.8862 Cell
> http://www.appsaspeers.com <http://www.appsaspeers.com/> Home Page
> 5202708862@voicestream.net SMS
> http://www.ollie.ezpeer.net <http://www.ollie.ezpeer.net/> Personal
> Home Page
> http://www.ollie.im-live.com/im-live/ Instant Chat
> MikeOliverAZ@hotmail.com MSN Messenger
> MikeOliverAZ@yahoo.com Yahoo Instant Messenger
> MikeOliverAZ Aol Instant Messenger
>
>
>
>
>
>
> --
> To unsubscribe, e-mail:
> <ma...@jakarta.apache.org>
> For additional commands, e-mail:
> <ma...@jakarta.apache.org>
>
>
>
>
> --
> To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
> For additional commands, e-mail:
<ma...@jakarta.apache.org>
>
--
To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
For additional commands, e-mail:
<ma...@jakarta.apache.org>
RE: Tutorial or examples or archive
Posted by Mike Oliver <ol...@appsaspeers.com>.
Yes of course anything helps and the JUnit source helps a lot too,
thanks.
Michael Oliver
AppsAsPeers LLC
7391 S. Bullrider Ave.
Tucson, AZ 85747
Phone:(520)574-1150
Fax:(520)844-1036
-----Original Message-----
From: Chang Sau Sheong [mailto:cssheong@pacific.net.sg]
Sent: Friday, December 13, 2002 9:09 AM
To: Commons HttpClient Project
Subject: Re: Tutorial or examples or archive
I'm planning to write a short tutorial for HttpClient sometime during
the
Christmas break (hopefully that's before the alpha2 release). In the
meantime, check out the sample JUnit code in the codebase. This is a
simple
snippet of how I use HttpClient myself:
<snippet>
InputStream is = null;
try {
// 1. create httpclient object
HttpClient client = new HttpClient();
// 2. create config object
HostConfiguration config = new HostConfiguration();
// 3. set the configuration
config.setHost(url, port, protocol);
// 4. apply the configuration
client.setHostConfiguration(config);
// 5. create a post method
UrlPostMethod post = new UrlPostMethod(url + page);
// 6. set the query parameters you want to post to the page
post.addParameter(key, value);
// 7. execute the method through the client object
client.executeMethod(post);
// 8. get back the response as an input stream
is = post.getResponseBodyAsStream();
}
catch (Exception e) {}
// ... process your input stream
</snippet>
Hope it helps.
.sausheong
elipva Ltd
----- Original Message -----
From: "Mike Oliver" <ol...@appsaspeers.com>
To: "'Commons HttpClient Project'"
<co...@jakarta.apache.org>
Sent: Friday, December 13, 2002 11:53 PM
Subject: RE: Tutorial or examples or archive
> Or an archive of this list....;-)
>
> Michael Oliver
> AppsAsPeers LLC
> 7391 S. Bullrider Ave.
> Tucson, AZ 85747
> Phone:(520)574-1150
> Fax:(520)844-1036
>
>
> -----Original Message-----
> From: Thandra, Kiran [mailto:Extern.Kiran.Thandra@vw.com]
> Sent: Friday, December 13, 2002 8:51 AM
> To: 'Commons HttpClient Project'
> Subject: RE: Tutorial or examples
>
> It would help me too.
>
> Thanks,
> Thandra
>
> -----Original Message-----
> From: Mike Oliver [mailto:ollie@appsaspeers.com]
> Sent: Friday, December 13, 2002 10:35 AM
> To: commons-httpclient-dev@jakarta.apache.org
> Subject: Tutorial or examples
>
>
> I have been searching for either a tutorial or examples of the use of
> commons-httpclient but have not had good success, any help would be
> appreciated.
>
>
>
> Michael Oliver
> Chief Technology Officer
> AppsAsPeers LLC
> 7391 S. Bullrider Ave.
> Tucson, AZ 85747
> 520.574.1150 Voice
> 520.844.1036 Fax
> 520.270.8862 Cell
> http://www.appsaspeers.com <http://www.appsaspeers.com/> Home Page
> 5202708862@voicestream.net SMS
> http://www.ollie.ezpeer.net <http://www.ollie.ezpeer.net/> Personal
> Home Page
> http://www.ollie.im-live.com/im-live/ Instant Chat
> MikeOliverAZ@hotmail.com MSN Messenger
> MikeOliverAZ@yahoo.com Yahoo Instant Messenger
> MikeOliverAZ Aol Instant Messenger
>
>
>
>
>
>
> --
> To unsubscribe, e-mail:
> <ma...@jakarta.apache.org>
> For additional commands, e-mail:
> <ma...@jakarta.apache.org>
>
>
>
>
> --
> To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
> For additional commands, e-mail:
<ma...@jakarta.apache.org>
>
--
To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
For additional commands, e-mail:
<ma...@jakarta.apache.org>
Re: Tutorial or examples or archive
Posted by Chang Sau Sheong <cs...@pacific.net.sg>.
I'm planning to write a short tutorial for HttpClient sometime during the
Christmas break (hopefully that's before the alpha2 release). In the
meantime, check out the sample JUnit code in the codebase. This is a simple
snippet of how I use HttpClient myself:
<snippet>
InputStream is = null;
try {
// 1. create httpclient object
HttpClient client = new HttpClient();
// 2. create config object
HostConfiguration config = new HostConfiguration();
// 3. set the configuration
config.setHost(url, port, protocol);
// 4. apply the configuration
client.setHostConfiguration(config);
// 5. create a post method
UrlPostMethod post = new UrlPostMethod(url + page);
// 6. set the query parameters you want to post to the page
post.addParameter(key, value);
// 7. execute the method through the client object
client.executeMethod(post);
// 8. get back the response as an input stream
is = post.getResponseBodyAsStream();
}
catch (Exception e) {}
// ... process your input stream
</snippet>
Hope it helps.
.sausheong
elipva Ltd
----- Original Message -----
From: "Mike Oliver" <ol...@appsaspeers.com>
To: "'Commons HttpClient Project'"
<co...@jakarta.apache.org>
Sent: Friday, December 13, 2002 11:53 PM
Subject: RE: Tutorial or examples or archive
> Or an archive of this list....;-)
>
> Michael Oliver
> AppsAsPeers LLC
> 7391 S. Bullrider Ave.
> Tucson, AZ 85747
> Phone:(520)574-1150
> Fax:(520)844-1036
>
>
> -----Original Message-----
> From: Thandra, Kiran [mailto:Extern.Kiran.Thandra@vw.com]
> Sent: Friday, December 13, 2002 8:51 AM
> To: 'Commons HttpClient Project'
> Subject: RE: Tutorial or examples
>
> It would help me too.
>
> Thanks,
> Thandra
>
> -----Original Message-----
> From: Mike Oliver [mailto:ollie@appsaspeers.com]
> Sent: Friday, December 13, 2002 10:35 AM
> To: commons-httpclient-dev@jakarta.apache.org
> Subject: Tutorial or examples
>
>
> I have been searching for either a tutorial or examples of the use of
> commons-httpclient but have not had good success, any help would be
> appreciated.
>
>
>
> Michael Oliver
> Chief Technology Officer
> AppsAsPeers LLC
> 7391 S. Bullrider Ave.
> Tucson, AZ 85747
> 520.574.1150 Voice
> 520.844.1036 Fax
> 520.270.8862 Cell
> http://www.appsaspeers.com <http://www.appsaspeers.com/> Home Page
> 5202708862@voicestream.net SMS
> http://www.ollie.ezpeer.net <http://www.ollie.ezpeer.net/> Personal
> Home Page
> http://www.ollie.im-live.com/im-live/ Instant Chat
> MikeOliverAZ@hotmail.com MSN Messenger
> MikeOliverAZ@yahoo.com Yahoo Instant Messenger
> MikeOliverAZ Aol Instant Messenger
>
>
>
>
>
>
> --
> To unsubscribe, e-mail:
> <ma...@jakarta.apache.org>
> For additional commands, e-mail:
> <ma...@jakarta.apache.org>
>
>
>
>
> --
> To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
> For additional commands, e-mail:
<ma...@jakarta.apache.org>
>