refactoring all cast message code to separate cast class