Esempio n. 1
0
        public void ThrowIfPublishingBroken(Event e)
        {
            var check = new EventCheckBeforePublish(e);
            var isOk  = e.IsPublished && check.IsReadyForPublish;

            if (!isOk)
            {
                throw new EventIsNotPublishedException(check);
            }
        }
Esempio n. 2
0
 public EventIsNotPublishedException(EventCheckBeforePublish eventCheck) : base("Can not publish!")
 {
     this._eventCheck = eventCheck;
 }