[Tutor] Is socket.socket() a func or a class

2012-04-06 Thread Khalid Al-Ghamdi
hi all, I'm reading this book that says when creating a socket you have to use the socket.socket() *function *as in : ss=socket.socket() but whey i check they type it says it's a class which makes sense cause you're creating a socket object. type(ss) class 'socket.socket' so, which is it? or

Re: [Tutor] Is socket.socket() a func or a class

2012-04-06 Thread Alan Gauld
On 06/04/12 07:10, Khalid Al-Ghamdi wrote: I'm reading this book that says when creating a socket you have to use the socket.socket() _function _as in : ... type(ss) class 'socket.socket' so, which is it? or do authors loosely use these terms interchangeably in this context? It just

Re: [Tutor] Is socket.socket() a func or a class

2012-04-06 Thread Steven D'Aprano
Khalid Al-Ghamdi wrote: hi all, I'm reading this book that says when creating a socket you have to use the socket.socket() *function *as in : ss=socket.socket() but whey i check they type it says it's a class which makes sense cause you're creating a socket object. type(ss) class