* add tests that check trucated sequence length matches the qual data
[bioperl-live.git] / Bio / Biblio / MedlineJournalArticle.pm
blob761ee88ea347931e86e6b8dd034050470bfc374b
2 # BioPerl module for Bio::Biblio::MedlineJournalArticle
4 # Please direct questions and support issues to <bioperl-l@bioperl.org>
6 # Cared for by Martin Senger <senger@ebi.ac.uk>
7 # For copyright and disclaimer see below.
9 # POD documentation - main docs before the code
11 =head1 NAME
13 Bio::Biblio::MedlineJournalArticle - Representation of a MEDLINE journal article
15 =head1 SYNOPSIS
17 $obj = Bio::Biblio::MedlineJournalArticle->new(
18 -title => 'Thermal adaptation analyzed by comparison of protein sequences from mesophilic and extremely thermophilic Methanococcus species.',
19 -journal => Bio::Biblio::MedlineJournal->new(-issn => '0027-8424'),
20 -volume => 96,
21 -issue => 7);
22 #--- OR ---
24 $obj = Bio::Biblio::MedlineJournalArticle->new();
25 $obj->title ('...');
26 $obj->journal (Bio::Biblio::MedlineJournal->new(-issn => '0027-8424'));
28 =head1 DESCRIPTION
30 A storage object for a MEDLINE journal article.
31 See its place in the class hierarchy in
32 http://www.ebi.ac.uk/~senger/openbqs/images/bibobjects_perl.gif
34 =head2 Attributes
36 The following attributes are specific to this class
37 (however, you can also set and get all attributes defined in the parent classes):
39 journal type: Bio::Biblio::MedlineJournal
41 =head1 SEE ALSO
43 =over 4
45 =item *
47 OpenBQS home page: http://www.ebi.ac.uk/~senger/openbqs/
49 =item *
51 Comments to the Perl client: http://www.ebi.ac.uk/~senger/openbqs/Client_perl.html
53 =back
55 =head1 FEEDBACK
57 =head2 Mailing Lists
59 User feedback is an integral part of the evolution of this and other
60 Bioperl modules. Send your comments and suggestions preferably to
61 the Bioperl mailing list. Your participation is much appreciated.
63 bioperl-l@bioperl.org - General discussion
64 http://bioperl.org/wiki/Mailing_lists - About the mailing lists
66 =head2 Support
68 Please direct usage questions or support issues to the mailing list:
70 I<bioperl-l@bioperl.org>
72 rather than to the module maintainer directly. Many experienced and
73 reponsive experts will be able look at the problem and quickly
74 address it. Please include a thorough description of the problem
75 with code and data examples if at all possible.
77 =head2 Reporting Bugs
79 Report bugs to the Bioperl bug tracking system to help us keep track
80 of the bugs and their resolution. Bug reports can be submitted via the
81 web:
83 https://redmine.open-bio.org/projects/bioperl/
85 =head1 AUTHORS
87 Heikki Lehvaslaiho (heikki-at-bioperl-dot-org),
88 Martin Senger (senger@ebi.ac.uk)
90 =head1 COPYRIGHT
92 Copyright (c) 2002 European Bioinformatics Institute. All Rights Reserved.
94 This module is free software; you can redistribute it and/or modify
95 it under the same terms as Perl itself.
97 =head1 DISCLAIMER
99 This software is provided "as is" without warranty of any kind.
101 =cut
104 # Let the code begin...
107 package Bio::Biblio::MedlineJournalArticle;
108 use strict;
109 use vars qw(@ISA);
112 use base qw(Bio::Biblio::MedlineArticle Bio::Biblio::JournalArticle);
115 # a closure with a list of allowed attribute names (these names
116 # correspond with the allowed 'get' and 'set' methods); each name also
117 # keep what type the attribute should be (use 'undef' if it is a
118 # simple scalar)
121 my %_allowed =
123 _journal => 'Bio::Biblio::MedlineJournal',
126 # return 1 if $attr is allowed to be set/get in this class
127 sub _accessible {
128 my ($self, $attr) = @_;
129 return 1 if exists $_allowed{$attr};
130 foreach my $parent (@ISA) {
131 return 1 if $parent->_accessible ($attr);
135 # return an expected type of given $attr
136 sub _attr_type {
137 my ($self, $attr) = @_;
138 if (exists $_allowed{$attr}) {
139 return $_allowed{$attr};
140 } else {
141 foreach my $parent (@ISA) {
142 if ($parent->_accessible ($attr)) {
143 return $parent->_attr_type ($attr);
147 return 'unknown';
153 __END__