Façade Pattern Code Review
Use the Façade Pattern
Code Review
- Façade Pattern Code Review: Define the Façade Object
- Façade Pattern Code Review: Define the SubSystem Objects
- Façade Pattern Code Review: Use the Façade Pattern
Code Walkthrough
The Program class creates an instance of the Façade class (object) and invokes the IsEligible() method.
class Program
{
static void Main(string[] args)
{
String customerID = "ABN000726351";
Facade systemFacade = new Facade();
Boolean eligible = systemFacade.IsEligible(customerID, 120000);
Console.WriteLine(String.Format("\n{0} has been {1}.", customerID, (eligible ? "Approved" : "Rejected")));
Console.Read(); } }
Facade systemFacade = new Facade();
Boolean eligible = systemFacade.IsEligible(customerID, 120000);
Console.WriteLine(String.Format("\n{0} has been {1}.", customerID, (eligible ? "Approved" : "Rejected")));
Console.Read(); } }
Printer Friendly Version
Add to Favourites
DotNet Kicks
Digg
del.icio.us
Live Favourites
ma.gnolia
reddit
Slashdot
Technorati
Yahoo!