ArticleTrader.com
  

 Main Menu

  Home
  Member Login
  Forum
  Submit Article
  Membership
  RSS Feeds
  Contact Us
  About

 Services

  Article Distribution
  Link Building

 Tools

  ArticleMS
  Directory Tracker

 Categories

  Automotive
  Business
  Computers
  » Games
  » Hardware
  » Software
  Entertainment
  Finance
  Food
  Health
  Home and Family
  Internet
  Legal
  Science
  Self Improvement
  Shopping
  Society
  Sports
  Technology
  Travel
  Writing

187 users online.



 
  » Category Sponsors
  Get Your Link Here - Limited Time Bargain at only $11/month!

Home » Computers » Software » Object-Oriented Concepts and Constructs

Spec-India
Article written by Spec-India

View Full Profile
Get Html Code
PDF | Print View | Post to your Site

Object-Oriented Concepts and Constructs

Submitted by Spec-India
Sun, 19 Sep 2010

Class, object, method, message, instance variable, and inheritance are the basic concepts of the OO technology. OO metrics are mainly measures of how these constructs are used in the design and development process. Therefore, a short review of definitions is in order.

- A class is a template from which objects can be created. It defines the structure and capabilities of an object instance. The class definition includes the state data and the behaviors (methods) for the instances of that class. The class can be thought of as a factory that creates instances as needed. For example, an Account class may have methods to allow deposits and withdrawals, using a balance instance variable to hold the current balance. This definition defines how an Account works, but it is not an actual account.

- An abstract class is a class that has no instances, created to facilitate sharing of state data and services among similar, more specialized subclasses.

- A concrete class is a class that has instances. For example, there might be a Savings Account class with a number of instances in a bank application.

- An object is an instantiation of a class. It is anything that models things in the real world. These things can be physical entities such as cars, or events such as a concert, or abstractions such as a general-purpose account. An object has state (data) and behavior (methods or services), as defined for the class of objects it belongs to.

- A method is a class service behavior. It operates on data in response to a message and is defined as part of the declaration of a class. Methods reflect how a problem is broken into segments and the capabilities other classes expect of a given class.

- Message: Objects communicate via messages. To request a service from another object, an object sends it a message. This is the only means to get information from an object, because its data is not directly accessible (this is called encapsulation).

- Instance variable is a place to store and refer to an object's state data. In traditional programming, this would be a data variable. In OO paradigm, data is made up of instance variables of an object.

- Inheritance: Similar classes of objects can be organized into categories called class hierarchies. The lower-level classes (called subclasses) can use the services of all the higher classes in their hierarchy. This is called inheritance. Inheritance is simply a way of reusing services and data. As an example, Savings accounts are types of general Account, and IRA accounts are types of Savings accounts. The Savings account inherits the capability to handle deposits from the Account class. The number of subclasses in the class hierarchy is called hierarchy nesting or depth of inheritance tree (DIT).

 

Spec-India is Software Development Company that Offers Cost Effective Software Development, Mobile Software Application Development, Custom Software Development, ASP.Net Application Development, Legacy System Migration, Onsite Software Development and Application Support and Maintenance Services.


Source: ArticleTrader.com
Creative Commons License

Comments

No comments posted.

Add Comment

You do not have permission to comment. If you log in, you may be able to comment.

 Top Authors

 1 Stebee (3270)
 2 limalan88 (2920)
 3 alien82 (2756)
 4 kajuba (2508)
 5 sverdlow (1712)
 6 jamiehanson (1705)
 7 juliet (1691)
 8 MarkeD (1296)
 9 robertoms2003 (1296)
 10 AnthonyF (1244)
 11 articles (1205)
 12 artavia.seo (1148)
 13 spinxwebdesign (1119)
 14 gprather (1071)
 15 LouieLiu (1069)

 Distribution

Article Distribution

  
  Affiliate Program 2Checkout.com, Inc. is an authorized retailer of ArticleTrader.com

0.03s