org.knime.base.node.io.pmml.read
Class PMMLImport

java.lang.Object
  extended by org.knime.base.node.io.pmml.read.PMMLImport

public class PMMLImport
extends Object

Author:
Fabian Dill, University of Konstanz

Constructor Summary
PMMLImport(File file)
           
PMMLImport(File file, ErrorHandler errorHandler)
          Reads the passed file, checks the PMML version, the PMML model type, and namespace and also validates the file against the schema, then creates the PMMLPortObjectSpec and PMMLPortObject from the content of the file.
 
Method Summary
 PMMLPortObject getPortObject()
           
 PMMLPortObjectSpec getPortObjectSpec()
           
static boolean isModelSupported(File file)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PMMLImport

public PMMLImport(File file,
                  ErrorHandler errorHandler)
           throws SAXException
Reads the passed file, checks the PMML version, the PMML model type, and namespace and also validates the file against the schema, then creates the PMMLPortObjectSpec and PMMLPortObject from the content of the file.

Parameters:
file - containing the PMML model
errorHandler - error handler used during parsing
Throws:
SAXException - if something goes wrong (wrong version, unsupported model type or invalid file)

PMMLImport

public PMMLImport(File file)
           throws SAXException
Parameters:
file - containing the PMML model
Throws:
SAXException - if something goes wrong
See Also:
with default error handler: {@link LoggingErrorHandler}.
Method Detail

isModelSupported

public static boolean isModelSupported(File file)
                                throws SAXException
Parameters:
file - the file containing the PMML model
Returns:
true if the type of model is supported by the current platform configuration
Throws:
SAXException - if something goes wrong

getPortObjectSpec

public PMMLPortObjectSpec getPortObjectSpec()
Returns:
the parsed port object spec (data dictionary and mining schema)

getPortObject

public PMMLPortObject getPortObject()
Returns:
the parsed PMML model


Copyright, 2003 - 2010. All rights reserved.
University of Konstanz, Germany.
Chair for Bioinformatics and Information Mining, Prof. Dr. Michael R. Berthold.
You may not modify, publish, transmit, transfer or sell, reproduce, create derivative works from, distribute, perform, display, or in any way exploit any of the content, in whole or in part, except as otherwise expressly permitted in writing by the copyright owner or as specified in the license file distributed with this product.