Tuesday, May 24, 2011

Software Development Models

In Software Development process we have different models to adopt to complete the Project and sometimes combination of Development process also used in Development process.

We Have Basic Knowledge on Software Development Cycle 

if we adopt one process it makes easy to develop  Projects.

We Have Four Types Of Development Processes
They are

1.Water Fall Model
2.Spiral Model
3.Iterative and Incremental Development
4.Agile Development

Tuesday, May 10, 2011

Simple Linq To Sql Example

How to Use Linq to sql in dotnet ?

--Take the Class with same name of Database
--Than Inherit With Class DotContext
--For This Class u have to add Linq ,data,Mapping references to project

--Using System.Linq.Data;
--Using System.Linq.Data.Mppaing
Ex:

public class Mydatabase() :DotContext
{

}

Monday, May 9, 2011

Differecne Between Interfaces and Abstract ?

Differences between Interface and Abstract Class?
Interfaces :
--An interface is not a class.
--It is an entity that is defined by the word Interface.
--An interface has no implementation;
--it only has the signature or in other words, just the definition of the methods without the body. As one of the similarities to Abstract class
 ____________________________________
Public Interface ImyInterface

{
String Method1();
int Method2();

}
Public Class myClass :ImyInterface
{
string Method1()
{
//Code
}
int Method2()
{
//Code
}
}
____________________________________________________________________________
---Requires more time to find the actual method in the corresponding classes. (Slow )


The main difference between them is that a class can implement more than one interface but can only inherit from one abstract class. Since C# doesn't support multiple inheritance, interfaces are used to implement multiple inheritance

  Abstract Class:
   These Classes Cannot be instantiated, 
 ---These are used if additional functionality is needed in derived classes,
 ---These Implemented partially or No Implementation
--Fast In Operation
 ____________________________________________________________
abstract class MyAbstractClass
{
public MyAbstractClass()
{
// Code to initialize the class goes here.
}

abstract public void Method1();
abstract public void Method2(int A);
abstract public long Method3(int B);
}
class MyClass : MyAbstractClass
{
public MyClass ()
{
// Initialization code goes here.
}

override public void Method1()
{
// code goes here.
}

override public void Method2(int A)
{
// code goes here.
}

override public long Method3(int B)
{
//code goes here.
}
}