You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It seems counter-intuitive that it is not possible to generate a specific version of a UUID using the Uuid::VERSION_* constants e.g. Uuid::generate(Uuid::VERSION_4);. As this library currently supports PHP >= 7.0.0 the use of private visibility constants isn't possible without a major version bump.
One solution is making these constants private (possibly static) properties. This would remove them from the public scope and avoid any confusion around their use.
The other possible solution is to add them as cases in the switch statement that determines which type of UUID to generate:
It seems counter-intuitive that it is not possible to generate a specific version of a UUID using the
Uuid::VERSION_*
constants e.g.Uuid::generate(Uuid::VERSION_4);
. As this library currently supports PHP >= 7.0.0 the use of private visibility constants isn't possible without a major version bump.One solution is making these constants private (possibly static) properties. This would remove them from the public scope and avoid any confusion around their use.
The other possible solution is to add them as cases in the switch statement that determines which type of UUID to generate:
Thoughts?
The text was updated successfully, but these errors were encountered: