Interface AlignmentToSamRecordFactory


  • public interface AlignmentToSamRecordFactory
    Factory for creating Alignment to htsjdk SAMRecord converters, which require late binding for a SAMFileHeader. Thus instead of a converter instance, a converter factory is available via injection:
     final class MyClass {
       private final AlignmentToSamRecordFactory alignmentToSamRecordFactory;
    
       @Inject
       MyClass(final AlignmentToSamRecordFactory alignmentToSamRecordFactory) {
         this.alignmentToSamRecordFactory = alignmentToSamRecordFactory;
       }
    
       void doIt() {
         Converter<Alignment, SAMRecord> converter = alignmentToSamRecordFactory.create(header);
         SAMRecord record = converter.convert(alignment, stringency, logger);
         // ...
     
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      Converter<org.bdgenomics.formats.avro.Alignment,​htsjdk.samtools.SAMRecord> create​(htsjdk.samtools.SAMFileHeader header)
      Create a new Alignment to htsjdk SAMRecord converter with the specified header.
    • Method Detail

      • create

        Converter<org.bdgenomics.formats.avro.Alignment,​htsjdk.samtools.SAMRecord> create​(htsjdk.samtools.SAMFileHeader header)
        Create a new Alignment to htsjdk SAMRecord converter with the specified header.
        Parameters:
        header - header, must not be null
        Returns:
        a new Alignment to htsjdk SAMRecord converter with the specified header