added several class definitions and wrote message creation method