Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

See inherited documentation in PHPStorm

Tags:

ide

phpstorm

I usually put the documentation in the interface if I can:

interface SenderInterface
{
    /**
     * Sends Email to user
     *
     * @param UserInterface $receiver
     * @param string $msg
     */
    public function sendEmail(UserInterface $receiver, $msg)
    //...
    {

I then inherit the doc like this to avoid redundancy.

class Sender implements SenderInterface
{
    /**
     * {@inheritDoc}
     */
    public function sendEmail(UserInterface $receiver, $msg)
    //...
    {

Is there a way to see the inherited doc directly into the Sender class without having to open the SenderInterface in PHPStorm?

like image 711
Mick Avatar asked Feb 13 '13 04:02

Mick


1 Answers

The upcoming PhpStorm v6 has much better support of {@inheritDoc} (in comparison to v5 and earlier).

The functionality you require is already working fine in EAP build (Early Access Program) -- you can try it yourself from here: http://confluence.jetbrains.net/display/WI/Web+IDE+EAP

Command to view documentation is View | Quick Documentation (Ctrl+Q .. or whatever shortcut you may have there)

like image 102
LazyOne Avatar answered Oct 19 '22 09:10

LazyOne