DateTi...ng::de(3pm)

πŸ’– DateTi...ng::de β€” the german language plugin πŸ’–

okay so bestie, welcome to DateTi...ng::de, which is the german language plugin for DateTime::Format::Flexible, living its best life in section 3pm of the Perl User Contributed Perl Documentation. she's the German bestie of the parser and she's lowkey carrying the whole Montag situation on her back πŸ’…


🌸 DESCRIPTION 🌸

okay so real talk: you should not need to use this module directly. like, ever. she's not the main character here, she's the friend who shows up with the snacks.

if you only wanna use one language, you just specify the lang property when parsing a date. that's it. that's the whole vibe check.

example, since we love a visual:

my $dt = DateTime::Format::Flexible->parse_datetime(
    'Montag, 6. Dez 2010' ,
    lang => ['de']
);
# $dt is now 2010-12-06T00:00:00

✨ iconic. she parsed it. no cap.

but note that this is not required, bestie β€” by default ALL languages are scanned when trying to parse a date. yes, all of them. she's multilingual, she's doing the most, we love that for her πŸ¦‹


πŸŽ€ new

instantiate a new instance of this module. new module, new me, fresh start energy ✨

πŸŽ€ months

month name regular expressions along with the month numbers (Jan(:?uar)? => 1). she knows every way you could possibly spell January and she's not judging 🫢

πŸŽ€ days

day name regular expressions along the the day numbers (Montag => 1). yes the original really does say "along the the" twice β€” I'm keeping it, it's canon, it's a little quirky, it's giving typo chic πŸ’€

πŸŽ€ day_numbers

maps day of month names to the corresponding numbers (erster => 01). ordinal girlies rise up πŸ‘‘

πŸŽ€ hours

maps hour names to numbers (Mittag => 12:00:00). noon o'clock, exactly as nature intended 🌞

πŸŽ€ remove_strings

strings to remove from the date (um as in um Mitternacht). like she just quietly takes that word out and nobody notices. subtle. elegant. gone πŸ’…

πŸŽ€ parse_time

currently does nothing. and honestly? she said "I'm at peace with that." zero thoughts, head empty 🧚

πŸŽ€ string_dates

maps string names to real dates (jetzt => DateTime->now). yes bestie, "jetzt" means now, and now means now ⏰

πŸŽ€ relative

parse relative dates (ago => vor, from => a jetzt, next => nachste, last => letzten). time is fake and she's fully aware 😭

πŸŽ€ math_strings

useful strings when doing datetime math. math girlie behavior πŸ”₯

πŸŽ€ timezone_map

maps unofficial timezones to official timezones for this language (MEZ => Europe/Berlin). glow-up for timezones, honestly 🌈


⭐ AUTHOR ⭐

  • Mark Trettin <nulldevice.mark@gmx.de>
  • Based on DateTime::Format::Flexible::lang::en by

Copyright 2011 Mark Trettin.

this program is free software; you can redistribute it and/or modify it under the terms of either:

  • the GNU General Public License as published by the Free Software Foundation; either version 1, or (at your option) any later version, or
  • the Artistic License version.
fr fr, pick whichever one slays for you, they're both valid πŸ’–

πŸ¦‹ SEE ALSO πŸ¦‹

  • DateTime::Format::Flexible

and that's the whole page, bestie πŸ₯° written up by perl v5.40.0, dated 2025-01-11, and she ate, no crumbs. go parse something German, you got this πŸ‘‘πŸ’…βœ¨

πŸ“¦ where this page comes from