XML::Atom::Atompub - XML::Atom::Atompub documentation


XML-Atom-Service documentation  | view source Contained in the XML-Atom-Service distribution.

Index


NAME

Top

XML::Atom::Atompub - Extensions of XML::Atom for the Atom Publishing Protocol

SYNOPSIS

Top

  use XML::Atom::Entry;
  use XML::Atom::Feed;
  use XML::Atom::Atompub;

  my $entry = XML::Atom::Entry->new;

  # <app:edited>2007-01-01T00:00:00Z</app:edited>
  $entry->edited('2007-01-01T00:00:00Z');

  # <app:control><app:draft>yes</app:draft></app:control>
  my $control = XML::Atom::Control->new;
  $control->draft('yes');
  $entry->control($control);

  # <content type="image/png" src="http://example.com/foo.png"/>
  my $content = XML::Atom::Content->new;
  $content->type('image/png');
  $content->src('http://example.com/foo.png');
  $entry->content($content);

  # <link rel="alternate" href="http://example.com/foo.html"/>
  $entry->alternate_link('http://example.com/foo.html');

  my $feed = XML::Atom::Feed->new;

  # <link rel="self" href="http://example.com"/>
  $feed->self_link('http://example.com');




METHODS of XML::Atom

Top

Some elements are introduced by the Atom Publishing Protocol, which are imported into XML::Atom by this module.

$entry->control([ $control ])

Returns an XML::Atom::Control object representing the control of the Entry, or undef if there is no control.

If $control is supplied, it should be an XML::Atom::Control object representing the control. For example:

    my $control = XML::Atom::Control->new;
    $control->draft('yes');
    $entry->control($control);

$entry->edited([ $edited ])

Returns an atom:edited element.

If $edited is given, sets the atom:edited element.

$content->src([ $src ])

Returns a value of src attribute in atom:content element.

If $src is given, the src attribute is added.

SEE ALSO

Top

XML::Atom XML::Atom::Service

AUTHOR

Top

Takeru INOUE, <takeru.inoue _ gmail.com>

LICENCE AND COPYRIGHT

Top

DISCLAIMER OF WARRANTY

Top

BECAUSE THIS SOFTWARE IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY FOR THE SOFTWARE, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE SOFTWARE "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE SOFTWARE IS WITH YOU. SHOULD THE SOFTWARE PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR, OR CORRECTION.

IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR REDISTRIBUTE THE SOFTWARE AS PERMITTED BY THE ABOVE LICENCE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE SOFTWARE (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF THE SOFTWARE TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.


XML-Atom-Service documentation  | view source Contained in the XML-Atom-Service distribution.