see if we can make PAUSE skip indexing these modules
[bioperl-live.git] / Bio / Biblio / Book.pm
blobabfde653d2bc5a8681b8820c910bcd210b49898e
2 # BioPerl module for Bio::Biblio::Book
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::Book - Representation of a book
15 =head1 SYNOPSIS
17 $obj = Bio::Biblio::Book->new(-identifier => '123abc',
18 -editor => Bio::Biblio::Person->new
19 (-lastname => 'Loukides'),
20 -isbn => '0-596-00068-5');
21 #--- OR ---
23 $obj = Bio::Biblio::Book->new();
24 $obj->isbn ('0-596-00068-5');
26 =head1 DESCRIPTION
28 A storage object for a book.
29 See its place in the class hierarchy in
30 http://www.ebi.ac.uk/~senger/openbqs/images/bibobjects_perl.gif
32 =head2 Attributes
34 The following attributes are specific to this class
35 (however, you can also set and get all attributes defined in the parent classes):
37 edition
38 editor type: Bio::Biblio::Provider
39 isbn
40 series
41 title
42 volume
44 =head1 SEE ALSO
46 =over 4
48 =item *
50 OpenBQS home page: http://www.ebi.ac.uk/~senger/openbqs/
52 =item *
54 Comments to the Perl client: http://www.ebi.ac.uk/~senger/openbqs/Client_perl.html
56 =back
58 =head1 FEEDBACK
60 =head2 Mailing Lists
62 User feedback is an integral part of the evolution of this and other
63 Bioperl modules. Send your comments and suggestions preferably to
64 the Bioperl mailing list. Your participation is much appreciated.
66 bioperl-l@bioperl.org - General discussion
67 http://bioperl.org/wiki/Mailing_lists - About the mailing lists
69 =head2 Support
71 Please direct usage questions or support issues to the mailing list:
73 I<bioperl-l@bioperl.org>
75 rather than to the module maintainer directly. Many experienced and
76 reponsive experts will be able look at the problem and quickly
77 address it. Please include a thorough description of the problem
78 with code and data examples if at all possible.
80 =head2 Reporting Bugs
82 Report bugs to the Bioperl bug tracking system to help us keep track
83 of the bugs and their resolution. Bug reports can be submitted via the
84 web:
86 https://redmine.open-bio.org/projects/bioperl/
88 =head1 AUTHORS
90 Heikki Lehvaslaiho (heikki-at-bioperl-dot-org),
91 Martin Senger (senger@ebi.ac.uk)
93 =head1 COPYRIGHT
95 Copyright (c) 2002 European Bioinformatics Institute. All Rights Reserved.
97 This module is free software; you can redistribute it and/or modify
98 it under the same terms as Perl itself.
100 =head1 DISCLAIMER
102 This software is provided "as is" without warranty of any kind.
104 =cut
107 # Let the code begin...
110 package Bio::Biblio::Book;
111 use strict;
114 use base qw(Bio::Biblio::Ref);
117 # a closure with a list of allowed attribute names (these names
118 # correspond with the allowed 'get' and 'set' methods); each name also
119 # keep what type the attribute should be (use 'undef' if it is a
120 # simple scalar)
123 my %_allowed =
125 _edition => undef,
126 _editor => 'Bio::Biblio::Provider',
127 _isbn => undef,
128 _series => undef,
129 _title => undef,
130 _volume => undef,
133 # return 1 if $attr is allowed to be set/get in this class
134 sub _accessible {
135 my ($self, $attr) = @_;
136 exists $_allowed{$attr} or $self->SUPER::_accessible ($attr);
139 # return an expected type of given $attr
140 sub _attr_type {
141 my ($self, $attr) = @_;
142 if (exists $_allowed{$attr}) {
143 return $_allowed{$attr};
144 } else {
145 return $self->SUPER::_attr_type ($attr);
152 __END__