code: private function doesFragmentConditionMatch(
          $fragment,
          ObjectType $type
      ) {
          $typeConditionNode = $fragment->typeCondition;
          if ($typeConditionNode === null) {
              return true;
          }
          $conditionalType = TypeInfo::typeFromAST($this->exeContext->schema, $typeConditionNode);
          if ($conditionalType === $type) {
              return true;
          }
          if ($conditionalType instanceof AbstractType) {
              return $this->exeContext->schema->isPossibleType($conditionalType, $type);
          }
  
          return false;
      }
docs: Determines if a fragment is applicable to the given type.
  
  @param FragmentDefinitionNode|InlineFragmentNode $fragment
  
  @return bool