added ROEncoder class