Example #1
0
        public static void Run()
        {
            Bderived   b = new Bderived();
            ABase      a = b;
            Iinterface i = b;

            a.hello();
            b.hello();
            i.hello();
        }
Example #2
0
 override public IProcessor Create(ABase a)
 {
     // this is ugly for a large amount of ABase implementations of course
     if (a is A1)
     {
         return(new Runtime1());
     }
     if (a is A2)
     {
         return(new Runtime2());
     }
     throw new NotSupportedException();
 }
Example #3
0
        public void AddAnswerToAnAnswerSheet()
        {
            AnswerSheet s = SetupSheet();
            QBinary     q = s.Form.Questions.AddANewQuestion <QBinary>("Est-ce que c'est bon ?", true);
            ABase       a = s.CreateAnswerFor(q);

            Assert.IsNotNull(a);
            Assert.IsInstanceOf(typeof(ABinary), a);

            ABinary b = (ABinary)a;

            b.Answer = true;
        }
Example #4
0
 public void Valid(ABase answer)
 {
     Console.WriteLine("I'm BASE");
 }
Example #5
0
 public abstract IProcessor Create(ABase a);
Example #6
0
 public void ProcessA(ABase a)
 {
     // process away differently
 }
Example #7
0
 public void ProcessA(ABase a)
 {
     // process away
 }