Content deleted Content added
m clarify |
m clarify for general audience |
||
Line 1:
A '''method''' in [[object-oriented programming]] (OOP) is a [[Procedure (computer science)|procedure]] associated with a [[Message passing|message]] and an [[Object (computer science)|object]]. An object consists of data and behavior. The data and behavior comprise an interface, which specifies how the object may be utilized by any of various consumers of the object. <
Data is represented as [[Property (programming)|properties]] of the object and behaviors are represented as methods of the object. For example, a <code>Window</code> object could have methods such as <code>open</code> and <code>close</code>, while its state (whether it is opened or closed at any given point in time) would be a property.
|