added the copy constructor