4/10/2023 0 Comments Uuid generatorPublic UUID(long mostSigBits, long leastSigBits)Ĭreates a new UUID using specified data. It is also known as GUID (Globally Unique Identifier). Java UUID class represents an immutable universally unique identifier and represents 128-bit value. See the License for the specific language governing permissions andįriedel Ziegelmayer for the Elixir programming language.Java UUID (Universally Unique Identifier) class is part of java.util package. WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. Unless required by applicable law or agreed to in writing, softwareĭistributed under the License is distributed on an "AS IS" BASIS, You may not use this file except in compliance with the License. Licensed under the Apache License, Version 2.0 (the "License") Some helper functions from rjsamson/hexate. Some code ported from avtobiff/erlang-uuid. An ArgumentError is raised if the argument is not valid UUID binary data. Use UUID.binary_to_string!/2 to convert valid UUID binary data to a String representation, with an optional format similar to the generator functions above. An ArgumentError is raised if the argument is not a valid UUID string. Use UUID.string_to_binary!/1 to convert a valid UUID string to its raw binary equivalent. !/1 directly returns the info keyword list when successful or raises an ArgumentError for error cases. 1 returns a tuple of if the argument is not a UUID string. Use /1 and !/1 to get a keyword list containing information about the given UUID. :urn is a standard UUID representation prefixed with the UUID URN: iex> UUID.uuid1(:urn) :hex is a valid hex string, corresponding to the standard UUID without the - (dash) characters: iex> UUID.uuid4(:hex) :default is a standard UUID representation: iex> UUID.uuid1() Default value is :default and can be omitted. Iex> UUID.uuid5("fcfe5f21-8a08-4c9a-9f97-29d2fd6a27b9", "my.")Īll UUID generator functions have an optional format parameter as the last argument. Valid namespaces are: :dns, :url, :oid, :x500, :nil. Generated using the SHA1 hash of a name and either a namespace atom or an existing UUID. Generated using the MD5 hash of a name and either a namespace atom or an existing UUID. Generated using a combination of time since the west adopted the gregorian calendar and the node id MAC address. Add as a dependency in your mix.exs file: defp deps do The changelog lists every available release and its corresponding language version requirement. New releases may change this minimum compatible version depending on breaking language changes. The latest version is 1.1.8 and requires Elixir ~> 1.0.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |