docstr: A class that represents a result of the query operation.
  
  Args:
  
  graph:
      The graph on which the query was executed.
  response:
      The response from the server.
  profile:
      A boolean indicating if the query command was "GRAPH.PROFILE"
docstr_tok: ["A","class","that","represents","a","result","of","the","query","operation",".","Args",":","graph",":","The","graph","on","which","the","query","was","executed",".","response",":","The","response","from","the","server",".","profile",":","A","boolean","indicating","if","the","query","command","was","``","GRAPH.PROFILE","''"]
code: def __init__(self, graph, response, profile=False):
      """
      A class that represents a result of the query operation.
  
      Args:
  
      graph:
          The graph on which the query was executed.
      response:
          The response from the server.
      profile:
          A boolean indicating if the query command was "GRAPH.PROFILE"
      """
      self.graph = graph
      self.header = []
      self.result_set = []
  
      # in case of an error an exception will be raised
      self._check_for_errors(response)
  
      if len(response) == 1:
          self.parse_statistics(response[0])
      elif profile:
          self.parse_profile(response)
      else:
          # start by parsing statistics, matches the one we have
          self.parse_statistics(response[-1])  # Last element.
          self.parse_results(response)
  
imports: import sys
  from collections import OrderedDict
  import setuptools
  from distutils.util import strtobool
  from redis import ResponseError
  from .edge import Edge
  from .exceptions import VersionMismatchException
  from .node import Node
  from .path import Path
label_desc: Use image node_id 1 to create a new QueryResult object  with example: obj = QueryResult(graph, response, profile)