The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

MARC::Moose::Field::Std - Standard Marc Field (tag >= 010)

VERSION

version 1.0.23

ATTRIBUTES

subf

An ArrayRef of field subfields. Each subfield is this array is an 2D ArrayRef. For example:

  $field->subf( [ [ 'a', 'Part1' ], [ 'b', 'Part2' ] ] );

or

  $field->subf( [ [ a => 'Part1' ], [ b => 'Part2' ] ] );

METHODS

subfield( regexp )

In scalar context, returns the first content of subfield which letter match regular expression regexp . In list context, returns all subfields content.

For example:

  my $field = MARC::Moose::Field::Std->new(
    tag => '600',
    subf => [
      [ a => 'Part 1' ],
      [ x => '2010' ],
      [ a => 'Part 2' ],
      [ b => 'Part 3' ],
    ] );
  my $value = $field->subfield('a|b'); # Get 'Part 1'
  my @values = $field->subfield('a|b'); # Get ('Part1', 'Part 2')

AUTHOR

Frédéric Demians <f.demians@tamil.fr>

COPYRIGHT AND LICENSE

This software is copyright (c) 2015 by Frédéric Demians.

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