What is object()

H

Hameed Khan

hi,
i was reading library refrence manual. there i found
object() function. they says in library refrence that
"Return a new featureless object. object() is
a base for all new style classes. It has the methods
that are common to all instances of new style
classes."

My questions are whats the use of this function and
the object returned by it? and what are new style
classes?.

Thanks,
Hameed Khan

__________________________________
Do you Yahoo!?
Yahoo! SiteBuilder - Free web site building tool. Try it!
http://webhosting.yahoo.com/ps/sb/
 
A

Aahz

i was reading library refrence manual. there i found
object() function. they says in library refrence that
"Return a new featureless object. object() is
a base for all new style classes. It has the methods
that are common to all instances of new style
classes."

There's not much use for an instance of object. Don't worry about it.
My questions are whats the use of this function and
the object returned by it? and what are new style
classes?.

http://www.python.org/2.2.3/descrintro.html
 
D

David Eppstein

[email protected] (Aahz) said:
There's not much use for an instance of object. Don't worry about it.

It can be useful when you want something that is guaranteed to be
different from all other objects and has no other purpose than existing
and being different.

Beyond that somewhat specialized use, object exists to be subclassed,
not instantiated directly.
 
D

Dan Bishop

Gerrit Holl said:
"Not much" >= "none" ;-)
Because none is not much ;-)

No, "Not much" < "none", because the comparison is case-sensitive.
However, it is True that "not much" >= "none" and "Not much" >= None
;-)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
474,176
Messages
2,570,949
Members
47,500
Latest member
ArianneJsb

Latest Threads

Top