~ubuntu-branches/ubuntu/hoary/bioperl/hoary

« back to all changes in this revision

Viewing changes to Bio/SeqFeature/Gene/NC_Feature.pm

  • Committer: Bazaar Package Importer
  • Author(s): Matt Hope
  • Date: 2004-04-18 14:24:11 UTC
  • mfrom: (1.2.1 upstream) (2.1.1 warty)
  • Revision ID: james.westby@ubuntu.com-20040418142411-gr92uexquw4w8liq
Tags: 1.4-1
* New upstream release
* Examples and working code are installed by default to usr/bin,
  this has been moved to usr/share/doc/bioperl/bin

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
# $Id: NC_Feature.pm,v 1.2 2001/11/20 02:09:37 lstein Exp $
 
1
# $Id: NC_Feature.pm,v 1.8 2003/05/15 08:30:30 lapp Exp $
2
2
#
3
3
# BioPerl module for Bio::SeqFeature::Gene::NC_Feature.pm
4
4
#
40
40
email or the web:
41
41
 
42
42
  bioperl-bugs@bioperl.org
43
 
  http://bioperl.org/bioperl-bugs/
 
43
  http://bugzilla.bioperl.org/
44
44
 
45
45
=head1 AUTHOR - David Block
46
46
 
47
 
Email dblock@gene.pbi.nrc.ca
 
47
Email dblock@gnf.org
48
48
 
49
49
Describe contact details here
50
50
 
71
71
use Bio::SeqFeature::Generic;
72
72
 
73
73
@ISA = qw(Bio::SeqFeature::Generic);
 
74
 
74
75
sub new {
75
 
  my($class,@args) = @_;
76
 
 
77
 
  my $self = $class->SUPER::new(@args);
78
 
 
 
76
    my($class,@args) = @_;
 
77
    
 
78
    my $self = $class->SUPER::new(@args);
 
79
 
 
80
    my ($is_coding) =
 
81
        $self->_rearrange([qw(IS_CODING)],@args);
 
82
    # default is non-coding
 
83
    $self->is_coding(defined($is_coding) ? $is_coding : 0);
 
84
 
 
85
    return $self;
79
86
}
80
87
 
81
88
 
83
90
=head2 is_coding
84
91
 
85
92
 Title   : is_coding
86
 
  Usage   : if ($feature->is_coding()) {
 
93
 Usage   : if ($feature->is_coding()) {
87
94
                     #do something
88
95
            }
89
96
 Function: Whether or not the feature codes for amino acid.
90
97
 Returns : FALSE
91
98
 Args    : none
92
99
 
93
 
 
94
100
=cut
95
101
 
96
 
sub is_coding {
97
 
   my ($self,@args) = @_;
98
 
   return;
 
102
sub is_coding{
 
103
    my $self = shift;
 
104
 
 
105
    return $self->{'is_coding'} = shift if @_;
 
106
    return $self->{'is_coding'};
99
107
}
100
108
 
101
109
=head2 cds