Debian Codegraph @

README

raw
1 NAME
2 XML::OPML::SimpleGen - create OPML using XML::Simple
3
4 VERSION
5 version 0.07
6
7 SYNOPSIS
8 require XML::OPML::SimpleGen;
9
10 my $opml = new XML::OPML::SimpleGen();
11
12 $opml->head(
13 title => 'FIFFS Subscriptions',
14 );
15
16 $opml->insert_outline(
17 group => 'news', # groups will be auto generated
18 text => 'some feed',
19 xmlUrl => 'http://www.somepage.org/feed.xml',
20 );
21
22 # insert_outline and add_outline are the same
23
24 $opml->add_group( text => 'myGroup' ); # explicitly create groups
25
26 print $opml->to_string;
27
28 $opml->save('somefile.opml');
29
30 $opml->xml_options( $hashref ); # XML::Simple compatible options
31
32 # See XML::OPML's synopsis for more knowledge
33
34 DESCRIPTION
35 XML::OPML::SimpleGen lets you simply generate OPML documents without
36 having too much to worry about. It is a drop-in replacement for
37 XML::OPML in regards of generation. As this module uses XML::Simple it
38 is rather generous in regards of attribute or element names.
39
40 NAME
41 XML::OPML::SimpleGen - create OPML using XML::Simple
42
43 COMMON METHODS
44 new( key => value )
45 Creates a new XML::OPML::SimpleGen instance. All key values will be
46 used as attributes for the <atom> element. The only thing you might
47 want to use here is the version => '1.1', which is default anyway.
48
49 head( key => value )
50 XML::OPML compatible head method to change header values.
51
52 id ( )
53 Returns (and increments) a counter.
54
55 add_group ( text => 'name' )
56 Method to explicitly create a group which can hold multiple outline
57 elements.
58
59 insert_outline ( key => value )
60 XML::OPML compatible method to add an outline element. See XML::OPML
61 for details. The group key is used to put elements in a certain
62 group. Non existent groups will be created automagically.
63
64 add_outline ( key => value )
65 Alias to insert_outline for XML::OPML compatibility.
66
67 as_string
68 Returns the given OPML XML data as a string
69
70 save ( $filename )
71 Saves the OPML data to a file
72
73 ADVANCED METHODS
74 xml_options ( $hashref )
75 $hashref may contain any XML::Simple options.
76
77 outline ( $hashref )
78 The outline method defines the 'template' for any new outline
79 element. You can preset key value pairs here to be used in all
80 outline elements that will be generated by XML::OPML::SimpleGen.
81
82 group ( $hashref )
83 This method is similar to outline, it defines the template for a
84 grouping outline element.
85
86 MAINTAINER
87 Stephen Cardie "<[email protected]>"
88
89 REPOSITORY
90 <https://github.com/stephenca/XML-OPML-SimpleGen>
91
92 CONTRIBUTORS
93 KAPPA "<[email protected]>" contributed a patch to close RT51000
94 <https://rt.cpan.org/Public/Bug/Display.html?id=51000>
95 [email protected] contributed a patch to close RT77725
96 <https://rt.cpan.org/Public/Bug/Display.html?id=77725>
97
98 REPO
99 The git repository for this module is at
100 L<https://github.com/stephenca/XML-OPML-SimpleGen>
101
102 BUGS
103 Please report any bugs or feature requests to
104 "[email protected]", or through the web interface at
105 <http://rt.cpan.org/NoAuth/ReportBug.html?Queue=XML-OPML-SimleGen>. I
106 will be notified, and then you'll automatically be notified of progress
107 on your bug as I make changes.
108
109 SEE ALSO
110 XML::OPML XML::Simple
111
112 AUTHOR
113 Marcus Theisen <[email protected]>
114
115 COPYRIGHT AND LICENSE
116 This software is copyright (c) 2013 by Marcus Thiesen.
117
118 This is free software; you can redistribute it and/or modify it under
119 the same terms as the Perl 5 programming language system itself.
120