changes all issue tracking in preparation for switch to github issues
[bioperl-live.git] / Bio / Restriction / Enzyme / MultiCut.pm
blob3f27154200633a78df92c986c52e7ae3ebed3d94
1 #------------------------------------------------------------------
3 # BioPerl module Bio::Restriction::Enzyme::MultiCut
5 # Please direct questions and support issues to <bioperl-l@bioperl.org>
7 # Cared for by Heikki Lehvaslaiho, heikki-at-bioperl-dot-org
9 # You may distribute this module under the same terms as perl itself
10 #------------------------------------------------------------------
12 ## POD Documentation:
14 =head1 NAME
16 Bio::Restriction::Enzyme::MultiCut - A single restriction endonuclease
18 =head1 SYNOPSIS
20 # set up a single restriction enzyme. This contains lots of
21 # information about the enzyme that is generally parsed from a
22 # rebase file and can then be read back
24 use Bio::Restriction::Enzyme;
27 =head1 DESCRIPTION
29 This module defines a restriction endonuclease class where one object
30 represents one of the distinct recognition sites for that enzyme. The
31 method L<others|others> stores references to other objects with
32 alternative sites.
34 In this schema each object within an EnzymeCollection can be checked
35 for matching a sequence.
38 REBASE report notation C<Bsp24I (8/13)GACNNNNNNTGG(12/7)> means:
41 Bsp24I
42 5' ^NNNNNNNNGACNNNNNNTGGNNNNNNNNNNNN^ 3'
43 3' ^NNNNNNNNNNNNNCTGNNNNNNACCNNNNNNN^ 5'
48 =head1 FEEDBACK
50 =head2 Mailing Lists
52 User feedback is an integral part of the evolution of this and other
53 Bioperl modules. Send your comments and suggestions preferably to one
54 of the Bioperl mailing lists. Your participation is much appreciated.
56 bioperl-l@bioperl.org - General discussion
57 http://bioperl.org/wiki/Mailing_lists - About the mailing lists
59 =head2 Support
61 Please direct usage questions or support issues to the mailing list:
63 I<bioperl-l@bioperl.org>
65 rather than to the module maintainer directly. Many experienced and
66 reponsive experts will be able look at the problem and quickly
67 address it. Please include a thorough description of the problem
68 with code and data examples if at all possible.
70 =head2 Reporting Bugs
72 Report bugs to the Bioperl bug tracking system to help us keep track
73 the bugs and their resolution. Bug reports can be submitted via the
74 web:
76 https://github.com/bioperl/bioperl-live/issues
78 =head1 AUTHOR
80 Heikki Lehvaslaiho, heikki-at-bioperl-dot-org
82 =head1 CONTRIBUTORS
84 Rob Edwards, redwards@utmem.edu
86 =head1 COPYRIGHT
88 Copyright (c) 2003 Rob Edwards.
90 Some of this work is Copyright (c) 1997-2002 Steve A. Chervitz. All
91 Rights Reserved. This module is free software; you can redistribute
92 it and/or modify it under the same terms as Perl itself.
94 =head1 SEE ALSO
96 L<Bio::Restriction::Enzyme>, L<Bio::Restriction::Analysis>,
97 L<Bio::Restriction::EnzymeCollection>
99 =head1 APPENDIX
101 Methods beginning with a leading underscore are considered private and
102 are intended for internal use by this module. They are not considered
103 part of the public interface and are described here for documentation
104 purposes only.
106 =cut
108 package Bio::Restriction::Enzyme::MultiCut;
109 use strict;
111 use Data::Dumper;
113 use vars qw ();
114 use base qw(Bio::Restriction::Enzyme);
117 =head2 new
119 Title : new
120 Function
121 Function : Initializes the enzyme object
122 Returns : The Restriction::Enzyme::MultiCut object
123 Argument :
125 =cut
127 sub new {
128 my($class, @args) = @_;
129 my $self = $class->SUPER::new(@args);
131 my ($others) =
132 $self->_rearrange([qw(
133 OTHERS
134 )], @args);
136 $others && $self->others($others);
137 return $self;
140 =head2 others
142 Title : others
143 Usage : $re->others(@enz_obj_array);
144 Function : Stores auxiliary Enzyme::MultiCut objects for multicutting enzymes
145 Arguments : optional array of Enzyme::MultiCut objects
146 Returns : array of Enzyme objects
149 Added for compatibility to REBASE
151 =cut
153 sub others {
154 my $self = shift;
155 push @{$self->{_others}}, @_ if @_;
156 return unless $self->{_others};
157 return @{$self->{'_others'}};
161 =head2 purge_others
163 Title : purge_others
164 Usage : $re->purge_references();
165 Function : Purges the set of references for this enzyme
166 Arguments :
167 Returns :
169 =cut
171 sub purge_others {
172 my ($self) = shift;
173 $self->{_others} = [];