Skip to content

Released 0.2.0

Latest
Compare
Choose a tag to compare
@jkuchar jkuchar released this 15 Jan 10:21
· 10 commits to master since this release

Features from 0.1.x version are mentioned in project readme.

Feedback is welcome - open issue or contact me directly.

  • support for switch, loose comparison, in_array, etc... (go to code)
  • it warns you about not intended usage (e.g. your enum must be final xor abstract), or that you have forgotten to call value constructor (go to code)
  • support for getting all possible values for enum (go to code)
  • started to distinguish between checked (runtime) and unchecked (usage) exceptions (go to code)
  • 📚 docs: added migrating legacy code example, adding behaviour to enum example, order state example and loylty program example (go to docs)
  • less internal magic used to make things work
  • support for non-anonymous classes as values (go to code)

Breaking changes

  • provideInstances(): scalar values are provided to first constructor parameter of each value; when using AutoInstances, you are not affected (go to code)
  • renamed getScalarValue() to toScalar() (go to code)

Thank you

Thank you, David Brnovják, for detailed feedback and many consultations over the Pékápkaři's Slack.

Thanks PHP Weekly for mentioning this library in the 10th January 2019 newsletter.