static void Main(string[] args) { //abstract factory design pattern TestAbstractFactory tbf = new TestAbstractFactory(); tbf.Run(); //factory method design pattern TestFactoryMethod tfm = new TestFactoryMethod(); tfm.Run(); //Singleton design pattern TestSingleton ts = new TestSingleton(); ts.Run(); TestOptimizedSingleton tos = new TestOptimizedSingleton(); tos.Run(); //Bridge design pattern TestBridge tb = new TestBridge(); tb.Run(); }
static void Main(string[] args) { TestAbstractFactory testAbstractFactory = new TestAbstractFactory(); testAbstractFactory.Test(); TestContinentFactory testContinentFactory = new TestContinentFactory(); testContinentFactory.Test(); BuilderTest builderTest = new BuilderTest(); builderTest.Test(); ShopTest shopTest = new ShopTest(); shopTest.Test(); FactoryTest factoryTest = new FactoryTest(); factoryTest.Test(); PageFactoryTest pageFactoryTest = new PageFactoryTest(); pageFactoryTest.Test(); PrototypeTest prototypeTest = new PrototypeTest(); prototypeTest.Test(); ColorPrototypeTest colorPrototypeTest = new ColorPrototypeTest(); colorPrototypeTest.Test(); SingletonTest singletonTest = new SingletonTest(); singletonTest.Test(); LoadBalancerTest loadBalancerTest = new LoadBalancerTest(); loadBalancerTest.Test(); AdapterTest adapterTest = new AdapterTest(); adapterTest.Test(); CompoundTest compoundTest = new CompoundTest(); compoundTest.Test(); BridgeTest bridgeTest = new BridgeTest(); bridgeTest.Test(); CustomersTest customersTest = new CustomersTest(); customersTest.Test(); ComponentTest componentTest = new ComponentTest(); componentTest.Test(); DrawingElementTest drawingElementTest = new DrawingElementTest(); drawingElementTest.Test(); AbstractComponentTest abstractComponentTest = new AbstractComponentTest(); abstractComponentTest.Test(); LibraryItemTest libraryItemTest = new LibraryItemTest(); libraryItemTest.Test(); FacadeTest facadeTest = new FacadeTest(); facadeTest.Test(); MortgageTest mortgageTest = new MortgageTest(); mortgageTest.Test(); FlyweightFactoryTest flyweightFactoryTest = new FlyweightFactoryTest(); flyweightFactoryTest.Test(); HandlerTest handlerTest = new HandlerTest(); handlerTest.Test(); ApproverTest approverTest = new ApproverTest(); approverTest.Test(); CommandTest commandTest = new CommandTest(); commandTest.Test(); UserTest userTest = new UserTest(); userTest.Test(); Console.ReadKey(); }
private void button14_Click(object sender, EventArgs e) { TestAbstractFactory.Testar(); }