setter created to print object attributes