File tree Expand file tree Collapse file tree 2 files changed +7
-5
lines changed
Expand file tree Collapse file tree 2 files changed +7
-5
lines changed Original file line number Diff line number Diff line change @@ -161,7 +161,7 @@ simpler for the most common use-cases.
161161` FASTA fasta = parser.next(); `
162162` // fasta contains a complete FASTA record. `
163163` } `
164- ` reader .close(); `
164+ ` parser .close(); `
165165
166166### Converting the FASTA sequence into DNA sequence
167167
@@ -177,12 +177,13 @@ simpler for the most common use-cases.
177177
178178` ThingParser ` <FASTA >` parser = ThingParserFactory. `
179179` getWriteParser(FASTA.format, new File("/path/to/my/fasta.fa"), fasta); `
180- ` parser.parseAll(); `
180+ ` parser.parseAll(); `
181+ ` parser.close(); `
181182
182183### Writing a FASTA file (the hard way)
183184
184185` FASTAEmitter emitter = new FASTAEmitter(fasta); `
185186` FASTAWriter writer = new FASTAFileWriter(new File("/path/to/new/fasta.fa")); `
186187` ThingParser ` <FASTA >` parser = new ThingParser ` <FASTA >` (emitter, writer); `
187188` parser.parseAll(); `
188- ` writer .close(); `
189+ ` parser .close(); `
Original file line number Diff line number Diff line change @@ -145,7 +145,7 @@ Convenience wrapper classes are provided to make the parsing process simpler for
145145 FASTA fasta = parser.next();
146146 // fasta contains a complete FASTA record.
147147 }
148- reader .close();
148+ parser .close();
149149
150150=== Converting the FASTA sequence into DNA sequence ===
151151
@@ -162,11 +162,12 @@ Convenience wrapper classes are provided to make the parsing process simpler for
162162 ThingParser<FASTA> parser = ThingParserFactory.
163163 getWriteParser(FASTA.format, new File("/path/to/my/fasta.fa"), fasta);
164164 parser.parseAll();
165+ parser.close();
165166
166167=== Writing a FASTA file (the hard way) ===
167168
168169 FASTAEmitter emitter = new FASTAEmitter(fasta);
169170 FASTAWriter writer = new FASTAFileWriter(new File("/path/to/new/fasta.fa"));
170171 ThingParser<FASTA> parser = new ThingParser<FASTA>(emitter, writer);
171172 parser.parseAll();
172- writer .close();
173+ parser .close();
You can’t perform that action at this time.
0 commit comments