BibTeX::Entry - Contains a single entry of a BibTeX document.
Version 0.01
This class ist a wrapper for a single BibTeX entry. It is usually created by a BibTeX::Parser.
use BibTeX::Parser::Entry; my $entry = BibTeX::Parser::Entry->new($type, $key, $parse_ok, \%fields); if ($entry->parse_ok) { my $type = $entry->type; my $key = $enty->key; print $entry->field("title"); my @authors = $entry->author; my @editors = $entry->editor; ... }
Create new entry.
If the entry was correctly parsed, this method returns a true value, false otherwise.
Return the error message, if the entry could not be parsed or undef otherwise.
Get or set the type of the entry, eg. 'ARTICLE' or 'BOOK'. Return value is always uppercase.
Get or set the reference key of the entry.
Get or set the contents of a field. The first parameter is the name of the field, the second (optional) value is the new value.
Get or set the authors. Returns an array of BibTeX::Author objects. The parameters can either be BibTeX::Author objects or strings.
Note: You can also change the authors with $entry->field('author', $authors_string)
Get or set the editors. Returns an array of BibTeX::Author objects. The parameters can either be BibTeX::Author objects or strings.
Note: You can also change the authors with $entry->field('editor', $editors_string)
Returns a list of all the fields used in this entry.
Returns a true value if this entry has a value for $fieldname.
Gerhard Gossen, <gerhard.gossen at googlemail.com>
<gerhard.gossen at googlemail.com>
Please report any bugs or feature requests to bug-bibtex-entry at rt.cpan.org, or through the web interface at http://rt.cpan.org/NoAuth/ReportBug.html?Queue=BibTeX-Parser. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes.
bug-bibtex-entry at rt.cpan.org
You can find documentation for this module with the perldoc command.
perldoc BibTeX::Parser
You can also look for information at:
RT: CPAN's request tracker
http://rt.cpan.org/NoAuth/Bugs.html?Dist=BibTeX-Parser
AnnoCPAN: Annotated CPAN documentation
http://annocpan.org/dist/BibTeX-Parser
CPAN Ratings
http://cpanratings.perl.org/d/BibTeX-Parser
Search CPAN
http://search.cpan.org/dist/BibTeX-Parser
Copyright 2008 Gerhard Gossen, all rights reserved.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
To install BibTeX::Parser, copy and paste the appropriate command in to your terminal.
cpanm
cpanm BibTeX::Parser
CPAN shell
perl -MCPAN -e shell install BibTeX::Parser
For more information on module installation, please visit the detailed CPAN module installation guide.