Changes

From Genome Analysis Wiki
Jump to navigationJump to search
no edit summary
Line 23: Line 23:  
=== Setting fields in the Header ===
 
=== Setting fields in the Header ===
 
The '''SamFileHeader''' class contains accessors to set the header lines of a SAM/BAM header.  By using these set methods to setup the header, they can be pulled back out using the get accessors or the header can be later written to a SAM/BAM file.
 
The '''SamFileHeader''' class contains accessors to set the header lines of a SAM/BAM header.  By using these set methods to setup the header, they can be pulled back out using the get accessors or the header can be later written to a SAM/BAM file.
 +
 +
==== Copying a Header ====
 +
These three methods are ways of copying the contents of one header into another one.
 +
{| style="margin: 1em 1em 1em 0; background-color: #f9f9f9; border: 1px #aaa solid; border-collapse: collapse;" border="1"
 +
|-style="background: #f2f2f2; text-align: center;"
 +
! Method Name !!  Description
 +
|-
 +
| <code>bool SamFileHeader::copy(const SamFileHeader& header)</code>
 +
| Copy method copies the specified header into this one.
 +
|-
 +
|<code>SamFileHeader::SamFileHeader(const SamFileHeader& header)</code>
 +
| Copy constructor copies the specified header into this one.
 +
|-
 +
|<code>SamFileHeader & SamFileHeader::operator = (const SamFileHeader& header)</code>
 +
| operator= copies the specified header into this one.
 +
|}
    
==== Adding an entire Header Line ====
 
==== Adding an entire Header Line ====

Navigation menu