gr.uoa.di.madgik.grs.record
Class GenericRecordDefinition

java.lang.Object
  extended by gr.uoa.di.madgik.grs.record.RecordDefinition
      extended by gr.uoa.di.madgik.grs.record.GenericRecordDefinition

public class GenericRecordDefinition
extends RecordDefinition

This RecordDefinition extending class acts as a generic placeholder for record definitions. It does not add much in the general definition provided by the RecordDefinition super class, other than supplying a readily available, non abstract implementation

Author:
gpapanikos

Constructor Summary
GenericRecordDefinition()
          Create a new instance
GenericRecordDefinition(FieldDefinition[] fieldDefinitions)
          Create a new instance
 
Method Summary
 void copyFrom(GenericRecordDefinition other)
           
 void extendDeflate(java.io.DataOutput out)
          Method that needs to be implemented by the RecordDefinition extenders to deflate any additional information kept
 boolean extendEquals(java.lang.Object obj)
          Method that needs to be implemented by the RecordDefinition extenders to extend the equality logic based on additional logic contained in the implementations
 void extendFromXML(org.w3c.dom.Element element)
           
 void extendInflate(java.io.DataInput in)
          Method that needs to be implemented by the RecordDefinition extenders to inflate any additional information previously deflated by the respective extender method
 void extendToXML(org.w3c.dom.Document out, org.w3c.dom.Element element)
           
 
Methods inherited from class gr.uoa.di.madgik.grs.record.RecordDefinition
copyFrom, deflate, equals, fromXML, getDefinition, getDefinition, getDefinitionSize, getTransportDirective, inflate, setTransportDirective, toXML
 
Methods inherited from class java.lang.Object
getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GenericRecordDefinition

public GenericRecordDefinition()
Create a new instance

See Also:
RecordDefinition.RecordDefinition()

GenericRecordDefinition

public GenericRecordDefinition(FieldDefinition[] fieldDefinitions)
Create a new instance

Parameters:
fieldDefinitions - the field definitions to set for the record definition
See Also:
RecordDefinition.RecordDefinition(FieldDefinition[])
Method Detail

copyFrom

public void copyFrom(GenericRecordDefinition other)
              throws GRS2RecordSerializationException
Throws:
GRS2RecordSerializationException

extendEquals

public boolean extendEquals(java.lang.Object obj)
Method that needs to be implemented by the RecordDefinition extenders to extend the equality logic based on additional logic contained in the implementations

This method simply checks for type equality and does not base its decision an any other elements

Specified by:
extendEquals in class RecordDefinition
Parameters:
obj - the object to check equality for
Returns:
true if the two instances are equal, false otherwise
See Also:
RecordDefinition.extendEquals(java.lang.Object)

extendDeflate

public void extendDeflate(java.io.DataOutput out)
                   throws GRS2RecordSerializationException
Method that needs to be implemented by the RecordDefinition extenders to deflate any additional information kept

nothing to add to deflate

Specified by:
extendDeflate in class RecordDefinition
Parameters:
out - the stream to deflate to
Throws:
GRS2RecordSerializationException - there was a serialization error
See Also:
RecordDefinition.extendDeflate(java.io.DataOutput)

extendInflate

public void extendInflate(java.io.DataInput in)
                   throws GRS2RecordSerializationException
Method that needs to be implemented by the RecordDefinition extenders to inflate any additional information previously deflated by the respective extender method

nothing to get from inflate

Specified by:
extendInflate in class RecordDefinition
Parameters:
in - the stream to inflate from
Throws:
GRS2RecordSerializationException - there was a problem deserializing the definition state
See Also:
RecordDefinition.extendInflate(java.io.DataInput)

extendFromXML

public void extendFromXML(org.w3c.dom.Element element)
                   throws GRS2RecordSerializationException
Specified by:
extendFromXML in class RecordDefinition
Throws:
GRS2RecordSerializationException

extendToXML

public void extendToXML(org.w3c.dom.Document out,
                        org.w3c.dom.Element element)
                 throws GRS2RecordSerializationException
Specified by:
extendToXML in class RecordDefinition
Throws:
GRS2RecordSerializationException