NAME
Text::BibTeX::Structure - check/enforce database structure in BibTeX entries
SYNOPSIS
DESCRIPTION
(Please do not use this module; it will be replaced with a completely different interface in release 0.3 of Text::BibTeX. It's here for temporary backwards compatability with release 0.2.)
Text::BibTeX::Structure
takes care of checking that BibTeX entries adhere to some pre-specified database structure, and optionally coercing them into compliance with that structure. It does this by maintaining, for a given database structure, the list of allowed entry types, and required and optional fields for each of the entry types.
For example, the `bibliography' structure -- an extension of the structure implicit in the original BibTeX's standard style files -- includes entry types such as article
, book
, and inproceedings
; the required fields for article
-type entries are author
, title
, journal
, and year
, and the optional fields are volume
, number
, pages
, month
, and note
. (Complete details of the `bibliography' structure will be documented elsewhere. Likewise, the method for creating new database structures will be documented elsewhere. Neither of these documents yet exist, so don't bother looking for them.)
Users can create new database structures using an as-yet-unspecified definition file. This allows the database structure to be defined explicitly and independently of the output format (`style file'), in contrast to the original BibTeX.
DETAILS
Traditional subroutines
- find_structure (STRUCT)
-
Searches the space of known database structures for the one named by STRUCT. (STRUCT might itself be a description of a database structure, in which case it is returned without further processing.)
Currently the only known database structure is `bibliography'; eventually this will be extended to search a user-extendible collection of on-line structure definitions.
Methods of Text::BibTeX::Structure
class
- dump
-
Dumps a structure definition. Format is suspiciously similar to that used to describe the BibTeX structure in A Guide to LaTeX2e, Appendix B. Probably also quite similar to what I'll require the input file to look like.
NAME is the name of the structure; it must be supplied. STRUCTURE is a complete structure definition, as returned by the mythical
read_structure
; if it is not supplied, then the structure associated with NAME is looked up in the global list of known structures. Croaks if this lookup fails. - read FILE
-
Reads a structure definition from a file. No clue how it'll work yet.
- known_type
- required_fields
- optional_fields
Methods of Text::BibTeX::Entry
class
- check_type
- check_required_fields
- check_optional_fields
- check
- coerce
- silently_corce
1 POD Error
The following errors were encountered while parsing the POD:
- Around line 375:
=over without closing =back