Jump to content

Object (computer science)

From Wikipedia, the free encyclopedia
(Redirected from Object (programming))

Template:Short description {{safesubst:#invoke:Unsubst||date=__DATE__|$B= Template:Ambox }}

In software development, an object is a semantic entity that has state, behavior, and identity.[1][2][3][4] An object can model some part of reality or can be an invention of the design process whose collaborations with other such objects serve as the mechanisms that provide some higher-level behavior. Put another way, an object represents an individual, identifiable item, unit, or entity, either real or abstract, with a well-defined role in the problem domain.[1]Template:Rp

A programming language can be classified based on its support for objects. A language that provides an encapsulation construct for state, behavior, and identity is classified as object-based. If the language also provides polymorphism and inheritance it is classified as object-oriented.[5]{{ safesubst:#invoke:Unsubst||date=__DATE__ |$B= Template:Fix }} A language that supports creating an object from a class is classified as class-based. A language that supports object creation via a template object is classified as prototype-based.

The concept of object is used in many different software contexts, including:

In purely object-oriented programming languages, such as Java and C#, all classes might be part of an inheritance tree with some root type (see any type), and all objects are either instances of the root type or descend from it; in Java, this type is Template:Javadoc:SE; in C#/.NET, this is System.Object.

See also

Template:Columns-list

References

Template:Reflist

Template:Software engineering Template:Data types Template:Authority control

  1. ↑ 1.0 1.1 1.2 Template:Cite book
  2. ↑ {{#invoke:citation/CS1|citation |CitationClass=web }}
  3. ↑ {{#invoke:citation/CS1|citation |CitationClass=web }}
  4. ↑ {{#invoke:citation/CS1|citation |CitationClass=web }}
  5. ↑ {{#invoke:citation/CS1|citation |CitationClass=web }}
  6. ↑ Template:Cite book