#include <Feature_AMOS.hh>
Inheritance diagram for AMOS::Feature_t:
Public Member Functions | |
| Feature_t () | |
| Constructs an empty Feature_t object. | |
| Feature_t (const Feature_t &source) | |
| Copy constructor. | |
| ~Feature_t () | |
| Destroys a Feature_t object. | |
| virtual void | clear () |
| Clears all object data, reinitializes the object. | |
| virtual NCode_t | getNCode () const |
| Get the AMOS NCode type identifier. | |
| Range_t | getRange () const |
| Get the feature range. | |
| std::pair< ID_t, NCode_t > | getSource () const |
| Get the feature source IID and type. | |
| FeatureType_t | getType () const |
| Get the feature type. | |
| void | setRange (Range_t range) |
| Set the feature range. | |
| void | setSource (std::pair< ID_t, NCode_t > source) |
| Set the feature source IID and type. | |
| void | setType (FeatureType_t type) |
| Set the feature type. | |
| virtual void | readMessage (const Message_t &msg) |
| Reads in data from a Message object. | |
| virtual void | writeMessage (Message_t &msg) const |
| Writes data to a Message object. | |
| const std::string & | getComment () const |
| Get the comment string. | |
| const Status_t | getStatus () const |
| Get the status value. | |
| void | setComment (const std::string &comment) |
| Set the comment string. | |
| void | setStatus (Status_t status) |
| Set the status value. | |
| const std::string & | getEID () const |
| Get the external ID. | |
| ID_t | getIID () const |
| Get the internal ID. | |
| bool | isRemoved () const |
| Check if the object is waiting to be removed from the bank. | |
| bool | isModified () const |
| Check if the object has been modified. | |
| bool | isFlagA () const |
| Check the value of flag A. | |
| bool | isFlagB () const |
| Check the value of flag B. | |
| void | setEID (const std::string &eid) |
| Set the external ID. | |
| void | setFlagA (bool flag) |
| Set flag A. | |
| void | setFlagB (bool flag) |
| Set flag B. | |
| void | setIID (ID_t iid) |
| Set the internal ID. | |
Static Public Attributes | |
| static const NCode_t | NCODE = M_FEATURE |
| The NCode type identifier for this object. | |
| static const FeatureType_t | NULL_FEATURE = 0 |
| static const FeatureType_t | REPEAT = 'R' |
| static const FeatureType_t | UNITIG = 'U' |
| static const FeatureType_t | JOIN = 'J' |
| static const FeatureType_t | ORF = 'O' |
| static const FeatureType_t | FIX = 'F' |
| static const FeatureType_t | COVERAGE = 'C' |
| static const FeatureType_t | POLYMORPHISM = 'P' |
| static const FeatureType_t | BREAKPOINT = 'B' |
| static const FeatureType_t | KMER = 'K' |
| static const FeatureType_t | MATEPAIR = 'M' |
| static const FeatureType_t | MISASSEMBLY = 'A' |
Protected Member Functions | |
| virtual void | readRecord (std::istream &fix, std::istream &var) |
| Read selected class members from a biserial record. | |
| virtual void | readRecordFix (std::istream &fix) |
| Read selected class members from a fixed store only. | |
| virtual void | writeRecord (std::ostream &fix, std::ostream &var) const |
| Write selected class members to a biserial record. | |
Protected Attributes | |
| ID_t | iid_m |
| internal ID (integer AMOS identifier) | |
| std::string | eid_m |
| external ID (anything you want sans newlines) | |
| BankFlags_t | flags_m |
| bank flags, derived classes may use "nibble" | |
Allows a range from some other Universal object to be flagged as a feature. One example would be a location on a contig where a repeat is known to exist. Multiple repeat features with the same consensus could then be grouped together with the Group object to represent a repeat class,
Definition at line 31 of file Feature_AMOS.hh.
| AMOS::Feature_t::Feature_t | ( | ) | [inline] |
Constructs an empty Feature_t object.
Sets all members to zero or NULL
Definition at line 81 of file Feature_AMOS.hh.
References NULL_FEATURE, AMOS::NULL_ID, and AMOS::NULL_NCODE.
| AMOS::Feature_t::Feature_t | ( | const Feature_t & | source | ) | [inline] |
| AMOS::Feature_t::~Feature_t | ( | ) | [inline] |
| virtual void AMOS::Feature_t::clear | ( | ) | [inline, virtual] |
Clears all object data, reinitializes the object.
Reimplemented from AMOS::Universal_t.
Definition at line 108 of file Feature_AMOS.hh.
References NULL_FEATURE, AMOS::NULL_ID, and AMOS::NULL_NCODE.
Referenced by readMessage(), and writeMessage().
| const std::string& AMOS::Universal_t::getComment | ( | ) | const [inline, inherited] |
Get the comment string.
Definition at line 116 of file Universal_AMOS.hh.
Referenced by AMOS::operator<<().
| const std::string& AMOS::IBankable_t::getEID | ( | ) | const [inline, inherited] |
Get the external ID.
Definition at line 174 of file Bank_AMOS.hh.
References AMOS::IBankable_t::eid_m.
Referenced by AMOS::TiledRead_t::TiledRead_t().
| ID_t AMOS::IBankable_t::getIID | ( | ) | const [inline, inherited] |
Get the internal ID.
Definition at line 185 of file Bank_AMOS.hh.
References AMOS::IBankable_t::iid_m.
Referenced by AMOS::Index_t::buildContigFeature(), AMOS::Index_t::buildContigScaffold(), AMOS::Index_t::buildReadContig(), AMOS::Index_t::buildReadLibrary(), AMOS::Index_t::buildScaffoldFeature(), and AMOS::operator<<().
| virtual NCode_t AMOS::Feature_t::getNCode | ( | ) | const [inline, virtual] |
Get the AMOS NCode type identifier.
Reimplemented from AMOS::Universal_t.
Definition at line 118 of file Feature_AMOS.hh.
References NCODE.
| Range_t AMOS::Feature_t::getRange | ( | ) | const [inline] |
Get the feature source IID and type.
This method only returns the IID of the object which this feature refers to. The entire source object can be obtained by fetching the returned IID from the specified bank type.
Definition at line 144 of file Feature_AMOS.hh.
| const Status_t AMOS::Universal_t::getStatus | ( | ) | const [inline, inherited] |
| FeatureType_t AMOS::Feature_t::getType | ( | ) | const [inline] |
| bool AMOS::IBankable_t::isFlagA | ( | ) | const [inline, inherited] |
Check the value of flag A.
Definition at line 228 of file Bank_AMOS.hh.
References AMOS::IBankable_t::flags_m.
Referenced by AMOS::Universal_t::writeMessage(), and AMOS::Overlap_t::writeMessage().
| bool AMOS::IBankable_t::isFlagB | ( | ) | const [inline, inherited] |
Check the value of flag B.
Definition at line 239 of file Bank_AMOS.hh.
References AMOS::IBankable_t::flags_m.
Referenced by AMOS::Universal_t::writeMessage(), and AMOS::Overlap_t::writeMessage().
| bool AMOS::IBankable_t::isModified | ( | ) | const [inline, inherited] |
Check if the object has been modified.
Definition at line 217 of file Bank_AMOS.hh.
References AMOS::IBankable_t::flags_m.
| bool AMOS::IBankable_t::isRemoved | ( | ) | const [inline, inherited] |
Check if the object is waiting to be removed from the bank.
Definition at line 206 of file Bank_AMOS.hh.
References AMOS::IBankable_t::flags_m.
| void Feature_t::readMessage | ( | const Message_t & | msg | ) | [virtual] |
Reads in data from a Message object.
Reads the data contained in a Message object and stores it in the Messagable object. Will not complain if incoming message is of the wrong type, will only try and suck out the fields it recognizes. All previous data in the Messagable object will be cleared or overwritten.
| msg | The Message to read from |
| ArgumentException_t |
Reimplemented from AMOS::Universal_t.
Definition at line 21 of file Feature_AMOS.cc.
References AMOS_THROW_ARGUMENT, clear(), AMOS::Encode(), AMOS::F_CLEAR, AMOS::F_SOURCE, AMOS::F_TYPE, AMOS::NCODE_SIZE, and AMOS::Universal_t::readMessage().
| virtual void AMOS::Feature_t::readRecord | ( | std::istream & | fix, | |
| std::istream & | var | |||
| ) | [protected, virtual] |
Read selected class members from a biserial record.
Reads the fixed and variable length streams from a biserial record and initializes the class members to the values stored within. Used in translating a biserial IBankable object, and needed to retrieve objects from a bank.
| fix | The fixed length stream (stores all fixed length members) | |
| var | The variable length stream (stores all var length members) |
The get pointer of var is at the beginning of the record
Reimplemented from AMOS::Universal_t.
| virtual void AMOS::Feature_t::readRecordFix | ( | std::istream & | fix | ) | [protected, virtual] |
Read selected class members from a fixed store only.
Reads the fixed stream and initializes the class members to the values stored within. Used to fetch the fixed portion of a biserial IBankable object, and needed to retrieve objects from a bank.
| fix | The fixed length stream (stores all fixed length members) |
Reimplemented from AMOS::Universal_t.
| void AMOS::Universal_t::setComment | ( | const std::string & | comment | ) | [inline, inherited] |
Set the comment string.
| comment | The new comment string |
Definition at line 150 of file Universal_AMOS.hh.
| void AMOS::IBankable_t::setEID | ( | const std::string & | eid | ) | [inline, inherited] |
Set the external ID.
Will only use the characters up to but not including the first newline.
Definition at line 252 of file Bank_AMOS.hh.
References AMOS::IBankable_t::eid_m, and AMOS::NL_CHAR.
| void AMOS::IBankable_t::setFlagA | ( | bool | flag | ) | [inline, inherited] |
Set flag A.
Has no effect on the actual object in memory other than setting a flag. This is one of two user accessible flags to be used as needed, the other is flag B.
| flag | The new flag A value |
Definition at line 272 of file Bank_AMOS.hh.
References AMOS::IBankable_t::flags_m.
Referenced by AMOS::Universal_t::readMessage(), and AMOS::Overlap_t::readMessage().
| void AMOS::IBankable_t::setFlagB | ( | bool | flag | ) | [inline, inherited] |
Set flag B.
Has no effect on the actual object in memory other than setting a flag. This is one of two user accessible flags to be used as needed, the other is flag A.
| flag | The new flag B value |
Definition at line 288 of file Bank_AMOS.hh.
References AMOS::IBankable_t::flags_m.
Referenced by AMOS::Universal_t::readMessage(), and AMOS::Overlap_t::readMessage().
| void AMOS::IBankable_t::setIID | ( | ID_t | iid | ) | [inline, inherited] |
Set the internal ID.
| iid | The new internal ID |
Definition at line 300 of file Bank_AMOS.hh.
References AMOS::IBankable_t::iid_m.
| void AMOS::Feature_t::setRange | ( | Range_t | range | ) | [inline] |
Set the feature range.
| range | The new feature range |
Definition at line 167 of file Feature_AMOS.hh.
Set the feature source IID and type.
| source | The new IID and NCode type identifier of the feature source |
Definition at line 179 of file Feature_AMOS.hh.
| void AMOS::Universal_t::setStatus | ( | Status_t | status | ) | [inline, inherited] |
Set the status value.
| status | The new status value |
Definition at line 162 of file Universal_AMOS.hh.
Referenced by AMOS::Universal_t::readMessage().
| void AMOS::Feature_t::setType | ( | FeatureType_t | type | ) | [inline] |
Set the feature type.
| type | The new feature type |
Definition at line 191 of file Feature_AMOS.hh.
| void Feature_t::writeMessage | ( | Message_t & | msg | ) | const [virtual] |
Writes data to a Message object.
Writes the data contained in a Messagable object to a Message object. All previous data in the Message will be cleared or overwritten.
| msg | The Message to write to |
Reimplemented from AMOS::Universal_t.
Definition at line 95 of file Feature_AMOS.cc.
References clear(), AMOS::Decode(), AMOS::F_CLEAR, AMOS::F_SOURCE, AMOS::F_TYPE, NCODE, NULL_FEATURE, AMOS::NULL_ID, AMOS::NULL_NCODE, AMOS::NULL_STRING, and AMOS::Universal_t::writeMessage().
| virtual void AMOS::Feature_t::writeRecord | ( | std::ostream & | fix, | |
| std::ostream & | var | |||
| ) | const [protected, virtual] |
Write selected class members to a biserial record.
Writes the fixed and variable length streams to a biserial record. Used in generating a biserial IBankable object, and needed to commit objects to a bank. Should not write the flags, EID, or IID of the object because the bank will handle the storage of these fields on its own.
| fix | The fixed length stream (stores all fixed length members) | |
| var | The variable length stream (stores all var length members) |
Reimplemented from AMOS::Universal_t.
const FeatureType_t AMOS::Feature_t::BREAKPOINT = 'B' [static] |
Definition at line 70 of file Feature_AMOS.hh.
const FeatureType_t AMOS::Feature_t::COVERAGE = 'C' [static] |
Definition at line 68 of file Feature_AMOS.hh.
std::string AMOS::IBankable_t::eid_m [protected, inherited] |
external ID (anything you want sans newlines)
Definition at line 66 of file Bank_AMOS.hh.
Referenced by AMOS::Bank_t::append(), AMOS::IBankable_t::clear(), AMOS::IBankable_t::getEID(), AMOS::BankStream_t::operator<<(), AMOS::BankStream_t::operator>>(), AMOS::Universal_t::readMessage(), AMOS::BankStream_t::replace(), AMOS::Bank_t::replace(), AMOS::BankStream_t::replaceByBID(), AMOS::IBankable_t::setEID(), and AMOS::Universal_t::writeMessage().
const FeatureType_t AMOS::Feature_t::FIX = 'F' [static] |
Definition at line 65 of file Feature_AMOS.hh.
BankFlags_t AMOS::IBankable_t::flags_m [protected, inherited] |
bank flags, derived classes may use "nibble"
Definition at line 68 of file Bank_AMOS.hh.
Referenced by AMOS::Bank_t::appendBID(), AMOS::Sequence_t::clear(), AMOS::IBankable_t::clear(), AMOS::Sequence_t::compress(), AMOS::Bank_t::fetchBID(), AMOS::Bank_t::fetchBIDFix(), AMOS::Overlap_t::getAdjacency(), AMOS::Link_t::getAdjacency(), AMOS::Sequence_t::isCompressed(), AMOS::IBankable_t::isFlagA(), AMOS::IBankable_t::isFlagB(), AMOS::Overlap_t::isFlagC(), AMOS::IBankable_t::isModified(), AMOS::IBankable_t::isRemoved(), AMOS::BankStream_t::operator<<(), AMOS::BankStream_t::operator>>(), AMOS::Bank_t::replaceBID(), AMOS::Overlap_t::setAdjacency(), AMOS::Link_t::setAdjacency(), AMOS::IBankable_t::setFlagA(), AMOS::IBankable_t::setFlagB(), AMOS::Overlap_t::setFlagC(), and AMOS::Sequence_t::uncompress().
ID_t AMOS::IBankable_t::iid_m [protected, inherited] |
internal ID (integer AMOS identifier)
Definition at line 64 of file Bank_AMOS.hh.
Referenced by AMOS::Bank_t::append(), AMOS::IBankable_t::clear(), AMOS::IBankable_t::getIID(), AMOS::IBankable_t::IBankable_t(), AMOS::BankStream_t::operator<<(), AMOS::BankStream_t::operator>>(), AMOS::Universal_t::readMessage(), AMOS::BankStream_t::replace(), AMOS::Bank_t::replace(), AMOS::BankStream_t::replaceByBID(), AMOS::IBankable_t::setIID(), and AMOS::Universal_t::writeMessage().
const FeatureType_t AMOS::Feature_t::JOIN = 'J' [static] |
Definition at line 63 of file Feature_AMOS.hh.
const FeatureType_t AMOS::Feature_t::KMER = 'K' [static] |
Definition at line 71 of file Feature_AMOS.hh.
const FeatureType_t AMOS::Feature_t::MATEPAIR = 'M' [static] |
Definition at line 72 of file Feature_AMOS.hh.
const FeatureType_t AMOS::Feature_t::MISASSEMBLY = 'A' [static] |
Definition at line 73 of file Feature_AMOS.hh.
const NCode_t Feature_t::NCODE = M_FEATURE [static] |
The NCode type identifier for this object.
Reimplemented from AMOS::Universal_t.
Definition at line 58 of file Feature_AMOS.hh.
Referenced by AMOS::Index_t::buildContigFeature(), AMOS::Index_t::buildScaffoldFeature(), getNCode(), and writeMessage().
const FeatureType_t AMOS::Feature_t::NULL_FEATURE = 0 [static] |
Definition at line 60 of file Feature_AMOS.hh.
Referenced by clear(), Feature_t(), and writeMessage().
const FeatureType_t AMOS::Feature_t::ORF = 'O' [static] |
Definition at line 64 of file Feature_AMOS.hh.
const FeatureType_t AMOS::Feature_t::POLYMORPHISM = 'P' [static] |
Definition at line 69 of file Feature_AMOS.hh.
const FeatureType_t AMOS::Feature_t::REPEAT = 'R' [static] |
Definition at line 61 of file Feature_AMOS.hh.
const FeatureType_t AMOS::Feature_t::UNITIG = 'U' [static] |
Definition at line 62 of file Feature_AMOS.hh.
1.4.7