4 # This module is licensed under the same terms as Perl itself. You use,
5 # modify, and redistribute it under the terms of the Perl Artistic License.
10 Bio::DescribableI - interface for objects with human readable names and descriptions
15 # to test this is a describable object
17 $obj->isa("Bio::DescribableI") ||
18 $obj->throw("$obj does not implement the Bio::DescribableI interface");
22 $name = $obj->display_name();
23 $desc = $obj->description();
29 This interface describes methods expected on describable objects, ie
30 ones which have human displayable names and descriptions
36 User feedback is an integral part of the evolution of this and other
37 Bioperl modules. Send your comments and suggestions preferably to one
38 of the Bioperl mailing lists. Your participation is much appreciated.
40 bioperl-l@bioperl.org - General discussion
41 http://bioperl.org/wiki/Mailing_lists - About the mailing lists
45 Report bugs to the Bioperl bug tracking system to help us keep track
46 the bugs and their resolution. Bug reports can be submitted via the web:
48 http://bugzilla.open-bio.org/
50 =head1 AUTHOR - Ewan Birney
52 Email birney@sanger.ac.uk
56 package Bio
::DescribableI
;
60 use base
qw(Bio::Root::RootI);
62 =head1 Implementation Specific Functions
64 These functions are the ones that a specific implementation must
70 Usage : $string = $obj->display_name()
71 Function: A string which is what should be displayed to the user
72 the string should have no spaces (ideally, though a cautious
73 user of this interface would not assumme this) and should be
74 less than thirty characters (though again, double checking
83 $self->throw_not_implemented();
90 Usage : $string = $obj->description()
91 Function: A text string suitable for displaying to the user a
92 description. This string is likely to have spaces, but
93 should not have any newlines or formatting - just plain
94 text. The string should not be greater than 255 characters
95 and clients can feel justified at truncating strings at 255
96 characters for the purposes of display
104 $self->throw_not_implemented();