[mary-dev] Fwd: LsfFileHeader and MfccFileHeader
i30817 at gmail.com
Tue Mar 17 22:57:58 CET 2009
---------- Forwarded message ----------
From: Paulo Levi <i30817 at gmail.com>
Date: Tue, Mar 17, 2009 at 7:07 PM
Subject: LsfFileHeader and MfccFileHeader
To: mary-users <mary-users at dfki.de>
I was looking at the useless casts and instanceof's in these header objects,
and found the readHeader override and the superclass (FeatureFileHeader)
readHeader doesn't do sanity checks. In on case it ignores a null
MaryRandomAccessFile argument and doesn't read the header at all
(LsfFileHeader). In the other two it throws a npe.
Also the function takes a parameter to close the randomaccess file (but
doesnt close on exception).
Should i introduce sanitychecks and refactor the methods to close even if it
throw a exception?
I'm going to commit the casts removal.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Mary-dev