original_string: private function getType(\ReflectionParameter $parameter, \ReflectionFunctionAbstract $function)
      {
          if (!$type = $parameter->getType()) {
              return;
          }
          $name = $type->getName();
          $lcName = strtolower($name);
  
          if ('self' !== $lcName && 'parent' !== $lcName) {
              return $name;
          }
          if (!$function instanceof \ReflectionMethod) {
              return;
          }
          if ('self' === $lcName) {
              return $function->getDeclaringClass()->name;
          }
          if ($parent = $function->getDeclaringClass()->getParentClass()) {
              return $parent->name;
          }
      }
code: private function getType(\ReflectionParameter $parameter, \ReflectionFunctionAbstract $function)
      {
          if (!$type = $parameter->getType()) {
              return;
          }
          $name = $type->getName();
          $lcName = strtolower($name);
  
          if ('self' !== $lcName && 'parent' !== $lcName) {
              return $name;
          }
          if (!$function instanceof \ReflectionMethod) {
              return;
          }
          if ('self' === $lcName) {
              return $function->getDeclaringClass()->name;
          }
          if ($parent = $function->getDeclaringClass()->getParentClass()) {
              return $parent->name;
          }
      }
code_tokens: private function getType ( \ ReflectionParameter $ parameter , \ ReflectionFunctionAbstract $ function ) { if ( ! $ type = $ parameter -> getType ( ) ) { return ; } $ name = $ type -> getName ( ) ; $ lcName = strtolower ( $ name ) ; if ( 'self' !== $ lcName && 'parent' !== $ lcName ) { return $ name ; } if ( ! $ function instanceof \ ReflectionMethod ) { return ; } if ( 'self' === $ lcName ) { return $ function -> getDeclaringClass ( ) -> name ; } if ( $ parent = $ function -> getDeclaringClass ( ) -> getParentClass ( ) ) { return $ parent -> name ; } }
docstring: Returns an associated type to the given parameter if available.
  
  @param \ReflectionParameter $parameter
  
  @return string|null
docstring_tokens: Returns an associated type to the given parameter if available .