implementing Event class