W3cubDocs

/Phoenix

Ecto.UUID

An Ecto type for UUIDs strings.

Summary

Types

raw()

A raw binary representation of a UUID

t()

A hex-encoded UUID string

Functions

bingenerate()

Generates a version 4 (random) UUID in the binary format

cast!(value)

Same as cast/1 but raises Ecto.CastError on invalid arguments

cast(binary)

Casts to UUID

dump(arg1)

Converts a string representing a UUID into a binary

generate()

Generates a version 4 (random) UUID

load(uuid)

Converts a binary UUID into a string

type()

The Ecto type

Types

raw()

raw() :: <>

A raw binary representation of a UUID.

t()

t() :: <>

A hex-encoded UUID string.

Functions

bingenerate()

bingenerate() :: raw()

Generates a version 4 (random) UUID in the binary format.

cast!(value)

cast!(t() | raw() | any()) :: t()

Same as cast/1 but raises Ecto.CastError on invalid arguments.

cast(binary)

cast(t() | raw() | any()) :: {:ok, t()} | :error

Casts to UUID.

dump(arg1)

dump(t() | any()) :: {:ok, raw()} | :error

Converts a string representing a UUID into a binary.

generate()

generate() :: t()

Generates a version 4 (random) UUID.

load(uuid)

load(raw() | any()) :: {:ok, t()} | :error

Converts a binary UUID into a string.

type()

The Ecto type.

© 2012 Plataformatec
Licensed under the Apache License, Version 2.0.
https://hexdocs.pm/ecto/Ecto.UUID.html