add create_line method