Archive Ensembl HomeArchive Ensembl Home
DnaPepAlignFeature.pm
Go to the documentation of this file.
00001 =head1 LICENSE
00002 
00003   Copyright (c) 1999-2012 The European Bioinformatics Institute and
00004   Genome Research Limited.  All rights reserved.
00005 
00006   This software is distributed under a modified Apache license.
00007   For license details, please see
00008 
00009     http://www.ensembl.org/info/about/code_licence.html
00010 
00011 =head1 CONTACT
00012 
00013   Please email comments or questions to the public Ensembl
00014   developers list at <dev@ensembl.org>.
00015 
00016   Questions may also be sent to the Ensembl help desk at
00017   <helpdesk@ensembl.org>.
00018 
00019 =cut
00020 
00021 =head1 NAME
00022 
00023 Bio::EnsEMBL::DnaPepAlignFeature - Ensembl specific dna-pep pairwise
00024 alignment feature
00025 
00026 =head1 SYNOPSIS
00027 
00028   See BaseAlignFeature
00029 
00030 =cut 
00031 
00032 
00033 package Bio::EnsEMBL::DnaPepAlignFeature;
00034 
00035 use strict;
00036 
00037 use Bio::EnsEMBL::BaseAlignFeature;
00038 use Scalar::Util qw(weaken isweak);
00039 
00040 use vars qw(@ISA);
00041 
00042 @ISA = qw( Bio::EnsEMBL::BaseAlignFeature );
00043 
00044 
00045 =head2 new_fast
00046 
00047   Arg [1]    : hashref $hashref
00048                A hashref which will be blessed into a PepDnaAlignFeature. 
00049   Example    : none
00050   Description: This allows for very fast object creation when a large number 
00051                of DnaPepAlignFeatures needs to be created.  This is a bit of 
00052                a hack but necessary when thousands of features need to be
00053                generated within a couple of seconds for web display. It is
00054                not recommended that this method be called unless you know what
00055                you are doing.  It requires knowledge of the internals of this
00056                class and its superclasses.  
00057   Returntype : Bio::EnsEMBL::DnaPepAlignFeature
00058   Exceptions : none
00059   Caller     : Bio::EnsEMBL::DBSQL::ProteinAlignFeatureAdaptor
00060   Status     : Stable
00061 
00062 =cut
00063 
00064 sub new_fast {
00065   my ($class, $hashref) = @_;
00066   my $self = bless $hashref, $class;
00067   weaken($self->{adaptor})  if ( ! isweak($self->{adaptor}) );
00068   return $self;
00069 }
00070 
00071 
00072 =head2 _hit_unit
00073 
00074   Arg [1]    : none
00075   Example    : none
00076   Description: PRIVATE implementation of abstract superclass method.  Returns
00077                1 as the 'unit' used for the hit sequence. 
00078   Returntype : int
00079   Exceptions : none
00080   Caller     : Bio::EnsEMBL::BaseAlignFeature
00081   Status     : Stable
00082 
00083 
00084 =cut
00085 
00086 sub _hit_unit {
00087   return 1;
00088 }
00089 
00090 
00091 =head2 _query_unit
00092 
00093   Arg [1]    : none
00094   Example    : none
00095   Description: PRIVATE implementation of abstract superclass method.  Returns
00096                3 as the 'unit' used for the query sequence. 
00097   Returntype : int
00098   Exceptions : none
00099   Caller     : Bio::EnsEMBL::BaseAlignFeature
00100   Status     : Stable
00101 
00102 
00103 =cut
00104 
00105 sub _query_unit {
00106   return 3;
00107 }
00108 
00109 
00110 
00111 
00112 1;