class_docstr: The super class for all nodes.
  A node has children, a type and possibly a parent node.
class_docstr_tok: ["The","super","class","for","all","nodes",".","A","node","has","children",",","a","type","and","possibly","a","parent","node","."]
docstr: Get the :py:class:`parso.tree.Leaf` at ``position``
  
  :param tuple position: A position tuple, row, column. Rows start from 1
  :param bool include_prefixes: If ``False``, ``None`` will be returned if ``position`` falls
      on whitespace or comments before a leaf
  :return: :py:class:`parso.tree.Leaf` at ``position``, or ``None``
code: def get_leaf_for_position(self, position, include_prefixes=False):
      """
      Get the :py:class:`parso.tree.Leaf` at ``position``
  
      :param tuple position: A position tuple, row, column. Rows start from 1
      :param bool include_prefixes: If ``False``, ``None`` will be returned if ``position`` falls
          on whitespace or comments before a leaf
      :return: :py:class:`parso.tree.Leaf` at ``position``, or ``None``
      """
  
      def binary_search(lower, upper):
          if lower == upper:
              element = self.children[lower]
              if not include_prefixes and position < element.start_pos:
                  # We're on a prefix.
                  return None
              # In case we have prefixes, a leaf always matches
              try:
                  return element.get_leaf_for_position(
                      position, include_prefixes
                  )
              except AttributeError:
                  return element
  
          index = int((lower + upper) / 2)
          element = self.children[index]
          if position <= element.end_pos:
              return binary_search(lower, index)
          else:
              return binary_search(index + 1, upper)
  
      if not ((1, 0) <= position <= self.children[-1].end_pos):
          raise ValueError(
              "Please provide a position that exists within this node."
          )
      return binary_search(0, len(self.children) - 1)
  
imports: from abc import abstractmethod, abstractproperty
  from typing import List, Optional, Tuple, Union
  from parso.utils import split_lines
label_desc: Use image node_id 7 for calling the BaseNode obj's underlying member method code with example usage: obj.get_leaf_for_position(position, include_prefixes) and returns: binary_search, binary_search, binary_search, None, element, element