Main Page | Class Hierarchy | Class List | Class Members

kddml.Core.Scalar.KDDMLScalar Class Reference

Inheritance diagram for kddml.Core.Scalar.KDDMLScalar:

kddml.Core.KDDMLObject kddml.Core.Scalar.KDDMLScalarManager kddml.Core.HTMLTranslator List of all members.

Public Member Functions

 KDDMLScalar (java.io.File physical_path, String value)
 KDDMLScalar (String value)
KDDMLObjectType getType ()
void setScalarType (KDDMLScalarType t)
KDDMLScalarType getScalarType ()
boolean isEmpty ()
void saveToRepository () throws kddml.Core.KDDMLCoreException
String toString ()
void saveHTML () throws KDDMLCoreException
Object getScalarValue () throws KDDMLScalarException

Detailed Description

A KDDML scalar is a basic object that contains a number or a string constant and it incorporates the type of the object. This class is used by KDDML both to represent XML attributes and results of language operators that returns a sclar value. The KDDMLScalar class assumes by default that the type of the scalar is a java.lang.String.

Title: KDDML

Description: Knowledge Discovery in Database Environment

Copyright: Copyright (c) 2003-2005

Company: Universita' di Pisa - Dipartimento di Informatica

Author:
Andrea Romei (romei@di.unipi.it)
Version:
2.0.16


Constructor & Destructor Documentation

kddml.Core.Scalar.KDDMLScalar.KDDMLScalar java.io.File  physical_path,
String  value
 

Constructor to represent KDDMLScalar objects.

Parameters:
physical_path File the repository physical path containing the object.
value String the scalar value as String.

kddml.Core.Scalar.KDDMLScalar.KDDMLScalar String  value  ) 
 

Constructor used to represent XML attribute vaues.

Parameters:
value String


Member Function Documentation

KDDMLObjectType kddml.Core.Scalar.KDDMLScalar.getType  )  [virtual]
 

Returns the type of the object.

Returns:
KDDMLObjectType KDDML_SCALAR

Implements kddml.Core.KDDMLObject.

void kddml.Core.Scalar.KDDMLScalar.setScalarType KDDMLScalarType  t  ) 
 

Sets the type to this scalar object.

Parameters:
t KDDMLScalarType

Implements kddml.Core.Scalar.KDDMLScalarManager.

KDDMLScalarType kddml.Core.Scalar.KDDMLScalar.getScalarType  ) 
 

Returns the type related to this scalar object. The type belongs to a type returned by the KDDMLScalarTypeEnum enumeration.

Returns:
KDDMLScalarType

Implements kddml.Core.Scalar.KDDMLScalarManager.

boolean kddml.Core.Scalar.KDDMLScalar.isEmpty  )  [virtual]
 

Tests if the object is empty.

Returns:
boolean false.

Implements kddml.Core.KDDMLObject.

void kddml.Core.Scalar.KDDMLScalar.saveToRepository  )  throws kddml.Core.KDDMLCoreException [virtual]
 

Saves the object in the system repository. The destination path is provided by the object_path variable. If it is null, the method do nothing.

Exceptions:
KDDMLCoreException 

Implements kddml.Core.KDDMLObject.

String kddml.Core.Scalar.KDDMLScalar.toString  ) 
 

Returns a representation of this scalar as string.

Returns:
String

void kddml.Core.Scalar.KDDMLScalar.saveHTML  )  throws KDDMLCoreException [virtual]
 

Saves the object in the system repository as HTML document. The destination path is provided by the object_path variable. If it is null, the method do nothing.

Exceptions:
KDDMLCoreException 

Implements kddml.Core.HTMLTranslator.

Object kddml.Core.Scalar.KDDMLScalar.getScalarValue  )  throws KDDMLScalarException
 

Returns the evaluation of expression related to this scalar. The output value depends on the type of the scalar.
It returns a String if the method getScalarType() returns STRING.
It returns an Integer if the method getScalarType() returns an int INTEGER_RANGE.
It returns a Double if the method getScalarType() returns a real DOUBLE_RANGE.
It returns a String if the method getScalarType() returns ENUMERATION.
It returns a Integer[] if the method getScalarType() returns an int INTEGER_LIST.
It returns a Double[] if the method getScalarType() returns a real REAL_LIST.
It returns a String[] if the method getScalarType() returns a string STRING_LIST.
It returns a InputStream if the method getScalarType() returns a FILE_READER.
It returns a PrintWriter if the method getScalarType() returns a FILE_WRITER.
Throws an exception if the class type do not match with the scalar value type.

Returns:
Object
Exceptions:
KDDMLScalarException 

Implements kddml.Core.Scalar.KDDMLScalarManager.


Generated on Thu Feb 23 13:04:46 2006 for kddml by  doxygen 1.4.3