refactored Decorator helper to better use prototype inheritance and mixins