Text::Tradition::Parser::TEI(3)

NAME
Text::Tradition::Parser::TEI

SYNOPSIS
  use Text::Tradition;

  my $t_from_file = Text::Tradition->new(
    'name' => 'my text',
    'input' => 'TEI',
    'file' => '/path/to/parallel_seg_file.xml'
    );

  my $t_from_string = Text::Tradition->new(
    'name' => 'my text',
    'input' => 'TEI',
    'string' => $parallel_seg_xml,
    );

DESCRIPTION
Parser module for Text::Tradition, given a TEI parallel-segmentation file that describes a text and its variants. Normally called upon initialization of Text::Tradition.

The witnesses for the tradition are taken from the <listWit/> element within the TEI header; the readings are taken from any <p/> element that appears in the text body (including <head/> elements therein.)

METHODS

  parse( $tradition, $option_hash )
Takes an initialized tradition and a set of options; creates the appropriate nodes and edges on the graph, as well as the appropriate witness objects. The $option_hash must contain either a 'file' or a 'string' argument with the XML to be parsed.

BUGS / TODO

•   More unit testing

•   Handle special designations apart from a.c.

•   Mark common nodes within collated variants

LICENSE
This package is free software and is provided "as is" without express or implied warranty. You can redistribute it and/or modify it under the same terms as Perl itself.

AUTHOR
Tara L Andrews <aurum@cpan.org>