Changes

From Genome Analysis Wiki
Jump to: navigation, search

LibStatGen: BAM

364 bytes added, 15:09, 25 March 2010
no edit summary
// Successfully read a record from the file, so check to see
// if it is valid.
if(samRecord.isValid(samHeader))
{
// It is valid, so write it.
// Successfully read a record from the file, so check to see
// if it is valid.
if(samRecord.isValid(samHeader))
{
// It is valid, so write it.
Returns true if successfully set, false if not.
|-
| bool setReferenceIDsetReferenceName(int referenceIDSamFileHeader& header, const char* referenceName)| Sets the reference sequence idname. The reference name id is not currently stored. A map to calculated using the header needs to be done to get this (which is done when writing a SAM file). THIS is an opportunity for improvement.
Returns true if successfully set, false if not.
|-
Returns true if successfully set, false if not.
|-
| bool setMateReferenceIDsetMateReferenceName(int mateReferenceIDSamFileHeader& header, const char* referenceName)| Sets the mate reference sequence idname. The mate reference name id is not currently stored. A map to calculated using the header needs to be done to get this (which is done when writing a SAM file). THIS is an opportunity for improvement.
Returns true if successfully set, false if not.
|-
! width=""|Description
|-
| bool isValid(SamFileHeader& header)
| Returns true if the record is valid. This performs validation steps. TODO: the method exists, but it does not yet perform any checks, so just returns true.
|-
| int getBlockSize()
| Returns the BAM block size of the record.
|-
| const char* getReferenceName()
| Returns the reference sequence name (SAM format).
|-
| int getReferenceID()
| Returns the reference sequence id ID (BAM format).
|-
| int get1BasedPosition()
| int getReadLength()
| Returns the length of the read.
|-
| const char* getMateReferenceName()
| Returns the mate reference sequence name (SAM format). Returns the mate reference sequence name even if it is the same as the reference sequence name.
|-
| const char* getMateReferenceNameOrEqual()
| Returns the mate reference sequence name (SAM format). Returns the mate reference sequence name, unless it is the same as the reference sequence name, then an "=" is returned..
|-
| int getMateReferenceID()

Navigation menu