public function getBody()
    {
        if ($this->isAbstract() === true) {
            throw new RuntimeException('Can not get body of an abstract method');
        }

        $fileName = $this->getDeclaringClass()->getFileName();
        if ($fileName === false) {
            throw new RuntimeException('Can not get body of a method belonging to an internal class.');
        }

        $lines = file($fileName, FILE_IGNORE_NEW_LINES);
        $lines = array_slice($lines, $this->getStartLine() - 1, ($this->getEndLine() - $this->getStartLine() + 1),
            true);
        $lines = implode("\n", $lines);

        $firstBracketPos = strpos($lines, '{');
        $lastBracketPost = strrpos($lines, '}');
        $body = substr($lines, $firstBracketPos + 1, $lastBracketPost - $firstBracketPos - 1);

        return trim(rtrim($body), "\n\r");
    }