DateTime::Format::Human - Format times in "spoken language"
use DateTime; use DateTime::Format::Human; my $dtfh = DateTime::Format::Human->new( evening => 19, night => 23, ); my $spoken_time = $dtfh->format_datetime( DateTime->now ); print "The time is now $spoken_time\n";
This module provides a "vague" rendering of the time into natural language; it's originally intended for text-to-speech applications and other speech-based interfaces.
This module accepts no arguments to it's
import method and exports no symbols.
Accepts a optional hash and returns a DateTime::Format::Human object.
my $dtfh = DateTime::Format::Human->new( evening => 19, night => 23, );
Sets the hour at which afternoon turns to evening.
This key defaults to the value of 18.
Sets the hour at which evening turns to night.
This key defaults to the value of 22.
Accepts a DateTime object.
Returns a string representing the time in spoken human language.
Simon Cozens (SIMON) who wrote Time::Human from which this module is a genetic descendant.
Everyone at the DateTime
Support for this module is provided via the firstname.lastname@example.org email list. See http://lists.perl.org/ for more details
Joshua Hoblitt <email@example.com>
Copyright (C) 2004 Joshua Hoblitt. All rights reserved. Sections of the code and documentation are Copyright (C) 2001 Simon Cozens.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
firstname.lastname@example.org mailing list