#include <gnMultiSpec.h>
Inheritance diagram for gnMultiSpec::
Public Methods | |
gnMultiSpec () | |
virtual | ~gnMultiSpec () |
Destructor, frees memory. More... | |
virtual gnMultiSpec* | Clone () const=0 |
virtual gnSeqI | GetLength () const |
Get the length of all the sequence data covered by this spec. More... | |
virtual void | CropStart (gnSeqI cropLen) |
Crop the first cropLen bases from the sequence. More... | |
virtual void | CropEnd (gnSeqI cropLen) |
Crop the last cropLen bases from the sequence. More... | |
virtual string | GetSourceName () const |
virtual void | SetSourceName (const string &sourceName) |
virtual void | Clear () |
Clears all data from this spec. More... | |
virtual boolean | SeqRead (const gnSeqI start, gnSeqC *buf, uint32 &bufLen, const uint32 contigI) const |
Reads sequence data from this spec. More... | |
virtual uint32 | GetSpecListLength () const=0 |
Returns the number of subspecs this spec contains. More... | |
virtual gnBaseSpec* | GetSpec (const uint32 i) const=0 |
Get the spec at index i in the list of subspecs. More... | |
virtual gnBaseSpec* | GetSpecByBase (const gnSeqI baseI) const=0 |
Get the spec from the list of subspecs which contains the specified base pair. More... | |
virtual uint32 | GetSpecIndexByBase (const gnSeqI baseI) const |
Get the index of the subspec which contains the specified base pair. More... | |
virtual uint32 | GetSpecIndexByName (const string &name) const |
Get the index of the spec which has the given name. More... | |
virtual gnSeqI | GetSpecStartBase (const uint32 specI) const |
Get the starting base pair, in this spec's sequence, of the given subspec. More... | |
virtual gnSeqI | GetSpecEndBase (const uint32 specI) const |
Get the ending base pair, in this spec's sequence, of the given subspec. More... | |
virtual void | AddSpec (gnBaseSpec *spec, const uint32 i=UINT32_MAX)=0 |
Add a subspec to this spec. More... | |
virtual void | RemoveSpec (uint32 i)=0 |
Remove a subspec from this spec. More... | |
virtual uint32 | GetHeaderListLength () const |
Returns the number of headers this spec contains. More... | |
virtual void | AddHeader (gnBaseHeader *head, const uint32 i=UINT32_MAX) |
Add a header to this spec, adds to the end of the header list by default. More... | |
virtual gnBaseHeader* | GetHeader (const uint32 i) const |
Get the headers at index i in the list of headers. More... | |
virtual gnBaseHeader* | GetHeader (const string &name, uint32 &i) const |
Find the first header with the specified name, starting at index i. More... | |
virtual void | RemoveHeader (uint32 i) |
Remove a header from this spec. More... | |
uint32 | AddFeature (gnBaseFeature *feat) |
Add a feature to this spec. More... | |
virtual uint32 | GetFeatureListLength () const=0 |
Returns the number of features this spec contains. More... | |
virtual gnBaseFeature* | GetFeature (const uint32 i) const=0 |
Get the feature at index i in the list of features. More... | |
virtual void | GetContainedFeatures (const gnLocation <, vector< gnBaseFeature *> &feature_vector, vector< uint32 > &index_vector) const=0 |
Creates a list of all features which are contained by coordinates specified. More... | |
virtual void | GetIntersectingFeatures (const gnLocation <, vector< gnBaseFeature *> &feature_vector, vector< uint32 > &index_vector) const=0 |
Creates a list of all features which intersect the coordinates specified. More... | |
virtual void | GetBrokenFeatures (const gnLocation <, vector< gnBaseFeature *> &feature_vector) const=0 |
Creates a list of features which may have been broken by an edit. More... | |
virtual void | RemoveFeature (const uint32 i)=0 |
Remove a feature from this spec. More... | |
Protected Attributes | |
string | m_sourceName |
vector<gnBaseHeader*> | m_headerList |
Definition at line 30 of file gnMultiSpec.h.
|
Definition at line 33 of file gnMultiSpec.h. |
|
Destructor, frees memory.
Definition at line 37 of file gnMultiSpec.h. |
|
Add a feature to this spec.
Reimplemented in gnFragmentSpec, and gnGenomeSpec. |
|
Add a header to this spec, adds to the end of the header list by default.
Definition at line 126 of file gnMultiSpec.cpp. Referenced by gnFASSource::GetSpec(), gnSEQSource::ParseStream(), gnGBKSource::ParseStream(), and gnSequence::addHeader().
|
|
Add a subspec to this spec. Throws an exception if the insertion index i is out of range
Reimplemented in gnFragmentSpec, and gnGenomeSpec. |
|
Clears all data from this spec.
Reimplemented from gnBaseSpec. Reimplemented in gnFragmentSpec, and gnGenomeSpec. Definition at line 24 of file gnMultiSpec.cpp. Referenced by gnGenomeSpec::Clear(), and gnFragmentSpec::Clear().
|
|
Reimplemented from gnBaseSpec. Reimplemented in gnFragmentSpec, and gnGenomeSpec. |
|
Crop the last cropLen bases from the sequence. CropEnd will delete features and headers associated with the cropped bases.
Reimplemented from gnBaseSpec. Reimplemented in gnFragmentSpec. Definition at line 105 of file gnMultiSpec.cpp. Referenced by gnFragmentSpec::CropEnd(), gnSequence::erase(), gnSequence::insert(), and gnSequence::splitContig().
|
|
Crop the first cropLen bases from the sequence. CropStart will delete features and headers associated with the cropped bases.
Reimplemented from gnBaseSpec. Reimplemented in gnFragmentSpec. Definition at line 86 of file gnMultiSpec.cpp. Referenced by gnFragmentSpec::CropStart(), gnSequence::insert(), and gnSequence::splitContig().
|
|
Creates a list of features which may have been broken by an edit.
Reimplemented in gnFragmentSpec, and gnGenomeSpec. |
|
Creates a list of all features which are contained by coordinates specified.
Reimplemented in gnFragmentSpec, and gnGenomeSpec. |
|
Get the feature at index i in the list of features.
Reimplemented in gnFragmentSpec, and gnGenomeSpec. |
|
Returns the number of features this spec contains.
Reimplemented in gnFragmentSpec, and gnGenomeSpec. |
|
Find the first header with the specified name, starting at index i.
Definition at line 132 of file gnMultiSpec.cpp. |
|
Get the headers at index i in the list of headers. Throws a HeaderIndexOutOfBounds exception if a nonexistant header is referenced
Definition at line 199 of file gnMultiSpec.h. Referenced by gnGBKSource::Write(), gnFASSource::Write(), gnDNXSource::Write(), gnGBKSource::WriteHeader(), and gnSequence::getHeader().
|
|
Returns the number of headers this spec contains.
Definition at line 194 of file gnMultiSpec.h. Referenced by gnSEQSource::ParseStream(), gnGBKSource::ParseStream(), gnGBKSource::Write(), and gnSequence::getHeaderListLength().
|
|
Creates a list of all features which intersect the coordinates specified.
Reimplemented in gnFragmentSpec, and gnGenomeSpec. |
|
Get the length of all the sequence data covered by this spec.
Reimplemented from gnBaseSpec. Definition at line 33 of file gnMultiSpec.cpp. Referenced by gnGenomeSpec::AddFeature(), gnGenomeSpec::CloneRange(), gnFragmentSpec::CloneRange(), CropEnd(), gnGenomeSpec::GetBrokenFeatures(), gnGenomeSpec::GetContainedFeatures(), gnSEQSource::GetContigSeqLength(), gnGBKSource::GetContigSeqLength(), gnDNXSource::GetContigSeqLength(), gnGenomeSpec::GetIntersectingFeatures(), gnGBKSource::Write(), gnSequence::contigLength(), gnSequence::erase(), gnSequence::insert(), gnSequence::length(), and gnSequence::size().
|
|
Definition at line 208 of file gnMultiSpec.h. Referenced by gnDNXSource::Write().
|
|
Get the spec at index i in the list of subspecs.
Reimplemented in gnFragmentSpec, and gnGenomeSpec. Referenced by CropEnd(), CropStart(), GetLength(), GetSpecEndBase(), GetSpecIndexByBase(), GetSpecIndexByName(), GetSpecStartBase(), and SeqRead().
|
|
Get the spec from the list of subspecs which contains the specified base pair.
Reimplemented in gnFragmentSpec, and gnGenomeSpec. |
|
Get the ending base pair, in this spec's sequence, of the given subspec.
Definition at line 74 of file gnMultiSpec.cpp. |
|
Get the index of the subspec which contains the specified base pair.
Definition at line 42 of file gnMultiSpec.cpp. Referenced by gnGenomeSpec::CloneRange(), gnFragmentSpec::CloneRange(), gnGenomeSpec::GetSpecByBase(), gnFragmentSpec::GetSpecByBase(), gnSequence::contigIndexByBase(), and gnSequence::globalToSource().
|
|
Get the index of the spec which has the given name.
Definition at line 53 of file gnMultiSpec.cpp. Referenced by gnSequence::contigByName(), and gnSequence::contigIndexByName().
|
|
Returns the number of subspecs this spec contains.
Reimplemented in gnFragmentSpec, and gnGenomeSpec. Referenced by CropEnd(), CropStart(), GetLength(), GetSpecEndBase(), GetSpecIndexByBase(), GetSpecIndexByName(), GetSpecStartBase(), gnGenomeSpec::RemoveSpec(), gnFragmentSpec::RemoveSpec(), and SeqRead().
|
|
Get the starting base pair, in this spec's sequence, of the given subspec.
Definition at line 62 of file gnMultiSpec.cpp. Referenced by gnGenomeSpec::CloneRange(), gnFragmentSpec::CloneRange(), gnGenomeSpec::GetFeature(), gnSequence::contigStart(), and gnSequence::globalToSource().
|
|
Remove a feature from this spec.
Reimplemented in gnFragmentSpec, and gnGenomeSpec. |
|
Remove a header from this spec. Throws a HeaderIndexOutOfBounds exception if a nonexistant header is referenced
Definition at line 140 of file gnMultiSpec.cpp. Referenced by gnSequence::removeHeader().
|
|
Remove a subspec from this spec.
Reimplemented in gnFragmentSpec, and gnGenomeSpec. Referenced by CropEnd(), and CropStart().
|
|
Reads sequence data from this spec. SeqRead will attempt to read "bufLen" base pairs starting at "start", an offset into the sequence. Reading inside a specific contig can be accomplished by supplying the "contigI" parameter with a valid contig index. SeqRead stores the sequence data in "buf" and returns the actual number of bases read in "bufLen". SeqRead will return false if a serious error occurs.
Reimplemented from gnBaseSpec. Definition at line 148 of file gnMultiSpec.cpp. Referenced by gnSequence::GetSeqC(), gnDNXSource::SeqRead(), gnSequence::ToArray(), and gnSequence::ToString().
|
|
Definition at line 213 of file gnMultiSpec.h. Referenced by gnFASSource::GetSpec(), and gnDNXSource::ParseStream().
|
|
Definition at line 188 of file gnMultiSpec.h. |
|
Reimplemented from gnBaseSpec. Definition at line 186 of file gnMultiSpec.h. |