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

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

public class PropertyElementEstimationCount
extends PropertyElementBase

Property Element that is used to set an estimation of the records in the ResultSet

Author:
uoA
See Also:
PropertyElementBase

Field Summary
static java.lang.String propertyType
          The Type of the Property this Property element produces
static int unspecified
          Specifying that there is no SSID provided
 
Constructor Summary
PropertyElementEstimationCount()
          Default contructor required by PropertyElementBase
PropertyElementEstimationCount(int min, int max, int estimation)
          Initializes a new PropertyElementEstimationCount
 
Method Summary
 void fromXML(java.lang.String xml)
          Method to be implemented that will handle the population of the custom Property element.
 int getEstimation()
          Retrieves the estimation
 int getMax()
          Retrieves the max estimation
 int getMin()
          Retrieves the min estimation
 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


unspecified

public static int unspecified
Specifying that there is no SSID provided

Constructor Detail

PropertyElementEstimationCount

public PropertyElementEstimationCount()
Default contructor required by PropertyElementBase


PropertyElementEstimationCount

public PropertyElementEstimationCount(int min,
                                      int max,
                                      int estimation)
                               throws java.lang.Exception
Initializes a new PropertyElementEstimationCount

Parameters:
min - The min estimation
max - The max estimation
estimation - The estimation
Throws:
java.lang.Exception - An unrecoverable for the operation error occured
Method Detail

getMin

public int getMin()
Retrieves the min estimation

Returns:
the min estimation

getMax

public int getMax()
Retrieves the max estimation

Returns:
the max estimation

getEstimation

public int getEstimation()
Retrieves the estimation

Returns:
the estimation

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)