de.unikassel.android.sdcframework.data.independent
Class AbstractSampleData

Package class diagram package AbstractSampleData
java.lang.Object
  extended by de.unikassel.android.sdcframework.data.independent.AbstractSampleData
All Implemented Interfaces:
SampleData, SerializableData
Direct Known Subclasses:
AccelerometerSampleData, BluetoothSampleData, FileReferenceSampleData, GSMSampleData, GyroscopeSampleData, LightSampleData, LocationSampleData, MagneticFieldSampleData, OrientationSampleData, PressureSampleData, ProximitySampleData, TemperatureSampleData, TextSampleData, TimeProviderSampleData, TwitterSampleData, WifiSampleData

public abstract class AbstractSampleData
extends Object
implements SampleData

Abstract base class for sample data types


Constructor Summary
AbstractSampleData()
          Constructor
 
Method Summary
protected  Object clone()
           
 String getRelatedData()
          Getter for related data
 String toXML()
          Serialization from the type to it's XML representation
 void updateRelatedData(String fileName)
          Update method for related data ( used to update relative file location for transmitted samples )
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface de.unikassel.android.sdcframework.data.independent.SampleData
doClone
 

Constructor Detail

AbstractSampleData

public AbstractSampleData()
Constructor

Method Detail

clone

protected Object clone()
                throws CloneNotSupportedException
Overrides:
clone in class Object
Throws:
CloneNotSupportedException

toXML

public final String toXML()
                   throws Exception
Description copied from interface: SerializableData
Serialization from the type to it's XML representation

Specified by:
toXML in interface SerializableData
Returns:
the XML representation of the type if successful, null otherwise
Throws:
Exception - if the schema for the object is not valid

getRelatedData

public String getRelatedData()
Description copied from interface: SampleData
Getter for related data

Specified by:
getRelatedData in interface SampleData
Returns:
the path to a related data file if existing, null otherwise

updateRelatedData

public void updateRelatedData(String fileName)
Description copied from interface: SampleData
Update method for related data ( used to update relative file location for transmitted samples )

Specified by:
updateRelatedData in interface SampleData
Parameters:
fileName - the new filename