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
Why do we need DMA? DMA is used to transfer the block of data directly among an external device and the main memory without the continuous intervention by the processor.

Knowledge Representation: To recap, now we have some characterizations of Artificial Intelligence, so  when an Artificial Intelligence problem arises, you will enable  to put i

Q. Show Network Topology in digital system? This deals with the geometrical arrangement of nodes (endpoints consisting of physical devices such as terminals, printers, PCs, and

Q. What is Synchronous message passing? In Synchronous message passing is executed on synchronous communication network.  In that case sender and receiver processes should be

Q. Explain about Deadlock Avoidance? To prevent deadlocks two kinds of techniques are used: 1) Static prevention:  It employs P and V operators in addition to Semaphores to

What are the various address Translation schemes? Explain which scheme is used in Internet? Translation from a computer's protocol address to a corresponding hardware address i

BIOS - Basic Input Output System, Power On Self Test (POST) and Loading Bootloader from the Hard disk drive Boot Sector is being completed by BIOS. It started the system for

This is a huge collection of computational algorithms ranging from elementary functions like sum, sine, cosine, and difficult arithmetic, to more sophisticated functions like matri

PRINCIPLES OF COMPOSITION The principles of composition are the way that the elements of composition are used to achieve a particular purpose. Some of the main principles of co

What is the advantage of caching in a web browser? Like other application browsers utilize a cache to enhance document access. The browser places a copy of all items it retriev