GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages
Catalyst::Plugin::DateTime(3) User Contributed Perl Documentation Catalyst::Plugin::DateTime(3)

Catalyst::Plugin::DateTime - DateTime plugin for Catalyst.

    # In your application class 
    use Catalyst qw/DateTime/;


    # Use DateTime objects within your Catalyst app:
    my $dt = $c->datetime(); # will return a DateTime object with local date and time
    my $dt = $c->datetime(year => '2005', month => '01');
 
    $c->datetime->mdy(); # returns current date in mdy format (i.e. 01/01/2006)

    $c->dt(time_zone => 'Asia/Taipei'); # returns current date & time for argued time zone

datetime
Returns a DateTime object. If params are argued they will be passed to the "DateTime->new()" method. Exceptions thrown by DateTime will be caught by Catalyst::Exception.

If the argument list is empty, a DateTime object with the local date and time obtained via "DateTime->now()" will be returned.

Uses "time_zone => local" as a default.

dt
Alias to datetime.

This module's intention is to make the wonders of DateTime easily accesible within a Catalyst application via the Catalyst::Plugin interface.

It adds the methods "datetime" and "dt" to the "Catalyst" namespace.

James Kiser james.kiser@gmail.com

Catalyst, DateTime

    Copyright (c) 2006 the aforementioned author(s). All rights
    reserved. This program is free software; you can redistribute
    it and/or modify it under the same terms as Perl itself.

Hey! The above document had some coding errors, which are explained below:
Around line 11:
=pod directives shouldn't be over one line long! Ignoring all 2 lines of content
2006-01-16 perl v5.32.1

Search for    or go to Top of page |  Section 3 |  Main Index

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with ManDoc.