Articles → .NET DESIGN PATTERN → Open Close Principle In C#
Open Close Principle In C#
What Does The Open-Close Principle Say?
Open-Close Principle In C#
Example
public class DBOperations
{
public void Delete()
{ }
public void Upsert(object entity)
{ }
public List<object> GetAll()
{
return new List<object>();
}
}
public class DBOperations
{
public void Delete()
{ }
public void Upsert(object entity)
{ }
public List<object> GetAll()
{
return new List<object>();
}
}
public class DBOperationsExt : DBOperations
{
public void ExecuteStoredProcedure(string storedProcName, ....)
{ }
}