Exemple #1
0
 /// <summary>
 /// Constructs an instance.
 /// </summary>
 /// <param name="owner">owning design object</param>
 /// <param name="events">events to combine</param>
 internal MultiEvent(DesignObject owner, IEnumerable <EventSource> events) :
     base(owner)
 {
     Owner    = owner;
     _events  = events;
     _awaiter = new Awaiter(this);
 }
Exemple #2
0
        /// <summary>
        /// Constructs an instance.
        /// </summary>
        /// <param name="owner">owning design object</param>
        /// <param name="evt">associated base event</param>
        /// <param name="pred">predicate function</param>
        internal PredicatedEvent(DesignObject owner, EventSource evt, Func <bool> pred,
                                 Expression description) :
            base(owner)
        {
            Contract.Requires <ArgumentNullException>(evt != null, "evt");
            Contract.Requires <ArgumentNullException>(pred != null, "pred");
            Contract.Requires <ArgumentNullException>(description != null, "description");

            Owner        = owner;
            _baseEvent   = evt;
            _pred        = pred;
            _awaiter     = new Awaiter(this);
            _description = description;
        }
Exemple #3
0
 /// <summary>
 /// Constructs an instance
 /// </summary>
 /// <param name="owner">owning design object</param>
 public EventSource(DesignObject owner)
 {
     Owner = owner;
 }
Exemple #4
0
 /// <summary>
 /// Constructs an instance.
 /// </summary>
 /// <param name="owner">owning design object</param>
 public Event(DesignObject owner) :
     base(owner)
 {
     _awaiter = new Awaiter(this);
 }