Added wrap and end methods. Modified cat method.