Acme-MetaSyntactic
view release on metacpan or search on metacpan
lib/Acme/MetaSyntactic/RemoteList.pm view on Meta::CPAN
Return a boolean indicating if the C<source> key is defined (and therefore
if the theme actually has a remote list).
=item source()
Return the data structure containing the source URLs. This can be quite
different depending on the class: a single scalar (URL), an array
reference (list of URLs) or a hash reference (each value being either
a scalar or an array reference) for themes that are subclasses of
C<Acme::MetaSyntactic::MultiList>.
=item sources( [ $category ] )
Return the list of source URL. The C<$category> parameter can be used
to select the sources for a sub-category of the theme (in the case of
C<Acme::MetaSyntactic::MultiList>).
C<$category> can be an array reference containing a list of categories.
=item extract( $content )
Return a list of items from the C<$content> string. C<$content> is
expected to be the content available at the URL given by C<source()>.
=back
=head1 TRANSFORMATION SUBROUTINES
The C<Acme::MetaSyntactic::RemoteList> class also provides a few helper
subroutines that simplify the normalisation of items:
=over 4
=item tr_nonword( $str )
Return a copy of C<$str> with all non-word characters turned into
underscores (C<_>).
=item tr_accent( $str )
Return a copy of C<$str> will all iso-8859-1 accented characters turned
into basic ASCII characters.
=item tr_utf8_basic( $str )
Return a copy of C<$str> with some of the utf-8 accented characters turned
into basic ASCII characters. This is very crude, but I didn't to bother
and depend on the proper module to do that.
=back
=head1 AUTHOR
Philippe 'BooK' Bruhat, C<< <book@cpan.org> >>.
=head1 ACKNOWLEDGEMENTS
Thanks to Michael Scherer for his help in finding the name of this
module on C<#perlfr>. Welcome in F<CONTRIBUTORS>, Michael! C<:-)>
#perlfr Tue Nov 1 19:33 CET 2005
<@BooK> bon, je sais toujours pas comment appeler mon module moi
<@BooK> AMS::RemoteSource ?
< misc> RemoteListing ?
<@BooK> RemoteList, même
=head1 SEE ALSO
L<Acme::MetaSyntactic>, L<Acme::MetaSyntactic::List>,
L<Acme::MetaSyntactic::Locale>.
=head1 COPYRIGHT
Copyright 2005-2012 Philippe 'BooK' Bruhat, All Rights Reserved.
=head1 LICENSE
This program is free software; you can redistribute it and/or modify it
under the same terms as Perl itself.
=cut
( run in 1.781 second using v1.01-cache-2.11-cpan-39bf76dae61 )