Member Function - Research Article from World of Computer Science

This encyclopedia article consists of approximately 1 page of information about Member Function.
Encyclopedia Article

Member Function - Research Article from World of Computer Science

This encyclopedia article consists of approximately 1 page of information about Member Function.
This section contains 175 words
(approx. 1 page at 300 words per page)

A member function is a component of objects. Objects are miniature programs, which consist of both code and data (data members). The code is comprised of a series of member functions. It is these functions that are called on by a user, also described as sending the object a message, in order to use the object. For example, calling an object's Draw function can also be described as sending the object the Draw message. Calling a member function invokes the function on the object.

A member function allows some of an object's behavior or contents to be retrieved. Thus, it forms one of the underpinnings of the programming of object-oriented languages such as C++.

Member functions can be classified according to their purpose. Examples of some types of member functions in C++ are "getters," "setters," "command methods," and "factory methods." Also, classification based on the properties of member functions is possible. Examples of these include "primitive or composed method," "hook or template method," "class or instance method," or a "convenience method."

This section contains 175 words
(approx. 1 page at 300 words per page)
Copyrights
Gale
Member Function from Gale. ©2005-2006 Thomson Gale, a part of the Thomson Corporation. All rights reserved.