What is class invariant in c++, Computer Engineering

A class invariant is a condition that describes all valid states for an object. It is a logical condition to make sure the correct working of a class. Class invariants must hold when an object is formed, and they must be preserved under all operations of the class. In particular all class invariants are both preconditions and post-conditions for all operations or member functions of the class.

 

 

Posted Date: 4/8/2013 3:36:31 AM | Location : United States







Related Discussions:- What is class invariant in c++, Assignment Help, Ask Question on What is class invariant in c++, Get Answer, Expert's Help, What is class invariant in c++ Discussions

Write discussion on What is class invariant in c++
Your posts are moderated
Related Questions
What are the restrictions of traditional payment instruments? How are such restrictions overcome by electronic payment systems? The restrictions of traditional payment system a

Question: (a) Describe the importance of Micro-Programming and point out one area where Micro-Programming is extensively used. (b) Below is a diagram of an 8086 processor.

What are the techniques of Data Collection It can be either automatic or manual. Manual techniques can include: -  Keypads/Keyboards to type in data -  touch screens to s

Communication by devices, such as the HC11 processor, is a key and vital part of most systems that are used in military, commercial, and academic settings.  In fact, most of these

Define service (within R/3)? A service is a process or group of processes that perform a exact system function and often give an application-programming interface for other pr

What is logical address space and physical address space? The set of all logical addresses generated by a program is known as a logical address space; the set of all physical a

Briefly analyse and compare the two website designs, applying in turn each of the six design principles. This will result in six brief paragraphs. As part of each analysis, expl

write a short note on good blend of engineering and managerial economics

What is a shell? A shell is an interactive user interface to an operating system services that permits an user to enter commands as character strings or by a graphical user int

Algorithm to insert a key in B-tree is as follows: 1.  First search is completed for the place where the new record must be put. As the keys are inserted, they are sorted into