Monday, 16 December 2013

Personal 7

memory leak.

Unreachable memory in the memory foot print when not released is memory leak.
when destruction of objects are not done which is constructed results in memory leak.
when de-allocation of memory is not done memory leaks. 

Personal 6


mutex 

mutually exclusive.

mutually   ---  commonly used.
exclusive  ---  not allowing other.

mutually exclusive   --- commonly used resource accessed excluding other threads.

lock resource
access resource
once complete
unlock resource.

the above is mutex access to resource, if the resource is application then single application
instance is created and handled ,and another instance is not allowed through mutex.
this is single instance of APPLICATION

Namespace

to avoid naming collision namespace used.
using namespace one
{
class-method1
class2-method2
}
using namespace two
{
class-method1
class2-method2
}

accessing same methods from 2 namespaces which have same name.

one::class->method1;
two::class->method1;

Personal 5

node class

data structure has nodes.
examples of data structure is list , map, tree etc.
the representation of nodes of data structure is through classes in oop.
such classes is known by name node class.

Personal 4

orthogonal base class

2 base classes which have no overlapping methods are inherited without difficulty 
by derived class then the 2 base classes are independent to each other and known as
orthogonal base class.

class1- save method                     |   class2 - save method


in the above classes both have save method does different saving, in such case derived
class has  overlapping methods so they are not orthogonal base class.

Personal 3

class invariant

this has property which is always true irrespective of other code in the program
invariant meaning which remains unchanged.
make the instance of the class final then the non inheritable character of that 
instance of the class is class invariant

Sunday, 15 December 2013

Personal 2

stack unwinding.

the constr creates momory allocation for type in this case for stack allocation.the memory allocated is destroyed with in block scope.even if exception occurs the complete memory allocated is unwound from stack,in reverse order of memory allocated because stack lifo.