/[cvs]/nfo/perl/scripts/xupdate/xupdate.pl
ViewVC logotype

Annotation of /nfo/perl/scripts/xupdate/xupdate.pl

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.1 - (hide annotations)
Thu May 1 20:41:47 2003 UTC (21 years ago) by joko
Branch: MAIN
File MIME type: text/plain
initial commit, partly from joko/Scripts/xupdate/xupdate.pl.

1 joko 1.1 #!/usr/bin/perl
2    
3     ## -------------------------------------------------------------------------
4     ## $Id: xupdate.pl,v 1.3 2003/04/26 01:42:39 joko Exp $
5     ## -------------------------------------------------------------------------
6     ## $Log: xupdate.pl,v $
7     ## -------------------------------------------------------------------------
8    
9    
10     =pod
11    
12    
13     =head1 NAME
14    
15     xupdate.pl
16    
17    
18     =head2 Description
19    
20     Please visit "perldoc XML::XUpdate::XSLT".
21    
22    
23     =head3 Todo
24    
25     o mimic interface from already established "xupdate.pl"
26     o replace shortcuts::files through File::Butler?
27    
28    
29     =cut
30    
31    
32     package main;
33    
34     use strict;
35     use warnings;
36    
37     BEGIN {
38     use lib '../../libs';
39     }
40    
41     use XML::XUpdate::XSLT;
42     use shortcuts::files qw( f2s );
43     use Data::Dumper;
44    
45    
46     sub main {
47    
48     my $xupdate = XML::XUpdate::XSLT->new(
49     warnings => 1
50     );
51    
52     #print Dumper($xupdate);
53    
54     # open required files
55     $xupdate->open_document( f2s("wd_document.xml") );
56     $xupdate->open_xupdate( f2s("wd_xupdate.xml") );
57    
58     $xupdate->process();
59     my $result = $xupdate->toString();
60    
61     # some error checking ...
62     if ($result) {
63     print $result, "\n";
64     } else {
65     print "No result.", "\n";
66     }
67    
68     }
69    
70     main();
71     print "ready.", "\n";
72    
73     1;
74     __END__

MailToCvsAdmin">MailToCvsAdmin
ViewVC Help
Powered by ViewVC 1.1.26 RSS 2.0 feed