org.gcube.common.searchservice.searchlibrary.resultset.elements
Class PropertyElementLifeSpanGC

java.lang.Object
  extended by org.gcube.common.searchservice.searchlibrary.resultset.elements.PropertyElementBase
      extended by org.gcube.common.searchservice.searchlibrary.resultset.elements.PropertyElementLifeSpanGC

public class PropertyElementLifeSpanGC
extends PropertyElementBase

Property Element that is used to set a specific lifespan to the ResultSet

Author:
uoA
See Also:
PropertyElementBase

Field Summary
static java.lang.String propertyType
          The Type of the Property this Property element produces
 
Constructor Summary
PropertyElementLifeSpanGC()
          Default contructor required by PropertyElementBase
PropertyElementLifeSpanGC(long lifeSpan)
          Initializes a new PropertyElementLifeSpanGC
 
Method Summary
 void fromXML(java.lang.String xml)
          Method to be implemented that will handle the population of the custom Property element.
 java.lang.String toXML()
          Method to be implemented that will handle the serialization of the custom Property element.
 
Methods inherited from class org.gcube.common.searchservice.searchlibrary.resultset.elements.PropertyElementBase
getType, getType, RS_fromXML, RS_toXML, setType
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

propertyType

public static java.lang.String propertyType
The Type of the Property this Property element produces

Constructor Detail

PropertyElementLifeSpanGC

public PropertyElementLifeSpanGC()
Default contructor required by PropertyElementBase


PropertyElementLifeSpanGC

public PropertyElementLifeSpanGC(long lifeSpan)
                          throws java.lang.Exception
Initializes a new PropertyElementLifeSpanGC

Parameters:
lifeSpan - The lifespan of this ResultSet in milliseconds
Throws:
java.lang.Exception - An unrecoverable for the operation error occured
Method Detail

toXML

public java.lang.String toXML()
                       throws java.lang.Exception
Description copied from class: PropertyElementBase
Method to be implemented that will handle the serialization of the custom Property element. It is called by the PropertyElementBase.RS_toXML() which then enriches the returned serialization to produce a valid property xml string

Specified by:
toXML in class PropertyElementBase
Returns:
The serialized property payload
Throws:
java.lang.Exception - An unrecoverable for the operation error occured
See Also:
PropertyElementBase.toXML()

fromXML

public void fromXML(java.lang.String xml)
             throws java.lang.Exception
Description copied from class: PropertyElementBase
Method to be implemented that will handle the population of the custom Property element. It is called by the PropertyElementBase.RS_fromXML(String) after it has striped the xml serialization of the type property

Specified by:
fromXML in class PropertyElementBase
Parameters:
xml - The serialized string to populate the insance from
Throws:
java.lang.Exception - An unrecoverable for the operation error occured
See Also:
PropertyElementBase.fromXML(java.lang.String)