Nette factory interface generator
This plugin allows you to quickly generate factory interface for your components and other classes.
Installation and requirements
This plugin is written for PhpStorm 10 and above and is compiled for Java 8. You can find it in the Jetbrains plugin repository. Install it from Preferences → Plugins → Browse repositories... and search for it.
With cursor anywhere in a PHP class, press Alt + Enter to open the intentions selection. Choose "Generate service factory interface".
A dialog will pop up allowing you to change the name of the factory interface and pick which constructor parameters should be enumerated in the factory's
A new PHP file will then be created in the same directory, based on your
PHP File file template. It will contain the factory interface, residing in the same namespace as the original class.
- Added checkbox to control whether to open the generated factory in the editor (see #4)
- Fixed EOF newline bug with CRLF (see #3)
- Fixed compatibility with 2017.1 (see #2)
- Fixed misplacement of phpdoc for PHP < 7.0 (#1)
- Generated code follows project's indentation and newline settings