nette-intellij / intellij-nette

Nette support in PhpStorm - Develop Nette with pleasure
http://plugins.jetbrains.com/plugin?pluginId=7231
75 stars 6 forks source link

Support for Factory methods #28

Open dg opened 6 years ago

dg commented 6 years ago

Is possible to add .phpstorm.meta.php file into plugin? It is decribed here https://confluence.jetbrains.com/display/PhpStorm/PhpStorm+Advanced+Metadata#PhpStormAdvancedMetadata-Packagingmetadata/stubfilesintoplugin

Content of file:

<?php

namespace PHPSTORM_META {

    override(
        \Nette\DI\Container::getService(0),
        map( [
            'application' => \Nette\Application\Application::class,
        ])
    );

    override(
        \Nette\DI\Container::getByType(0),
        map([
            '' => '@',
        ])
    );

    override(\Nette\Utils\Arrays::get(0), elementType(0));
    override(\Nette\Utils\Arrays::getRef(0), elementType(0));
    override(\Nette\Utils\Arrays::grep(0), type(0));
}