adds Ruby compatible mode to version 2
refactor method names to fit to new structure