Skip to main content

Crate vardadieniai

Crate vardadieniai 

Source
Expand description

§vardadieniai

Lietuvos vardadienių kalendorius: kurie vardai švenčiami pasirinktą dieną, kada švenčia konkretus vardas ir kas švenčia šiandien (Vilniaus laiku). Lithuanian name day calendar: names by date, dates by name and today’s names in Europe/Vilnius time. No dependencies.

The calendar for people, with today’s and tomorrow’s names, greetings and gift ideas: https://dovanasuvardu.lt/vardadieniai/

assert!(vardadieniai::names_on(11, 9).contains(&"Teodoras"));
assert!(vardadieniai::days_for("ąžuolas").iter().all(|&(m, _)| (1..=12).contains(&m)));
assert_eq!(vardadieniai::format_date(11, 9), "lapkričio 9 d.");

Code: MIT. Name day data: CC BY-SA 4.0 (source: Lithuanian Wikipedia).

Structs§

Date
A calendar date (proleptic Gregorian calendar).

Constants§

HOMEPAGE
Online name day calendar (Lithuanian).
MONTHS_LT
Lithuanian month names in the genitive case (sausio … gruodžio).

Functions§

days_for
Days (month, day) on which the name is celebrated. Case and diacritics are ignored, so "azuolas" finds Ąžuolas.
days_in_month
Number of days in the month.
fold
Lowercases the text and removes Lithuanian diacritics (Ąžuolas -> azuolas).
format_date
Lithuanian date label, e.g. format_date(11, 9) = "lapkričio 9 d.".
is_leap
true for leap years.
month
All days of a month (1..=12) with their names, in calendar order.
names_on
Names celebrated on the given day (month 1–12, day 1–31). Returns an empty slice for a date that is not in the calendar.
today
Names celebrated today in Lithuania.
tomorrow
Names celebrated tomorrow in Lithuania.
vilnius_date
The date in Lithuania (Europe/Vilnius: UTC+2, UTC+3 from the last Sunday of March to the last Sunday of October, switching at 01:00 UTC) for a Unix timestamp in seconds.
vilnius_today
Today’s date in Lithuania.