IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Oct 26, 2006, 4:15:45 PM (20 years ago)
Author:
jhoblitt
Message:

fix time tests that were dependent on MULTI times being broken
fix MULTI time
no longer require the 'Z' and the end of ISO8601 times
implement NULL time support

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/PS-IPP-Metadata-Config/config_grammar.txt

    r9495 r9758  
    11# Copyright (c) 2005  Joshua Hoblitt
    22#
    3 # $Id: config_grammar.txt,v 1.6 2006-10-12 02:08:51 jhoblitt Exp $
     3# $Id: config_grammar.txt,v 1.7 2006-10-27 02:15:45 jhoblitt Exp $
    44
    55{
     
    146146            $return->{comment} = $item{'comment(?)'}[0]
    147147                if $item{'comment(?)'}[0];
     148
     149            if ( defined $thisparser->{local}{name}{ $item{name} } ) {
     150                $return->{multi}++
     151                    if $thisparser->{local}{name}{ $item{name} } =~ /MULTI/;
     152            } else {
     153                $thisparser->{local}{name}{ $item{name} }++;
     154            }
    148155        }
    149156
     
    362369    iso8601
    363370    | utc_epoch
     371    | NULL
    364372
    365373UT1:
    366374    iso8601
    367375    | epoch
     376    | NULL
    368377
    369378TAI:
    370379    iso8601
    371380    | epoch
     381    | NULL
    372382
    373383TT:
    374384    iso8601
    375385    | epoch
     386    | NULL
    376387
    377388iso8601:
    378389    # based on code from DateTime::Format::ISO8601
    379     / \d{4} -?? \d\d -?? \d\d T?? \d\d :?? \d\d :?? \d\d (?:[\.,] (\d+))? Z/x
     390    / \d{4} -?? \d\d -?? \d\d T?? \d\d :?? \d\d :?? \d\d (?:[\.,] (\d+))? Z?/x
    380391        { DateTime::Format::ISO8601->parse_datetime( $item[1] ) }
    381392
     
    394405            nsec    => $2,
    395406        }}
     407NULL:
     408    /NULL/
     409    { $return = "NULL" }
    396410
    397411eofile:
Note: See TracChangeset for help on using the changeset viewer.