Deprecate Uuid::setFactory() and Uuid::getFactory()

This commit is contained in:
Ben Ramsey
2022-08-05 17:28:37 -05:00
parent 55693967d7
commit 7b3eaf32c7
3 changed files with 76 additions and 7 deletions
+8
View File
@@ -403,6 +403,9 @@ class Uuid implements UuidInterface
/**
* Returns the factory used to create UUIDs
*
* @deprecated ramsey/uuid version 5 will no longer support getting a
* factory instance from the base Ramsey\Uuid\Uuid class.
*/
public static function getFactory(): UuidFactoryInterface
{
@@ -416,6 +419,11 @@ class Uuid implements UuidInterface
/**
* Sets the factory used to create UUIDs
*
* @deprecated ramsey/uuid version 5 will no longer support setting a
* factory instance on the base Ramsey\Uuid\Uuid class. If you need to
* customize the properties used to build a UUID, use one of the
* dedicated factories that version 5 will introduce.
*
* @param UuidFactoryInterface $factory A factory that will be used by this
* class to create UUIDs
*/