Help-Site Computer Manuals
Software
Hardware
Programming
Networking
  Algorithms & Data Structures   Programming Languages   Revision Control
  Protocols
  Cameras   Computers   Displays   Keyboards & Mice   Motherboards   Networking   Printers & Scanners   Storage
  Windows   Linux & Unix   Mac

News::Article::Mbox
combines News::Article and Mail::Mbox::MessageParser

News::Article::Mbox - combines News::Article and Mail::Mbox::MessageParser


NAME

News::Article::Mbox - combines News::Article and Mail::Mbox::MessageParser


SYNOPSIS


  use News::Article::Mbox;

  my @articles = News::Article::Mbox->read_mbox( \*STDIN );


DESCRIPTION

News::Article is capable of reading in individual messages from STDIN or other sources to make into Article objects. However, it is often helpful to be able to read many Articles out of an mbox-class storage format, as created by many newsreader programs. This package adds a single function, read_mbox(), to News::Article which makes this easy and accurate, using the functionality of Mail::Mbox::MessageParser.


USAGE

Mostly the same as News::Article, except with the following function:

read_mbox ( SOURCE [, MAXSIZE, MAXHEAD] )
Acts like News::Article::read(), except that it loads a large number of articles instead of each one. SOURCE is parsed with Mail::Mbox::MessageParser; if it turns out to only be a single news message and not a full mbox, then this is bypassed and that message is parsed. All messages make News::Article references. Returns an array or arrayref of articles.

This function is exportable, but is not exported by default.


REQUIREMENTS

News::Article, File::Temp, Mail::Mbox::MessageParser


SEE ALSO

News::Article


TODO

This actually works pretty much the way it's supposed to.

It might be nice if we didn't have to use File::Temp...


AUTHOR

Tim Skirvin <tskirvin@killfile.org>


HOMEPAGE

http://www.killfile.org/~tskirvin/software/news-archive/

http://www.killfile.org/~tskirvin/software/newslib/


LICENSE

This code may be redistributed under the same terms as Perl itself.


COPYRIGHT

Copyright 2004, Tim Skirvin.

Programminig
Wy
Wy
yW
Wy
Programming
Wy
Wy
Wy
Wy