Refactor event

resolves #11, #16, #17 and #18 by adding a new event type EventWithApplication.  had to split event into subclasses to achieve that. 

resolves #25