TPTP 4.4.0 Platform Project
Public API Specification

org.eclipse.hyades.models.common.export.util.impl
Class TPFTestSuiteSerializer

java.lang.Object
  extended byorg.eclipse.hyades.models.common.export.util.impl.XMLSerializer
      extended byorg.eclipse.hyades.models.common.export.util.impl.TPFTestSuiteSerializer
All Implemented Interfaces:
ISerializer

public class TPFTestSuiteSerializer
extends XMLSerializer


Field Summary
protected  boolean constrainDates
           
protected  java.util.Stack containsVerdicts
           
protected  long endTime
           
static java.lang.String LF
           
protected  boolean onlyConsiderMostRecentResult
           
protected  int[] overallVerdict
           
static java.lang.String RESPONSE_URL
           
protected  long startTime
           
protected  int[] suiteVerdict
           
static java.lang.String TIME
           
 
Fields inherited from class org.eclipse.hyades.models.common.export.util.impl.XMLSerializer
content, dom, format, indent, os, parent, parentStack
 
Constructor Summary
TPFTestSuiteSerializer(org.eclipse.emf.common.util.EList content)
          Constructor that takes in a list of EMF objects (the source model) and an outputstream.
TPFTestSuiteSerializer(org.eclipse.emf.common.util.EList content, java.io.OutputStream os)
          Constructor that takes in a list of EMF objects (the source model) and an outputstream.
 
Method Summary
protected  org.eclipse.emf.common.util.EList buildTestSuiteList()
           
protected  void cleanup()
           
protected  org.w3c.dom.Element createElement(java.lang.Object element, boolean root)
          Constructs an XML element based on an object
static java.util.List findAllReferencedTestSuites(TPFTestSuite testSuite)
          Recursively resolves all referenced test suites from the parameter root test suite.
 long getEndTime()
           
 long getStartTime()
           
protected  void init()
          Initialize serializer.
 boolean isConstrainDates()
           
protected  boolean isContainsVerdict()
           
 boolean isOnlyConsiderMostRecentResult()
           
protected  void recurseGenerate(org.eclipse.emf.common.util.EList list, boolean root)
          Helper function that processes the list of elements during serialization.
protected  void resetVerdict()
           
 void serialize(org.eclipse.emf.common.util.EList content, java.util.List[] allExecutionResults)
          This method will serialize the contents of the EMF test model to a DOM representation.
 void serialize(org.eclipse.emf.common.util.EList content, java.util.List[] allExecutionResults, java.util.Properties properties)
           
 void serialize(java.io.OutputStream out)
          This method will serialize the contents of the EMF test model to a DOM representation.
 void serialize(java.io.OutputStream out, java.util.Properties properties)
           
 void setConstrainDates(boolean constrainDates)
           
 void setEndTime(long endTime)
           
 void setOnlyConsiderMostRecentResult(boolean onlyConsiderMostRecentResult)
           
protected  void setParentContainsVerdict(boolean flag)
           
 void setStartTime(long startTime)
           
protected  void setVerdict(boolean flag)
           
 
Methods inherited from class org.eclipse.hyades.models.common.export.util.impl.XMLSerializer
appendTextNode, beginTag, beginTag, createDocument, decode, endTag, endTag, getDom, getIndent, isFormat, serializeGeneratedDocument, serializeGeneratedDocumentToString, setAttribute, setFormat, setIndent
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

RESPONSE_URL

public static final java.lang.String RESPONSE_URL
See Also:
Constant Field Values

TIME

public static final java.lang.String TIME
See Also:
Constant Field Values

LF

public static final java.lang.String LF
See Also:
Constant Field Values

onlyConsiderMostRecentResult

protected boolean onlyConsiderMostRecentResult

constrainDates

protected boolean constrainDates

suiteVerdict

protected int[] suiteVerdict

overallVerdict

protected int[] overallVerdict

containsVerdicts

protected java.util.Stack containsVerdicts

startTime

protected long startTime

endTime

protected long endTime
Constructor Detail

TPFTestSuiteSerializer

public TPFTestSuiteSerializer(org.eclipse.emf.common.util.EList content,
                              java.io.OutputStream os)
Constructor that takes in a list of EMF objects (the source model) and an outputstream.

Parameters:
content - a list of EMF objects to serialize
os - the outputstream to serialize to

TPFTestSuiteSerializer

public TPFTestSuiteSerializer(org.eclipse.emf.common.util.EList content)
Constructor that takes in a list of EMF objects (the source model) and an outputstream.

Parameters:
content - a list of EMF objects to serialize
Method Detail

init

protected void init()
Initialize serializer.


cleanup

protected void cleanup()

isContainsVerdict

protected boolean isContainsVerdict()

setParentContainsVerdict

protected void setParentContainsVerdict(boolean flag)

setVerdict

protected void setVerdict(boolean flag)

resetVerdict

protected void resetVerdict()

isOnlyConsiderMostRecentResult

public boolean isOnlyConsiderMostRecentResult()

setOnlyConsiderMostRecentResult

public void setOnlyConsiderMostRecentResult(boolean onlyConsiderMostRecentResult)

serialize

public void serialize(java.io.OutputStream out)
This method will serialize the contents of the EMF test model to a DOM representation. After this method is processed the DOM reprentation can be extracted using the getDOM method.

See Also:
org.eclipse.hyades.test.tools.ui.common.internal.report.ISerializer#serialize()

serialize

public void serialize(java.io.OutputStream out,
                      java.util.Properties properties)

buildTestSuiteList

protected org.eclipse.emf.common.util.EList buildTestSuiteList()

findAllReferencedTestSuites

public static java.util.List findAllReferencedTestSuites(TPFTestSuite testSuite)
Recursively resolves all referenced test suites from the parameter root test suite.

Parameters:
testSuite - The root test suite.
Returns:
The list of all recursively referenced test suites, including the root grandparent test suite.

serialize

public void serialize(org.eclipse.emf.common.util.EList content,
                      java.util.List[] allExecutionResults)
This method will serialize the contents of the EMF test model to a DOM representation. After this method is processed the DOM reprentation can be extracted using the getDOM method.

See Also:
org.eclipse.hyades.test.tools.ui.common.internal.report.ISerializer#serialize()

serialize

public void serialize(org.eclipse.emf.common.util.EList content,
                      java.util.List[] allExecutionResults,
                      java.util.Properties properties)

recurseGenerate

protected void recurseGenerate(org.eclipse.emf.common.util.EList list,
                               boolean root)
Helper function that processes the list of elements during serialization.

Parameters:
list -

createElement

protected org.w3c.dom.Element createElement(java.lang.Object element,
                                            boolean root)
Constructs an XML element based on an object

Specified by:
createElement in class XMLSerializer
Parameters:
element - object that is used to construct the XML element
Returns:
XML element representation of the object provided

getEndTime

public long getEndTime()

setEndTime

public void setEndTime(long endTime)

getStartTime

public long getStartTime()

setStartTime

public void setStartTime(long startTime)

isConstrainDates

public boolean isConstrainDates()

setConstrainDates

public void setConstrainDates(boolean constrainDates)

TPTP 4.4.0 Platform Project
Public API Specification