code: public function getContext($name)
      {
          if (is_array($this->contexts)) {
              foreach ($this->contexts as $context) {
                  if ($context->getName() == $name) {
                      return $context;
                  }
              }
          }
      }
docs: Convenience method to get a Dialogflow context by name.
  Reference: https://dialogflow.com/docs/contexts.
  
  @param string $name context name
  
  @return null|Context