[bug 2714]
[bioperl-live.git] / Bio / Biblio / Provider.pm
blobf1b17e1db04d2be532736eb33ea315624499b110
1 # $Id$
3 # BioPerl module for Bio::Biblio::Provider
5 # Cared for by Martin Senger <senger@ebi.ac.uk>
6 # For copyright and disclaimer see below.
8 # POD documentation - main docs before the code
10 =head1 NAME
12 Bio::Biblio::Provider - Representation of a general provider
14 =head1 SYNOPSIS
16 # usually this class is not instantiated but can be...
17 $obj = Bio::Biblio::Provider->new(-type => 'Department');
19 #--- OR ---
21 $obj = Bio::Biblio::Provider->new();
22 $obj->type ('Department');
24 =head1 DESCRIPTION
26 A storage object for a general bibliographic resource provider
27 (a rpovider can be a person, a organisation, or even a program).
29 =head2 Attributes
31 The following attributes are specific to this class,
32 and they are inherited by all provider types.
34 type
36 =head1 SEE ALSO
38 =over 4
40 =item *
42 OpenBQS home page: http://www.ebi.ac.uk/~senger/openbqs/
44 =item *
46 Comments to the Perl client: http://www.ebi.ac.uk/~senger/openbqs/Client_perl.html
48 =back
50 =head1 FEEDBACK
52 =head2 Mailing Lists
54 User feedback is an integral part of the evolution of this and other
55 Bioperl modules. Send your comments and suggestions preferably to
56 the Bioperl mailing list. Your participation is much appreciated.
58 bioperl-l@bioperl.org - General discussion
59 http://bioperl.org/wiki/Mailing_lists - About the mailing lists
61 =head2 Reporting Bugs
63 Report bugs to the Bioperl bug tracking system to help us keep track
64 of the bugs and their resolution. Bug reports can be submitted via the
65 web:
67 http://bugzilla.open-bio.org/
69 =head1 AUTHORS
71 Heikki Lehvaslaiho (heikki-at-bioperl-dot-org),
72 Martin Senger (senger@ebi.ac.uk)
74 =head1 COPYRIGHT
76 Copyright (c) 2002 European Bioinformatics Institute. All Rights Reserved.
78 This module is free software; you can redistribute it and/or modify
79 it under the same terms as Perl itself.
81 =head1 DISCLAIMER
83 This software is provided "as is" without warranty of any kind.
85 =cut
88 # Let the code begin...
91 package Bio::Biblio::Provider;
92 use strict;
93 use vars qw($AUTOLOAD);
96 use base qw(Bio::Biblio::BiblioBase);
99 # a closure with a list of allowed attribute names (these names
100 # correspond with the allowed 'get' and 'set' methods); each name also
101 # keep what type the attribute should be (use 'undef' if it is a
102 # simple scalar)
105 my %_allowed =
107 _type => undef,
110 # return 1 if $attr is allowed to be set/get in this class
111 sub _accessible {
112 my ($self, $attr) = @_;
113 exists $_allowed{$attr};
116 # return an expected type of given $attr
117 sub _attr_type {
118 my ($self, $attr) = @_;
119 $_allowed{$attr};
124 __END__