org.knime.core.data.xml
Class PMMLBlobCell

java.lang.Object
  extended by org.knime.core.data.DataCell
      extended by org.knime.core.data.container.BlobDataCell
          extended by org.knime.core.data.xml.PMMLBlobCell
All Implemented Interfaces:
Serializable, DataValue, StringValue, PMMLValue, XMLValue

public class PMMLBlobCell
extends BlobDataCell
implements PMMLValue, StringValue

BlobDataCell implementation that encapsulates a XMLCellContent.

Author:
Heiko Hofer, Dominik Morent
See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from interface org.knime.core.data.xml.XMLValue
XMLValue.XMLUtilityFactory
 
Nested classes/interfaces inherited from interface org.knime.core.data.DataValue
DataValue.UtilityFactory
 
Nested classes/interfaces inherited from interface org.knime.core.data.StringValue
StringValue.StringUtilityFactory
 
Field Summary
 
Fields inherited from class org.knime.core.data.container.BlobDataCell
USE_COMPRESSION
 
Fields inherited from interface org.knime.core.data.xml.XMLValue
UTILITY
 
Fields inherited from interface org.knime.core.data.StringValue
UTILITY
 
Constructor Summary
PMMLBlobCell(PMMLCellContent content)
          Create a new instance.
 
Method Summary
protected  boolean equalsDataCell(DataCell dc)
          Derived classes implement their specific equals function here.
static DataCellSerializer<PMMLBlobCell> getCellSerializer()
          Returns the serializer for PMML cells.
 Document getDocument()
          Returns the parsed XML document.
 List<Node> getModels()
          
 List<Node> getModels(org.knime.core.pmml.PMMLModelType type)
          
 Set<org.knime.core.pmml.PMMLModelType> getModelTypes()
          
 String getPMMLVersion()
          
static Class<? extends DataValue> getPreferredValueClass()
          Returns the preferred value class for PMML cells which is PMMLValue.
 String getStringValue()
          
 int hashCode()
          This method must be implemented in order to ensure that two equal DataCell objects return the same hash code.
 String toString()
          Returns the String representation of this cell's value.
 
Methods inherited from class org.knime.core.data.DataCell
equals, getType, isMissing
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

PMMLBlobCell

public PMMLBlobCell(PMMLCellContent content)
Create a new instance.

Parameters:
content - the content of this cell
Method Detail

getCellSerializer

public static DataCellSerializer<PMMLBlobCell> getCellSerializer()
Returns the serializer for PMML cells.

Returns:
a serializer

getPreferredValueClass

public static Class<? extends DataValue> getPreferredValueClass()
Returns the preferred value class for PMML cells which is PMMLValue.

Returns:
the preferred value class

getStringValue

public String getStringValue()

Specified by:
getStringValue in interface StringValue
Returns:
A String value.

getDocument

public Document getDocument()
Returns the parsed XML document.

Specified by:
getDocument in interface XMLValue
Returns:
the DOM

toString

public String toString()
Returns the String representation of this cell's value.

Specified by:
toString in class DataCell
Returns:
a String representation of this cell's value

equalsDataCell

protected boolean equalsDataCell(DataCell dc)
Derived classes implement their specific equals function here. The argument is guaranteed to be not null or a missing value, to be of the same class like this.

Specified by:
equalsDataCell in class DataCell
Parameters:
dc - the cell to compare this to
Returns:
true if this is equal to the argument, false if not

hashCode

public int hashCode()
This method must be implemented in order to ensure that two equal DataCell objects return the same hash code.

Specified by:
hashCode in class DataCell
Returns:
the hash code of your specific DataCell
See Also:
Object.hashCode(), DataCell.equals(java.lang.Object)

getPMMLVersion

public String getPMMLVersion()

Specified by:
getPMMLVersion in interface PMMLValue
Returns:
the PMML Version

getModelTypes

public Set<org.knime.core.pmml.PMMLModelType> getModelTypes()

Specified by:
getModelTypes in interface PMMLValue
Returns:
the types of the contained PMML models
See Also:
PMMLModelType

getModels

public List<Node> getModels(org.knime.core.pmml.PMMLModelType type)

Specified by:
getModels in interface PMMLValue
Parameters:
type - the model type of the models
Returns:
a list with all nodes of the specified model type or an empty list if there is no model of such a type

getModels

public List<Node> getModels()

Specified by:
getModels in interface PMMLValue
Returns:
a list with all pmml models


Copyright, 2003 - 2012. 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.