document Query.traverse method