Skip to content
This repository has been archived by the owner on Jan 16, 2019. It is now read-only.

Releases: stubbles/stubbles-core

5.3.0 - Go native

31 Dec 17:28
Compare
Choose a tag to compare

BC breaks

  • deprecated classes in stubbles\lang\reflect, use PHP's native reflection instead, will be removed with 6.0.0
    • stubbles\lang\reflect\BaseReflectionClass
    • stubbles\lang\reflect\MixedType
    • stubbles\lang\reflect\ReflectionClass
    • stubbles\lang\reflect\ReflectionExtension
    • stubbles\lang\reflect\ReflectionFunction
    • stubbles\lang\reflect\ReflectionMethod
    • stubbles\lang\reflect\ReflectionObject
    • stubbles\lang\reflect\ReflectionParameter
    • stubbles\lang\reflect\ReflectionPrimitive
    • stubbles\lang\reflect\ReflectionProperty
    • stubbles\lang\reflect\ReflectionRoutine
    • stubbles\lang\reflect\ReflectionType
    • stubbles\lang\reflect\matcher\MethodMatcher
    • stubbles\lang\reflect\matcher\PropertyMatcher
  • added stubbles\lang\reflect\annotationsOf() which allows to retrieve annotations without using the stubbles\lang\reflect\Reflection* classes
  • added stubbles\lang\reflect\annotationsOfConstructor() as shortcut
  • added stubbles\lang\reflect\annotationsOfParameter() as shortcut
  • added stubbles\lang\reflect\annotationsOfConstructorParameter() as shortcut
  • all typehints in ˚\stubbles\iocclasses which where againststubbles\lang\reflect\Reflection*` classes now use PHP standard reflection classes
  • deprecated stubbles\lang\typeFor(), will be removed with 6.0.0
  • deprecated stubbles\lang\reflect\annotation\Annotations::of(), use stubbles\lang\reflect\annotation\Annotations::named() instead, will be removed with 6.0.0

Other changes

  • added stubbles\lang\reflect\annotation\Annotations::firstNamed()
  • added stubbles\lang\reflect\methodsOf()
  • added stubbles\lang\reflect\propertiesOf()
  • added stubbles\lang\reflect\parametersOf()
  • added stubbles\lang\reflect\parametersOfConstructor()
  • added stubbles\lang\reflect\parameter()
  • added stubbles\lang\reflect\constructorParameter()
  • added stubbles\predicate\ContainsAnyOf
  • implemented #122: add support for ::class in value parser
  • added stubbles\lang\Sequence::mapKeys()
  • stubbles\lang\iterator\MappingIterator can now work with key mapping only

5.2.0 - The sequence of life

31 Dec 17:27
Compare
Choose a tag to compare
  • added stubbles\lang\Sequence
  • added stubbles\streams\linesOf()

5.1.2 - Here are some params for you

31 Dec 17:26
Compare
Choose a tag to compare
  • added stubbles\peer\Uri::addParams()

5.1.1 - Transposing ain't easy

31 Dec 17:26
Compare
Choose a tag to compare
  • fixed bug: transposing a parsed uri forgot any parameters changed in query string

5.1.0 - Repeat after me: setter injection is bad

31 Dec 17:25
Compare
Choose a tag to compare

BC breaks

  • Setter injection is now discouraged and disabled by default, and will be removed with 6.0.0.
    • Reenable the old behaviour with stubbles\ioc\Binder::enableSetterInjection()

Other changes

  • IoC now supports default param values for non-optional injections:
    If no binding present for a param but the param has a default value the
    default value will be used for injection.
  • implemented #117: injection stack on binding exceptions
  • improved performance of annotation parsing
  • improved annotation cache storage functions api
  • properties from config.ini are also now available as instance of stubbles\lang\Properties, named config.ini

5.0.1 - Learn how to catch

31 Dec 17:24
Compare
Choose a tag to compare
  • fixed issue #119: stubbles\peer\ParsedUri should catch IllegalArgumentException from stubbles\peer\QueryString

5.0.0 - There can be more than @one

31 Dec 17:23
Compare
Choose a tag to compare

BC breaks

  • Removed stubbles\ioc\App::createModeBindingModule($projectPath, $mode = null)
    • project path and mode are now bound automatically if not explicitly specified
    • to overrule or configure the defaults use stubbles\ioc\App::runtime($mode = null) instead
  • A __bindings() method within an app doesn't receive the project path any more. If it is still required call self::projectPath()
  • Deprecated stubbles\ioc\App::bindCurrentWorkingDirectory(), use stubbles\ioc\App::currentWorkingDirectory() instead, will be removed with 6.0.0
  • Deprecated stubbles\ioc\App::bindHostname(), use stubbles\ioc\App::hostname() instead, will be removed with 6.0.0
  • Removed possibility to change values on annotations, annotations should be read only.
  • It is now possible to have more than one annotation of the same type. Retrieving only one annotation via one of the following methods will only return the first defined one:
    • stubbles\lang\reflect\ReflectionClass::annotation()
    • stubbles\lang\reflect\ReflectionObject::annotation()
    • stubbles\lang\reflect\ReflectionFunction::annotation()
    • stubbles\lang\reflect\ReflectionMethod::annotation()
    • stubbles\lang\reflect\ReflectionParameter::annotation()
    • stubbles\lang\reflect\ReflectionProperty::annotation()
  • Deprecated stubbles\lang\reflect\Reflection*::getAnnotation(), use stubbles\lang\reflect\Reflection*::annotation() instead
  • Retrieving a non-existing value from stubbles\lang\reflect\annotation\Annotation via method will throw a BadMethodCallException instead of stubbles\lang\exception\MethodNotSupportedException
  • Parsing null with any of the stubbles\lang\Parse methods will now always return null.
  • Removed all classes, methods and functions deprecated with 4.0.0 and 4.1.0
  • The stubbles\lang\exception\IllegalAccessException is now also an instance of LogicException. It is recommended to use the latter in catch statements, as this increases interoperability.
  • The stubbles\lang\exception\IllegalArgumentException is now also an instance of InvalidArgumentException. It is recommended to use the latter in catch statements, as this increases interoperability.
  • The stubbles\lang\exception\IllegalStateException is now also an instance of LogicException. It is recommended to use the latter in catch statements, as this increases interoperability.
  • The stubbles\lang\exception\MethodInvocationException is now also an instance of BadMethodCallException. It is recommended to use the latter in catch statements, as this increases interoperability.
  • The stubbles\lang\exception\MethodNotSupportedException is now also an instance of BadMethodCallException. It is recommended to use the latter in catch statements, as this increases interoperability.
  • Deprecated several exceptions where build-in exceptions in PHP exist, will be removed with 6.0.0:
    • stubbles\lang\exception\IllegalAccessException, use LogicException instead
    • stubbles\lang\exception\IllegalArgumentException, use InvalidArgumentException instead
    • stubbles\lang\exception\IllegalStateException, use LogicException instead
    • stubbles\lang\exception\MethodInvocationException, use BadMethodCallException instead
    • stubbles\lang\exception\MethodNotSupportedException, use BadMethodCallException instead
    • stubbles\lang\exception\RuntimeException, use native RuntimeException instead
  • Deprecated stubbles\lang\exception\Throwable, will be removed with 6.0.0

Other changes

  • Added possibility to retrieve all annotations for an element:
    • stubbles\lang\reflect\ReflectionClass::annotations()
    • stubbles\lang\reflect\ReflectionObject::annotations()
    • stubbles\lang\reflect\ReflectionFunction::annotations()
    • stubbles\lang\reflect\ReflectionMethod::annotations()
    • stubbles\lang\reflect\ReflectionParameter::annotations()
    • stubbles\lang\reflect\ReflectionProperty::annotations()
  • Added non-static usage of stubbles\lang\Parse
    • instance creation takes a string value
    • all methods to*() are additionally available as non-static as*() methods except toType()
  • Added stubbles\lang\Properties::parse() which returns an instance of stubbles\lang\Parse
  • Added stubbles\lang\reflect\annotation\Annotation::parse() which returns an instance of stubbles\lang\Parse
  • Added stubbles\lang\iterator\RecursiveArrayIterator to iterate recursively on leafs of arrays only
  • Added stubbles\lang\iterator\MappingIterator to allow mapping of keys and values during iteration

4.1.4 - Call me back to reflect

31 Dec 17:21
Compare
Choose a tag to compare
  • added support to reflect array callbacks with stubbles\lang\reflect()

4.1.3 - Secure strings are properties, too

31 Dec 17:20
Compare
Choose a tag to compare
  • fixed bug that property bindings did not work together with type hints, e.g. for stubbles\lang\SecureString

4.1.2 - Such a secure string

31 Dec 17:19
Compare
Choose a tag to compare
  • fixed bug in stubbles\lang\exception\Exception::__toString() always reporting this class instead of the real exception class
  • all properties in stubbles\lang\Properties where key ends with password are automatically stored as stubbles\lang\SecureString
  • fixed bug that a var_dump() of a stubbles\lang\SecureString instance reveiled the length of the secured string