Moved public method definitions into return statement
Added setter methods
- fixes #242