Exemplo n.º 1
0
        public static CoroutineBuilder Build(this ICoroutineProcessor processor, Action logic)
        {
            var result = new CoroutineBuilder(processor);

            result.Then(logic);

            return(result);
        }
Exemplo n.º 2
0
        public static CoroutineBuilder Build <TContext>(this ICoroutineProcessor processor, Action logic,
                                                        TContext context = null) where TContext : class, new()
        {
            if (context == null)
            {
                context = new TContext();
            }

            var result = new CoroutineBuilder <TContext>(processor, context);

            result.Then(logic);

            return(result);
        }