Andrew Jones > ICal-Format-Natural-1.121310 > ICal::Format::Natural

Download:
ICal-Format-Natural-1.121310.tar.gz

Dependencies

Annotate this POD

Website

View/Report Bugs
Module Version: 1.121310   Source  

NAME ^

ICal::Format::Natural - Create an Data::ICal object with natural parsing logic.

VERSION ^

version 1.121310

SYNOPSIS ^

  # only exported on demand
  use ICal::Format::Natural qw(ical_format_natural);

  my $ical = ical_format_natural('Tomorrow at noon. Lunch with Bob');
  # creates an Data::ICal object with:
  #   dtstart tomorrow 12:00
  #   dtend tomorrow 13:00
  #   summary Lunch with Bob

DESCRIPTION ^

ICal::Format::Natural will (one day) take a human readable string and create an Data::ICal object.

NOTE: Currently this is pretty dumb and simply splits the sting on a fullstop, taking the first part as the date and the second part as the summary.

I would love to improve this one day, but as always it's about finding the time. Any contributions and/or ideas are most welcome.

METHODS ^

ical_format_natural( $string )

Parses the string and returns an Data::ICal object.

CREDITS ^

Thanks to Mark Stosberg who wrote ICal::QuickAdd. It contained a simple version of the parser and was the basis for this module.

AUTHOR ^

Andrew Jones <andrew@arjones.co.uk>

COPYRIGHT AND LICENSE ^

This software is copyright (c) 2012 by Andrew Jones.

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.

syntax highlighting: