using System;
Kalpesh Patolia's Blog
Sharing my knowledge, experience using this Blog on various Microsoft Technologies like WPF, C#, XAML, LINQ, WCF, ASP.Net, And database like SQL Server, Oracle And ORM technologies like NHibernate.
Tuesday, 12 April 2022
Custome Service Class to connect wcf service
Thursday, 26 August 2021
Repository Pattern
Repository pattern is one of the Data Access Pattern, which is used to access the data from database or other data source. A repository pattern encapsulates the data access so the consumer no longer has to know about the underlying data structure.
Problem that repository pattern solves
- The controller / UI is tightly coupled with data access layer , if we are using data access from controller / UI.
- It is difficult to write a test for the controller / UI without side effects
- Hard to extends entities with domain specific behaviour.
Benefits of repository pattern
- The consumer is now separated (decoupled) from the data access
- Easy to write a test without side-effects.
- Modify and extend entities before they are passed on to the consumer.
- A sharable abstraction resulting in less duplication of code.
- Improved maintainability.
Sunday, 8 August 2021
Chain of Responsibility Pattern
Chain of Responsibility pattern comes under behavioral design patterns category, this pattern lets you pass requests along a chain of handlers. Upon receiving a request, each handler decides either to process the request or to pass it to the next handler in the chain.
Iterator Pattern
Iterator pattern comes under behavioral design patterns category, this pattern let you traverse elements of collection without exposing its underlying implementation. This pattern also known as Cursor.
Command Pattern
Command pattern comes under behavioral design patterns category, this pattern turns a request into a stand-alone object that contains all information about the request. A request is wrapped under an object as command and passed to invoker object. Invoker object looks for the appropriate object which can handle this command and passes the command to the corresponding object which executes the command.
Mediator Pattern
Mediator pattern comes under behavioral design patterns category, this pattern lets you reduce chaotic dependencies between objects. The pattern restricts direct communication between the objects and forces them to collaborate only via mediator object. Mediator pattern is used to reduce communication complexity between multiple objects or classes. This pattern provides a mediator class which normally handles all the communications between different classes and supports easy maintenance of the code by loose coupling.
Memento Pattern
Memento pattern comes under behavioral design patterns category, this pattern lets you save and restore the previous state of an object without revealing the details of its implementation.
Custome Service Class to connect wcf service
using System; using System.ServiceModel; namespace Custom.Service.Client { // Borrowed from: http://old.iserviceoriented.com/blog/p...
-
The Major components of WPF Architecture are Presentation Framework, Presentation Core and Media Integration Layer. The architecture divid...
-
As per standard development process we are hosting application after new Iteration (Aglie Methodology) or module development. For client t...
-
Our application loads a big cache of data from database when it starts. A DataReader is an option we have chossen to retrive the date, sinc...