By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
434,960 Members | 2,459 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 434,960 IT Pros & Developers. It's quick & easy.

Socket class disadvantages

P: n/a
Hi

I have a question related to Socket class. What are the advantages /
disadvantages of using Socket class comparing to TcpClient and
HttpWebRequest

Regards
Piotr Kołodziej
Dec 15 '07 #1
Share this Question
Share on Google+
2 Replies


P: n/a
Piotr,

Well, when using the TcpClient vs the Socket, you probably want to use
the client most of the time, since it exposes the underlying Socket through
the Client property.

Now, comparing those to HttpWebRequest, with HttpWebRequest, it wraps
all of the protocol interaction for you, forming the request, parsing the
response, etc, etc. You don't have that with the TcpClient/Socket.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Piotrekk" <Pi*************@gmail.comwrote in message
news:fd**********************************@x69g2000 hsx.googlegroups.com...
Hi

I have a question related to Socket class. What are the advantages /
disadvantages of using Socket class comparing to TcpClient and
HttpWebRequest

Regards
Piotr Kołodziej

Dec 15 '07 #2

P: n/a
Socket can be used for UDP packets, the others can't.
"Piotrekk" <Pi*************@gmail.comwrote in message
news:fd**********************************@x69g2000 hsx.googlegroups.com...
Hi

I have a question related to Socket class. What are the advantages /
disadvantages of using Socket class comparing to TcpClient and
HttpWebRequest

Regards
Piotr Kołodziej
Dec 27 '07 #3

This discussion thread is closed

Replies have been disabled for this discussion.