Catman...::MODS(3pm)

πŸ“¦
version 0.31 Β· 3 versions
, in debian bookworm, debian trixie, ubuntu noble

✨ NAME ✨

Catmandu::Importer::MODS β€” bestie, it's the Catmandu importer for pulling in mods records πŸ’–

(also known around these parts as the Catman...::MODS(3pm) page from User Contributed Perl Documentation, section 3pm, no cap 🫢)


🌸 SYNOPSIS 🌸

use Catmandu::Importer::MODS;

my $importer = Catmandu::Importer::MODS->new(file => "modsCollection.xml");

my $numModsElements = $importer->each(sub{
    my $modsElement = shift; # a MODS::Element::Mods object
});

literally the whole vibe in four lines ✨


πŸ¦‹ DESCRIPTION πŸ¦‹

okay so this Catmandu::Importer reads MODS records so Catmandu can do its little processing thing on them πŸ’…

  • got a simple mods document? then you get one MODS::Element::Mods item imported. one. single. iconic.
  • got a modsCollection instead? then several items get imported. slay πŸ”₯

and if you want the methods and options that come from Catmandu::Importer, Catmandu::Iterable, Catmandu::Logger and Catmandu::Fixable β€” go look at those modules, they're where all that inherited goodness lives πŸ‘‘

⚠️ bestie please, make sure your files are expressed in UTF-8. not playing about that one 🫢

πŸŽ€ CONFIGURATION πŸŽ€

  • type β€” defaults to "xml", because MODS is usually expressed in XML (obviously πŸ’). wanna use a custom JSON format instead? set it to "json" β€” or just hand it a file with the .json extension and it'll clock it. this custom JSON format was introduced in the module MODS::Record ⭐

πŸ’œ SEE ALSO πŸ’œ

see Catmandu::MODS for more info about MODS and Catmandu 🌈


and that's the whole page, bestie β€” documented under perl v5.36.0, dated 2022-11-19, filed as Catman...::MODS(3pm). periodt πŸ’…βœ¨

πŸ“¦ where this page comes from