# Copyright (c) 2006 bivio Software, Inc. All Rights Reserved. # # Visit http://www.bivio.biz for more info. # # This library is free software; you can redistribute it and/or modify # it under the terms of the GNU Lesser General Public License as # published by the Free Software Foundation; either version 2.1 of the # License, or (at your option) any later version. # # This library is distributed in the hope that it will be useful, but # WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU # Lesser General Public License for more details. # # You should have received a copy of the GNU Lesser General Public # License along with this library; If not, you may get a copy from: # http://www.opensource.org/licenses/lgpl-license.html # # $Id: DateTime.bunit,v 1.5 2010/12/26 02:04:49 nagler Exp $ [ class => [ { method => 'get_widget_value', compute_params => sub { my(undef, $params) = @_; my($mode, $dt, $tz) = @$params; return [ DateTime($dt || '3/6/2006 12:0:1'), $mode, !$tz, ]; }, } => [ [qw(DATE_TIME 0 1)] => '03/06/2006 12:00:01 GMT', TIME => '12:00:01', DATE => '03/06/2006', DATE_TIME => '03/06/2006 12:00:01', MONTH_NAME_AND_DAY_NUMBER => 'March 6', MONTH_AND_DAY => '03/06', FULL_MONTH_DAY_AND_YEAR_UC => 'MARCH 6, 2006', FULL_MONTH_DAY_AND_YEAR => 'March 6, 2006', FULL_MONTH_AND_YEAR_UC => 'MARCH, 2006', FULL_MONTH => 'March', DAY_MONTH3_YEAR => '06-Mar-2006', DAY_MONTH3_YEAR_TIME => '06-Mar-2006 12:00:01', RFC822 => 'Mon, 6 Mar 2006 12:00:01 GMT', DAY_MONTH3_YEAR_TIME_PERIOD => '06-Mar-2006 12:00:01 PM', [DAY_MONTH3_YEAR_TIME_PERIOD => '4/15/2006 00:00:00'] => '15-Apr-2006 12:00:00 AM', [DAY_MONTH3_YEAR_TIME_PERIOD => '4/15/2006 11:59:59'] => '15-Apr-2006 11:59:59 AM', [DAY_MONTH3_YEAR_TIME_PERIOD => '4/15/2006 13:00:00'] => '15-Apr-2006 01:00:00 PM', [DAY_MONTH3_YEAR_TIME_PERIOD => '4/15/2006 23:59:59'] => '15-Apr-2006 11:59:59 PM', HOUR_MINUTE_AM_PM_LC => '12:00 pm', [HOUR_MINUTE_AM_PM_LC => '4/15/2006 01:00:30'] => '1:01 am', ], ], ];