added copy protection to classes