Ejemplo n.º 1
0
        protected DataIncrementingEventArgs OnIncrementing(string name, string member, ICondition condition, int interval = 1, bool cancel = false)
        {
            var args = new DataIncrementingEventArgs(name, member, condition, interval, cancel);

            this.OnIncrementing(args);
            return(args);
        }
Ejemplo n.º 2
0
        protected virtual void OnIncrementing(DataIncrementingEventArgs args)
        {
            var e = this.Incrementing;

            if (e != null)
            {
                e(this, args);
            }
        }
Ejemplo n.º 3
0
        protected virtual bool OnIncrementing(DataIncrementContext context)
        {
            var e = this.Incrementing;

            if (e == null)
            {
                return(false);
            }

            var args = new DataIncrementingEventArgs(context);

            e(this, args);
            return(args.Cancel);
        }