provide a close method