adding __toString, next and previous methods