public Fastq build ( ) { if ( description == null ) { throw new IllegalStateException ( "description must not be null" ) ; } if ( sequence == null ) { throw new IllegalStateException ( "sequence must not be null" ) ; } if ( quality == null ) { throw new IllegalStateException ( "quality must not be null" ) ; } if ( ! sequenceAndQualityLengthsMatch ( ) ) { throw new IllegalStateException ( "sequence and quality scores must be the same length" ) ; } Fastq fastq = new Fastq ( description , sequence . toString ( ) , quality . toString ( ) , variant ) ; return fastq ; }
Build and return a new FASTQ formatted sequence configured from the properties of this builder .