Adding a copy method and equal comparison method.