Releases: nette/php-generator
Releases · nette/php-generator
Released version 4.1.7
- added support for PHP 8.4 features
- properties hooks
- asymmetric visibility
- property can be abstract / final
- interfaces can have properties
- added Visibility
ClassManipulator::implement()
can implement abstract classesClassManipulator::implementInterface()
renamed toimplement()
- PsrPrinter is not final
- Constant: type can be nullable
- Factory: fixed visibility of promoted property
Released version 4.0.10 (EOL)
Extractor::extractAll()
fixed file comment parsing- Factory: $withBodies cannot be used for internal classes/functions
- Printer: fixed falsy Attribute aren't printed (#142)
- added Visibility
Released version 4.1.6
- added ClassManipulator
- Parameter & Property:
isNullable()
returns true when default value is null (possible BC break) - added TraitsAware::hasTrait method (#163)
- support for PHP 8.4
Released version 4.1.5
- added
PhpNamespace::getClass()
&getFunction()
- added
CommentAware::removeComment()
- added
PhpFile::removeNamespace()
- Factory, Extractor: sets flag readonly for promoted properties #158 (reverts "Factory: properties in readonly classes are not readonly")
- ClassType: cloning includes attributes and parameters
- GlobalFunction, Method:
from()
accepts first-class callables
Released version 4.1.4
- PsrPrinter: opening bracket on the correct line #155
- Make
ClassLike::from
return type assert the subclass type (BC break) (#154) Dumper::dumpArray()
,dumpArguments()
optimization- Dumper: simplified list with negative keys
- added parameter $overwrite to
addMember()
,addMethod()
,addProperty()
,addConstant()
,addCase()
#152 - Factory: parameters 'int $foo = null' are parsed as '?int'
Released version 4.1.3
- Extractor: supports PHP-Parser 5.0 (#150)
- Extractor: fix escaping quotes when converting to double quoted string #151
- Extractor: NOWDOC/HEREDOC are not converted to single line strings
- Dumper: added $customObjects
- Dumper: refactoring, added
dumpCustomObject()
- Printer: option $omitEmptyNamespaces is applied by
printFile()
[Close #147]
Released version 4.1.2
Released version 4.1.1
- ClassType: added
inheritMethod()
&inheritProperty()
- Printer: added option $omitEmptyNamespaces
- added
ConstantsAware::getConstant()
Extractor::extractAll()
extracts only top-level classes and functions, fixed file comment parsing- Extractor: extracts native PHP values
- ClassType:
getType()
is deprecated - Printer: fixed falsy Attribute aren't printed (#142)
Released version 4.1.0
- ClassType::class(), interface(), traits() & enum() are deprecated
- removed Nette\SmartObject
- removed deprecated stuff