Tuesday, 17 November 2015

explanation of definition of ado.net

Ado means active data object and ado is replaced by ado.net .Ado.net is fully based on oops concept.
ADO.NET is a set of computer software components that programmers can use to access data and data services based on disconnected DataSets and XML. It is a part of the base class library that is included with the Microsoft .NET Framework. It is commonly used by programmers to access and modify data stored in relational database systems, though it can also access data in non-relational sources. ADO.NET is sometimes considered an active x data object.

Sunday, 1 November 2015

difference between interface and abstract class.

Difference between interface and abstract class

Interface provide pure abstract methods.
Abstract class provide concrete classes.

Interface provide multiple inheritance.
Abstract class don't provide multiple inheritance.

We cannot create object of interface, we create only reference variable of interface.
We create object of abstract class.

We cannot define data field within interface.
In abstract class we have to define data field. 

We cannot use any access specifier within interface.
We can use access specifier with abstract class.

Friday, 16 October 2015

difference between c++ and c#.


  • C++ support operator overloading.
  • C# does not support operator overloading.
  • C++ contains header files.
  • C# contains namespaces.
  • C++ support multiple inheritance.
  • C# does not support multiple inheritance because it support interface.

Saturday, 5 September 2015

static in c#.net

Static
static is a keyword that behaves like type modifier.
static works again oop and beyond the oops.
static member are guest for a class.
A static variable created only once in complete program whenever
class is invoked only when application is closed.
Example:-
class class1
{
public int a,b;
public static int c;
public static int count=0;
public class1()
{
count++
message box.show("convert.To string")
}






class1 ob1=new class();
class1.c=25;

upcasting,downcasting,boxing,unboxing

Up casting.

Conversion of child data type into parent data type is
known as up casting.

Downcasting.

Conversion of parent data type into child data type is
known as downcasting.

To execute downcasting process there is always need of
type casting method.

General syntax for downcasting.

(type)expression

ob2=(class2)ob1;

Boxing

Conversion of value type into object data type is known as boxing.

Object behave like a universal data type because of boxing.

Object obj;
obj="helow";
obj="7.5";

unboxing

conversion of object data type into value type is called unboxing.
To executing unboxing process we always need of type casting.

doubled=convert.to Double (obj);

Diference between structure and class.

Difference between structure and c lass.

structure1.variable of structure define as value type variable.

2.In case of structure compiler support static binding.

class

1.variable of class define as reference type variable.

In case of class compiler support dynamic binding.


Note=>in oops every class contain its own object or reference
or pointer in same class with name This.

This behave like owner of class.

Rules of oops

Rules of oops.

First rule=>

To access member of class from outside of class we have to create object of same class .

General syntax to create object of class.

class name object name=new class name();
class1 obj 1 = new class1();

class name object name();

Example=>

class1 customer 1;
customer cusID=new customer;

class class1
private int a,b;
public int c;
public void set data1()
{
a=5;b=7;c=9;
}
public void set data2 (int x,int y,int z)
{
a=x;
b=y;
c=z;
}
public void set data3(int a,int b,int c);
{
a=a;
b=b;
c=c;
}
second rule=>


Every object have three separate memory blocks.

class1 ob 1=new class1();
obj1.a=25;

class1 ob 2= new class1();
ob 2.b=5;
ob 2.set data z(10,20,30);

class1 ob 3=new class1();
ob 3.set data 3(100,200,300);