|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectde.jstacs.AnnotatedEntity
de.jstacs.results.Result
de.jstacs.results.StorableResult
public class StorableResult
Class for Result
s that are Storable
s. The method
AnnotatedEntity.toXML()
is used to save the StorableResult
together with the
result to an XML representation, or in the method toString()
.
Storable
Field Summary | |
---|---|
static byte |
FALSE
The model/classifier has not been trained. |
static byte |
NA
The Storable cannot be trained anyway. |
static byte |
TRUE
The model/classifier has been trained. |
Fields inherited from class de.jstacs.AnnotatedEntity |
---|
comment, datatype, name |
Constructor Summary | |
---|---|
StorableResult(StringBuffer buf)
The standard constructor for the interface Storable . |
|
StorableResult(String name,
String comment,
Storable object)
Creates a result for an XML representation of an object. |
Method Summary | |
---|---|
protected void |
appendFurtherInfos(StringBuffer buf)
This method can be used in the method Storable.toXML() to extract
further information (name, comment, datatype). |
protected void |
extractFurtherInfos(StringBuffer representation)
This method can be used in the constructor with parameter StringBuffer to
extract the further information. |
String |
getClassName()
Returns the name of the class of the Storable corresponding to
the XML representation stored in this StorableResult . |
Storable |
getResultInstance()
Returns the instance of the Storable that is the result of this
StorableResult . |
String |
getValue()
Returns the value of the AnnotatedEntity . |
String |
getXMLTag()
This method returns a tag used as outer tag of the XML description. |
byte |
isInitialized()
Returns TRUE if the model or classifier was trained when
obtaining its XML representation stored in this StorableResult ,
FALSE if it was not, and NA if the object could not be
trained anyway. |
String |
toString()
|
Methods inherited from class de.jstacs.results.Result |
---|
checkDatatype, createResult, isCastableResult, isComparableResult |
Methods inherited from class de.jstacs.AnnotatedEntity |
---|
getComment, getDatatype, getName, toXML |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final byte NA
Storable
cannot be trained anyway.
public static final byte FALSE
public static final byte TRUE
Constructor Detail |
---|
public StorableResult(String name, String comment, Storable object)
name
- the name of the resultcomment
- a comment on the resultobject
- the Storable
that is the resultpublic StorableResult(StringBuffer buf) throws NonParsableException
Storable
.
Constructs a new StorableResult
from its XML representation as
returned by AnnotatedEntity.toXML()
.
buf
- the XML representation as StringBuffer
NonParsableException
- if buf
could not be parsedMethod Detail |
---|
public byte isInitialized()
TRUE
if the model or classifier was trained when
obtaining its XML representation stored in this StorableResult
,
FALSE
if it was not, and NA
if the object could not be
trained anyway.
public String getClassName()
Storable
corresponding to
the XML representation stored in this StorableResult
.
public String getValue()
AnnotatedEntity
AnnotatedEntity
.
getValue
in class AnnotatedEntity
AnnotatedEntity
public Storable getResultInstance()
Storable
that is the result of this
StorableResult
.
public String getXMLTag()
AnnotatedEntity
getXMLTag
in class AnnotatedEntity
protected void appendFurtherInfos(StringBuffer buf)
AnnotatedEntity
Storable.toXML()
to extract
further information (name, comment, datatype).
appendFurtherInfos
in class AnnotatedEntity
buf
- a XML representation of the main information as
StringBuffer
Storable.toXML()
protected void extractFurtherInfos(StringBuffer representation) throws NonParsableException
AnnotatedEntity
StringBuffer
to
extract the further information.
extractFurtherInfos
in class AnnotatedEntity
representation
- a XML represenation of the main information as
StringBuffer
NonParsableException
- if the XML representation is not parsableAnnotatedEntity.AnnotatedEntity(StringBuffer)
public String toString()
toString
in class Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |