Пример #1
0
 public ATurkeyCock(IFly f, ICluck c, ISwimm s, IGo g)
 {
     _fly   = f;
     _cluck = c;
     _swimm = s;
     _go    = g;
 }
Пример #2
0
 public ADuck()
 {
     _fly   = new DucksFly();
     _quack = new DucksQuack();
     _swimm = new DucksSwimm();
     _go    = new DucksGo();
 }
Пример #3
0
 public ADuck(IFly f, IQuack q, ISwimm s, IGo g)
 {
     _fly   = f;
     _quack = q;
     _swimm = s;
     _go    = g;
 }
Пример #4
0
 /// <summary>
 /// Executes the batch returning 2 strongly typed result sets.
 /// </summary>
 /// <typeparam name="T1">Is the type of the Table1 in the result. Use dynamic or object type for dynamic result set.</typeparam>
 /// <typeparam name="T2">Is the type of the Table2 in the result. Use dynamic or object type for dynamic result set.</typeparam>
 /// <param name="prev">A predecessor object.</param>
 public static Result <T1, T2> Go <T1, T2>(this IGo prev)
 {
     return(PublicInvoker.Call <Result <T1, T2> >(Assembly.GetCallingAssembly(), (ca) =>
     {
         var connectable = Reader.GetConnectable(ca, (Chainer)prev);
         return Reader.LoadMany <T1, T2>(connectable);
     }));
 }
Пример #5
0
 /// <summary>
 /// Executes the batch asynchronously returning a dynamic result with all the result sets from the batch.
 /// </summary>
 /// <param name="onCompleted">Is a delegate method that is invoked when the asynchronous operation completes.</param>
 /// <param name="prev">A predecessor object.</param>
 public static Async GoAsync(this IGo prev, Action <Result> onCompleted = null)
 {
     return(PublicInvoker.Call <Async>(Assembly.GetCallingAssembly(), (ca) =>
     {
         var connectable = Reader.GetConnectable(ca, (Chainer)prev);
         connectable.OnAsyncCompleted = onCompleted;
         return Reader.LoadAllAsync(connectable);
     }));
 }
Пример #6
0
 /// <summary>
 /// Executes the batch returning a single strongly typed result set. The result can be fetched through the callback method.
 /// </summary>
 /// <typeparam name="T">Is the type of the enumerated row. Use dynamic or object type for dynamic result set. DataTable type is not supported.</typeparam>
 /// <param name="rowHandler">Is a delegate method that processes the row of a type T as an input.</param>
 /// <param name="prev">A predecessor object.</param>
 public static Result <T> Go <T>(this IGo prev, Action <T> rowHandler)
 {
     return(PublicInvoker.Call <Result <T> >(Assembly.GetCallingAssembly(), (ca) =>
     {
         var connectable = Reader.GetConnectable(ca, (Chainer)prev);
         var result = Reader.LoadTable <T>(connectable, rowHandler);
         return result;
     }));
 }
Пример #7
0
 /// <summary>
 /// Executes the batch asynchronously returning 9 strongly typed result sets.
 /// </summary>
 /// <typeparam name="T1">Is the type of the Table1 in the result. Use dynamic or object type for dynamic result set.</typeparam>
 /// <typeparam name="T2">Is the type of the Table2 in the result. Use dynamic or object type for dynamic result set.</typeparam>
 /// <typeparam name="T3">Is the type of the Table3 in the result. Use dynamic or object type for dynamic result set.</typeparam>
 /// <typeparam name="T4">Is the type of the Table4 in the result. Use dynamic or object type for dynamic result set.</typeparam>
 /// <typeparam name="T5">Is the type of the Table5 in the result. Use dynamic or object type for dynamic result set.</typeparam>
 /// <typeparam name="T6">Is the type of the Table6 in the result. Use dynamic or object type for dynamic result set.</typeparam>
 /// <typeparam name="T7">Is the type of the Table7 in the result. Use dynamic or object type for dynamic result set.</typeparam>
 /// <typeparam name="T8">Is the type of the Table8 in the result. Use dynamic or object type for dynamic result set.</typeparam>
 /// <typeparam name="T9">Is the type of the Table9 in the result. Use dynamic or object type for dynamic result set.</typeparam>
 /// <param name="onCompleted">Is a delegate method that is invoked when the asynchronous operation completes.</param>
 /// <param name="prev">A predecessor object.</param>
 public static Async <Result <T1, T2, T3, T4, T5, T6, T7, T8, T9> > GoAsync <T1, T2, T3, T4, T5, T6, T7, T8, T9>(
     this IGo prev, Action <Result <T1, T2, T3, T4, T5, T6, T7, T8, T9> > onCompleted = null)
 {
     return(PublicInvoker.Call <Async <Result <T1, T2, T3, T4, T5, T6, T7, T8, T9> > >(Assembly.GetCallingAssembly(), (ca) =>
     {
         var connectable = Reader.GetConnectable(ca, (Chainer)prev);
         connectable.OnAsyncCompleted = onCompleted;
         return Reader.LoadManyAsync <T1, T2, T3, T4, T5, T6, T7, T8, T9>(connectable);
     }));
 }
