Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 732b58c

Browse filesBrowse files
committed
feature #12820 Added the docs for the UUID polyfill (javiereguiluz)
This PR was squashed before being merged into the 3.4 branch (closes #12820). Discussion ---------- Added the docs for the UUID polyfill Commits ------- fcb2b89 Added the docs for the UUID polyfill
2 parents 58d4112 + fcb2b89 commit 732b58c
Copy full SHA for 732b58c

File tree

Expand file treeCollapse file tree

1 file changed

+57
-0
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+57
-0
lines changed

‎components/polyfill_uuid.rst

Copy file name to clipboard
+57Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
.. index::
2+
single: Polyfill
3+
single: PHP
4+
single: Components; Polyfill
5+
6+
The Symfony Polyfill / UUID Component
7+
=====================================
8+
9+
This component provides ``uuid_*`` functions to users who run PHP versions
10+
without the UUID extension.
11+
12+
Installation
13+
------------
14+
15+
.. code-block:: terminal
16+
17+
$ composer require symfony/polyfill-uuid
18+
19+
.. include:: /components/require_autoload.rst.inc
20+
21+
Usage
22+
-----
23+
24+
Once this component is installed in your application, you can use the following
25+
functions, no matter if the `PHP UUID extension`_ is installed or not in your
26+
server.
27+
28+
Provided Constants
29+
~~~~~~~~~~~~~~~~~~
30+
31+
* ``UUID_VARIANT_NCS`` (value = 0)
32+
* ``UUID_VARIANT_DCE`` (value = 1)
33+
* ``UUID_VARIANT_MICROSOFT`` (value = 2)
34+
* ``UUID_VARIANT_OTHER`` (value = 3)
35+
* ``UUID_TYPE_DEFAULT`` (value = 0)
36+
* ``UUID_TYPE_TIME`` (value = 1)
37+
* ``UUID_TYPE_DCE`` (value = 4)
38+
* ``UUID_TYPE_NAME`` (value = 1)
39+
* ``UUID_TYPE_RANDOM`` (value = 4)
40+
* ``UUID_TYPE_NULL`` (value = -1)
41+
* ``UUID_TYPE_INVALID`` (value = -42)
42+
43+
Provided Functions
44+
~~~~~~~~~~~~~~~~~~
45+
46+
* :phpfunction:`uuid_create`
47+
* :phpfunction:`uuid_is_valid`
48+
* :phpfunction:`uuid_compare`
49+
* :phpfunction:`uuid_is_null`
50+
* :phpfunction:`uuid_type`
51+
* :phpfunction:`uuid_variant`
52+
* :phpfunction:`uuid_time`
53+
* :phpfunction:`uuid_mac`
54+
* :phpfunction:`uuid_parse`
55+
* :phpfunction:`uuid_unparse`
56+
57+
.. _`PHP UUID extension`: https://pecl.php.net/package/uuid

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.