replaced getters and setters with attr_accessor.