NAME

URI::Collection - Input and output link collections in different formats.

SYNOPSIS

use URI::Collection;

$store = URI::Collection->new (
    file      => $bookmarks,
    directory => $favorites,
);

$file_contents = $store->as_bookmark_file ();
$top_directory = $store->as_favorite_directory ();

ABSTRACT

Input and output link collections in different formats.

DESCRIPTION

An object of class URI::Collection represents a parsed Netscape style bookmark file or a Windows "Favorites" directory with multi-format output methods.

METHODS

new

$store = URI::Collection->new (
    file      => $bookmarks,
    directory => $favorites,
);

Return a new URI::Collection object.

This method mashes the link store formats together, simultaneously.

as_bookmark_file

$bookmarks = $store->as_bookmark_file ();

Output a Netscape style bookmark file.

as_favorite_directory

$favorites = $store->as_favorite_directory ();

Output an M$ Windows "Favorites" folder.

DEPENDENCIES

Cwd

File::Find

File::Path

Config::IniFiles

Netscape::Bookmarks

TODO

Make tests damnit!

Add a "save as" filename argument (and function) to the as_bookmark_file () method.

Return the M$ Favorites directory structure (as a variable) instead of writing it to disk.

Handle the top Favorites path better!

Allow munging of file and directory handles to bookmark/favorites.

Throw out redundant links.

Allow slicing of the category-links structure.

Add a method to munge a set of links as bookmarks or favorites after the constructor is called.

Allow this link munging to happen under a given category.

Check if links are active.

Update link titles and URLs if changed or moved.

Mirror links?

Handle other bookmark formats (if there even are any) and "raw" lists of links, to justify such a generic package name. :-)

Make the internal hash structure an object attribute, instead of a global variable.

AUTHOR

Gene Boggs <cpan@ology.net>

COPYRIGHT AND LICENSE

Copyright 2003 by Gene Boggs

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.