Version: ${maven.project.version}

org.soaplab.services.events
Class DefaultDeserializer

java.lang.Object
  extended by org.soaplab.services.events.DefaultDeserializer
All Implemented Interfaces:
EventConstants, EventDeserializer

public class DefaultDeserializer
extends java.lang.Object
implements EventConstants, EventDeserializer

A default implementation of the EventDeserializer that recognizes standard Soaplab events.

Version:
$Id: DefaultDeserializer.java,v 1.2 2007/04/19 22:17:05 marsenger Exp $
Author:
Martin Senger

Field Summary
 
Fields inherited from interface org.soaplab.services.events.EventConstants
ANALYSIS_EVENT, HEARTBEAT_PROGRESS, MESSAGE, NEW_STATE, PERCENT_PROGRESS, PERCENTAGE, PREVIOUS_STATE, REMAINING, STATE_CHANGED, STEP_PROGRESS, STEPS_COMPLETED, TIME_PROGRESS, TIMESTAMP, TIMESTAMP_FORMAT, TOTAL_STEPS
 
Constructor Summary
DefaultDeserializer()
           
 
Method Summary
 AnalysisEvent deserialize(java.lang.Object source, java.io.File xmlEventFile)
          Create an object representing an event from XML stored in given file.
 AnalysisEvent deserialize(java.lang.Object source, java.lang.String xmlEvent)
          Create an object representing an event from 'xmlEvent'.
static EventDeserializer getDeserializer()
          Find available deserializer, create its instance and return it.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultDeserializer

public DefaultDeserializer()
Method Detail

getDeserializer

public static EventDeserializer getDeserializer()
Find available deserializer, create its instance and return it. If not found return an instance of self.


deserialize

public AnalysisEvent deserialize(java.lang.Object source,
                                 java.lang.String xmlEvent)
                          throws SoaplabException
Description copied from interface: EventDeserializer
Create an object representing an event from 'xmlEvent'.

Specified by:
deserialize in interface EventDeserializer
Parameters:
source - is a source of this event; can be null if the source is not known (this is here because event serialization, the XML string, does not contain any event source)
xmlEvent - is a serialized event
Returns:
an event created from input parameters
Throws:
SoaplabException - if something prevents to create an event

deserialize

public AnalysisEvent deserialize(java.lang.Object source,
                                 java.io.File xmlEventFile)
                          throws SoaplabException
Description copied from interface: EventDeserializer
Create an object representing an event from XML stored in given file.

Otherwise the same as the EventDeserializer.deserialize(Object,String) method.

Specified by:
deserialize in interface EventDeserializer
Throws:
SoaplabException

Version: ${maven.project.version}

Submit a bug or feature
Generated: Tue Jun 14 15:18:14 AST 2011