set most members  private and added getters