returns a pretty printed object as a string.