• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

nette / utils / 39638515326

21 Oct 2026 04:50PM UTC coverage: 92.495% (-0.06%) from 92.551%
39638515326

push

github

dg
added support for PHP 8.6

1 of 1 new or added line in 1 file covered. (100.0%)

114 existing lines in 17 files now uncovered.

1861 of 2012 relevant lines covered (92.5%)

0.92 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

85.71
/src/Utils/ReflectionMethod.php
1
<?php declare(strict_types=1);
2

3
/**
4
 * This file is part of the Nette Framework (https://nette.org)
5
 * Copyright (c) 2004 David Grudl (https://davidgrudl.com)
6
 */
7

8
namespace Nette\Utils;
9

10
use function is_string;
11

12

13
/**
14
 * ReflectionMethod preserving the original class name.
15
 * @internal
16
 */
17
final class ReflectionMethod extends \ReflectionMethod
18
{
19
        private \ReflectionClass $originalClass;
20

21

22
        public function __construct(object|string $objectOrMethod, ?string $method = null)
23
        {
24
                if (is_string($objectOrMethod) && str_contains($objectOrMethod, '::')) {
1 ✔
UNCOV
25
                        [$objectOrMethod, $method] = explode('::', $objectOrMethod, 2);
×
26
                }
27
                parent::__construct($objectOrMethod, $method);
1 ✔
28
                $this->originalClass = new \ReflectionClass($objectOrMethod);
1 ✔
29
        }
1 ✔
30

31

32
        public function getOriginalClass(): \ReflectionClass
33
        {
34
                return $this->originalClass;
1 ✔
35
        }
36
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc