timex_ecto v3.1.1 Timex.Ecto.Date

Support for using Timex with :date fields

Summary

Functions

Handle casting to Timex.Ecto.Date

Convert to native Ecto representation

Load from the native Ecto representation

Returns the underlying schema type for the custom type

Functions

autogenerate(precision \\ :sec)
cast(date)

Handle casting to Timex.Ecto.Date

dump(datetime)

Convert to native Ecto representation

load(date)

Load from the native Ecto representation

type()

Returns the underlying schema type for the custom type.

For example, if you want to provide your own date structures, the type function should return :date.

Note this function is not required to return Ecto primitive types, the type is only required to be known by the adapter.

Callback implementation for Ecto.Type.type/0.