예제 #1
0
        static void Main(string[] args)
        {
            RefinedAbstraction refinedAbstraction = new RefinedAbstraction();

            Implementor implementorA = new ImplementorA();

            refinedAbstraction.Implementor = implementorA;
            refinedAbstraction.Operation();

            Implementor implementorB = new ImplementorB();

            refinedAbstraction.Implementor = implementorB;
            refinedAbstraction.Operation();
        }
예제 #2
0
        static void Main(string[] args)
        {
            Implementor a = new ImplementorA();
            Implementor b = new ImplementorB();

            Bridger m = new MyBridger(a);

            m.operation();

            Bridger n = new MyBridger(b);

            n.operation();

            Console.ReadKey();
        }