Esempio n. 1
0
        Action RenderOnce(Action action)
        {
            var    context = new RenderOnlyOnce();
            Action ret     = () =>
            {
                if (false == context.AlreadyCalled)
                {
                    action();
                    context.AlreadyCalled = true;
                }
            };

            return(ret);
        }
Esempio n. 2
0
        Action RenderOnce(Action action)
        {
            var context = new RenderOnlyOnce();
            Action ret = () =>
            {
                if (false == context.AlreadyCalled)
                {
                    action();
                    context.AlreadyCalled = true;
                }
            };

            return ret;
        }