Пример #8
0
 /// <summary>
 /// Executes the batch asynchronously returning a single strongly typed result set.
 /// </summary>
 /// <typeparam name="T">Is the type of the result set. Use dynamic or object type for dynamic result set.</typeparam>
 /// <param name="onCompleted">Is a delegate method that is invoked when the asynchronous operation completes.</param>
 /// <param name="prev">A predecessor object.</param>
 public static Async <Result <T> > GoAsync <T>(this IGo prev, Action <Result <T> > onCompleted = null)
 {
     return(PublicInvoker.Call <Async <Result <T> > >(Assembly.GetCallingAssembly(), (ca) =>
     {
         var connectable = Reader.GetConnectable(ca, (Chainer)prev);
         connectable.OnAsyncCompleted = (dynamic)onCompleted;
         if (typeof(T) == typeof(DataTable))
         {
             return Reader.LoadDataTableAsync <T>(connectable);
         }
         else
         {
             return Reader.LoadTableAsync <T>(connectable, null);
         }
     }));
 }
Пример #9
0
        /// <summary>
        /// Opens the testing environment window. When closed the execution proceeds. The testing does not affect the data state of the execution.
        /// </summary>
        /// <param name="prev">A predecessor object.</param>
        /// <param name="title">A title that will appear in the window.</param>
        /// <param name="option">An option that specifies whether the testing environment window should open, should open and execute, or should be skipped.</param>
        public static Connectable Test(this IGo prev, string title, TestingOption option = TestingOption.OpenAndExecute)
        {
            return(PublicInvoker.Call <Connectable>(Assembly.GetCallingAssembly(), (ca) =>
            {
                var connectable = Reader.GetConnectable(ca, (Chainer)prev);
                if (!Admin.IsTestingEnvironmentOff(ca) && option != TestingOption.Skip)
                {
                    using (var form = new TestingForm(connectable, option, title))
                    {
                        form.ShowDialog();
                    }
                }

                return connectable;
            }));
        }
Пример #10
0
        /// <summary>
        /// Executes the batch returning a single strongly typed result set.
        /// </summary>
        /// <typeparam name="T">Is the type of the result set. Use dynamic or object type for dynamic result set.</typeparam>
        /// <param name="prev">A predecessor object.</param>
        public static Result <T> Go <T>(this IGo prev)
        {
            return(PublicInvoker.Call <Result <T> >(Assembly.GetCallingAssembly(), (ca) =>
            {
                var connectable = Reader.GetConnectable(ca, (Chainer)prev);
                Result <T> result;

                if (typeof(T) == typeof(DataTable))
                {
                    result = Reader.LoadDataTable <T>(connectable);
                }
                else
                {
                    result = Reader.LoadTable <T>(connectable, null);
                }

                return result;
            }));
        }
Пример #11
0
 public DbCHeck(IGo dbCheck_)
 {
     this._go = dbCheck_;
 }
Пример #12
0
 public ATurkeyCock(IGo g)
 {
     _go = g;
 }
Пример #13
0
 public ADuck(IGo g)
 {
     _go = g;
 }
Пример #14
0
 public Competition(IGo member)
 {
     Member = member;
 }
Пример #15
0
 public SuperHeroAdapter(IFly fly, IShoot shoot, IGo go)
 {
     _fly   = fly;
     _shoot = shoot;
     _go    = go;
 }