date() = calendar:date()
{Year, Month, Day}
datetime() = calendar:datetime()
{{Year, Month, Day}, {Hour, Min, Sec}}
pday() = day | days
period() = {integer(), ptype()} | {ptype(), integer()}
periods() = [period()]
phour() = hrs | hour | hours
pminute() = min | minute | minutes
pmonth() = month | months
psecond() = sec | second | seconds
ptype() = psecond() | pminute() | phour() | pday() | pmonth() | pyear()
pyear() = year | years
add_days/1 | Same as uef_time:add_seconds(Days * 86400). |
add_days/2 | Adds the number of days Days to DateOrDatetime and returns a new date or datetime value. |
add_hours/1 | Same as uef_time:add_seconds(Hours * 3600). |
add_hours/2 | Adds the number of hours Hours to DateOrDatetime and returns a new datetime value. |
add_minutes/1 | Same as uef_time:add_seconds(Minutes * 60). |
add_minutes/2 | Adds the number of minutes Minutes to DateOrDatetime and returns a new datetime value. |
add_months/1 | Same as uef_time:add_months(erlang:localtime(), Months). |
add_months/2 | Adds the number of months Months to DateOrDatetime and returns a new date or datetime value. |
add_seconds/1 | Same as uef_time:add_seconds(erlang:localtime(), Seconds). |
add_seconds/2 | Adds the number of seconds Seconds to DateOrDatetime and returns a new datetime value. |
add_time/1 | Same as uef_time:add_time(erlang:localtime(), Periods). |
add_time/2 | Adds one or more periods of time to DateOrDatetime and returns a new date or datetime value. |
add_weeks/1 | Same as uef_time:add_seconds(Weeks * 604800). |
add_weeks/2 | Adds the number of weeks Weeks to DateOrDatetime and returns a new date or datetime value. |
add_years/1 | Same as uef_time:add_years(erlang:localtime(), Years). |
add_years/2 | Adds the number of years Years to DateOrDatetime and returns a new date or datetime value. |
days_diff/1 | Returns the difference in days between Date and the current local date provided by function erlang:date(). |
days_diff/2 | Returns the difference in days between Date2 and Date1. |
seconds_diff/1 | Returns the difference in seconds between Date and the current local time provided by function erlang:localtime(). |
seconds_diff/2 | Returns the difference in seconds between DateTime2 and DateTime1. |
today/0 | Returns the current date as {Year, Month, Day}. |
tomorrow/0 | Returns tomorrow's date as {Year, Month, Day}. |
unix_time/0 | Returns the current number of seconds since 00:00:00 (UTC), 1 January 1970. |
unix_time/1 | Returns the number of seconds elapsed between 00:00:00 (UTC), 1 January 1970 and Datetime. |
yesterday/0 | Returns yesterday's date as {Year, Month, Day}. |
add_days(Days::integer()) -> datetime()
Same as uef_time:add_seconds(Days * 86400). See docs of uef_time:add_seconds/1.
add_days(DateOrDatetime::date() | datetime(), Days::integer()) -> NewDateOrDateTime::date() | datetime()
Adds the number of days Days to DateOrDatetime and returns a new date or datetime value. The type of NewDateOrDateTime is the same as the type of DateOrDatetime.
add_hours(Hours::integer()) -> datetime()
Same as uef_time:add_seconds(Hours * 3600). See docs of uef_time:add_seconds/1.
add_hours(DateOrDatetime::date() | datetime(), Hours::integer()) -> datetime()
Adds the number of hours Hours to DateOrDatetime and returns a new datetime value.
add_minutes(Minutes::integer()) -> datetime()
Same as uef_time:add_seconds(Minutes * 60). See docs of uef_time:add_seconds/1.
add_minutes(DateOrDatetime::date() | datetime(), Minutes::integer()) -> datetime()
Adds the number of minutes Minutes to DateOrDatetime and returns a new datetime value.
add_months(Months::integer()) -> datetime()
Same as uef_time:add_months(erlang:localtime(), Months). See docs of uef_time:add_months/2.
add_months(DateOrDatetime::date() | datetime(), Months::integer()) -> NewDateOrDateTime::date() | datetime()
Adds the number of months Months to DateOrDatetime and returns a new date or datetime value. The type of NewDateOrDateTime is the same as the type of DateOrDatetime.
add_seconds(Seconds::integer()) -> datetime()
Same as uef_time:add_seconds(erlang:localtime(), Seconds). See docs of uef_time:add_seconds/2.
add_seconds(DateOrDatetime::date() | datetime(), Seconds::integer()) -> datetime()
Adds the number of seconds Seconds to DateOrDatetime and returns a new datetime value.
add_time(Periods::periods()) -> datetime()
Same as uef_time:add_time(erlang:localtime(), Periods).
add_time(DateOrDatetime::date() | datetime(), Tail::periods()) -> NewDateOrDateTime::date() | datetime()
Adds one or more periods of time to DateOrDatetime and returns a new date or datetime value.
add_weeks(Weeks::integer()) -> datetime()
Same as uef_time:add_seconds(Weeks * 604800). See docs of uef_time:add_seconds/1.
add_weeks(DateOrDatetime::date() | datetime(), Weeks::integer()) -> NewDateOrDateTime::date() | datetime()
Adds the number of weeks Weeks to DateOrDatetime and returns a new date or datetime value. The type of NewDateOrDateTime is the same as the type of DateOrDatetime.
add_years(Years::integer()) -> datetime()
Same as uef_time:add_years(erlang:localtime(), Years). See docs of uef_time:add_years/2.
add_years(DateOrDatetime::date() | datetime(), Years::integer()) -> NewDateOrDateTime::date() | datetime()
Adds the number of years Years to DateOrDatetime and returns a new date or datetime value. The type of NewDateOrDateTime is the same as the type of DateOrDatetime.
days_diff(Date::date()) -> Days::integer()
Returns the difference in days between Date and the current local date provided by function erlang:date(). Date must be of type calendar:date() ({Year, Month, Day}). Days is a positive value if Date is after erlang:date() or a negative value otherwise.
Returns the difference in days between Date2 and Date1. Date1 and Date2 must be of type calendar:date() ({Year, Month, Day}). Days is a positive value if Date2 is after Date1 or a negative value otherwise.
seconds_diff(DateTime::datetime()) -> Seconds::integer()
Returns the difference in seconds between Date and the current local time provided by function erlang:localtime(). DateTime must be of type calendar:datetime() ({{Year, Month, Day}, {Hour, Minute, Second}}). Seconds is a positive value if DateTime is after erlang:localtime() or a negative value otherwise.
seconds_diff(DateTime1::datetime(), DateTime2::datetime()) -> integer()
Returns the difference in seconds between DateTime2 and DateTime1. DateTime1 and DateTime2 must be of type calendar:datetime() ({{Year, Month, Day}, {Hour, Minute, Second}}). Seconds is a positive value if DateTime2 is after DateTime1 or a negative value otherwise.
today() -> CurrentDate::date()
Returns the current date as {Year, Month, Day}. Same as erlang:date(). CurrentDate is of type calendar:date().
tomorrow() -> TomorrowDate::date()
Returns tomorrow's date as {Year, Month, Day}. TomorrowDate is of type calendar:date().
unix_time() -> Seconds::integer()
Returns the current number of seconds since 00:00:00 (UTC), 1 January 1970. It also known as Unix time or POSIX time or UNIX Epoch time.
unix_time(Datetime::datetime()) -> Seconds::integer()
Returns the number of seconds elapsed between 00:00:00 (UTC), 1 January 1970 and Datetime. Datetime must be of type calenadr:datetime().
yesterday() -> YesterdayDate::date()
Returns yesterday's date as {Year, Month, Day}. YesterdayDate is of type calendar:date().
Generated by EDoc