Package pulse.io.readers
Class QuadratureReader
- java.lang.Object
-
- pulse.io.readers.QuadratureReader
-
- All Implemented Interfaces:
AbstractHandler,AbstractReader<OrdinateSet>,Reflexive
public class QuadratureReader extends Object implements AbstractReader<OrdinateSet>
A reader, which convertsquadfiles into instancesOrdinateSet. Invoked at program start and reads through the associated resource folder.
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static QuadratureReadergetInstance()Returns the single instance of this class.StringgetSupportedExtension()Retrieves the supported extension of files, which thisAbstractHandleris able to process.OrdinateSetread(File file)Reads an ordinate set.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface pulse.io.readers.AbstractHandler
isExtensionSupported
-
-
-
-
Method Detail
-
read
public OrdinateSet read(File file) throws IOException
Reads an ordinate set. Scans the first line for any keywords and then treats any subsequent lines as consisting of two tokens, which correspond to the quadrature node and weight. Ignores all other information.- Specified by:
readin interfaceAbstractReader<OrdinateSet>- Parameters:
file- a file which has readable content- Returns:
- a
Tobject created by reading all information fromf. - Throws:
IOException
-
getSupportedExtension
public String getSupportedExtension()
Description copied from interface:AbstractHandlerRetrieves the supported extension of files, which thisAbstractHandleris able to process.- Specified by:
getSupportedExtensionin interfaceAbstractHandler- Returns:
quad
-
getInstance
public static QuadratureReader getInstance()
Returns the single instance of this class.- Returns:
- an instance of
QuadratureReader.
-
-