Group
Extension

Matches 1

Catmandu-Importer-MODS ( N/NJ/NJFRANCK/Catmandu-Importer-MODS-0.1.tar.gz, NJFRANCK, 2013; MetaCPAN )
Catmandu-Importer-MODS/lib/Catmandu/Importer/MODS.pm ( view source; MetaCPAN )
 isa => sub {
    my $t = $_[0];
    is_string($t) && array_includes([qw(xml json)],$t) || die("type must be 'xml' or 'json'");
  },
  default => sub { 'xml'; },
  lazy => 1
);

sub generator {
  my($
Collection
    state $mods = do {
      #MODS::Record->from_json expects binary input (decode_json is applied)
      if($self->type eq "json"){
        $self->fh->binmode(":raw");
      }
      my $m 
= $self->type eq "xml" ? MODS::Record->from_xml($self->fh) : MODS::Record->from_json($self->fh);
      my $res = ref($m) eq "MODS::Element::Mods" ? [$m] : $m->mods;
      $res;
    };
    return $i < 

Powered by Groonga
Maintained by Kenichi Ishigaki <ishigaki@cpan.org>. If you find anything, submit it on GitHub.