hepdata is hosted by Hepforge, IPPP Durham

cedar.hepdata.model
Class Property

java.lang.Object
  extended by cedar.hepdata.model.Property
All Implemented Interfaces:
HDPersistable

public class Property
extends java.lang.Object
implements HDPersistable

A Property is an attribute of a dataset or axis. It has a name and a Value. The value may be numeric - in which case the property.value.value will be populated (possibly also property.value.Errors). For non-numeric values, just the property.value.description will be populated. Strings loaded into the property.header can be used to link a particular property or axis to an observable. If a property.name of "RE" is loaded, a reaction will be created. Reaction and Observable are special types of property, at present unrelated. Maybe they should be subclasses?

Version:
$Date: 2006-02-02 16:35:56 +0000 (Thu, 02 Feb 2006) $ $Revision: 500 $
Author:
S Butterworth

Constructor Summary
Property(int paperId, int datasetId, int axisId, java.lang.String header, java.lang.String name, java.lang.String sValue, boolean isNumeric)
          Property constructor containinq all required information from a dataset or axis.
 
Method Summary
 int getAxisId()
           
 int getDatasetId()
           
 java.lang.String getHeader()
           
 int getId()
          Return the property ID
 java.lang.String getName()
           
 int getPaperId()
           
 java.lang.String getUnit()
          get property unit
 Value getValue()
           
 void setAxisId(int id)
           
 void setDatasetId(int id)
           
 void setHeader(java.lang.String hdr)
           
 void setId(int id)
          set property id
 void setName(java.lang.String name)
           
 void setPaperId(int id)
           
 void setUnit(java.lang.String un)
          set property unit
 void setValue(Value v)
           
 java.lang.String toString()
          Produce a string representation of the object
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Property

public Property(int paperId,
                int datasetId,
                int axisId,
                java.lang.String header,
                java.lang.String name,
                java.lang.String sValue,
                boolean isNumeric)
Property constructor containinq all required information from a dataset or axis.

Parameters:
paperId -
datasetId -
axisId -
header - from dataset or axis (reference to observable)
name - refers to property or reaction (if =="RE")
sValue - string value of property
isNumeric - if true, property is numeric

Method Detail

getId

public int getId()
Return the property ID

Specified by:
getId in interface HDPersistable
Returns:
propertyId


setId

public void setId(int id)
set property id

Specified by:
setId in interface HDPersistable
Parameters:
id - internal ID used to define (part of) the


getPaperId

public int getPaperId()

setPaperId

public void setPaperId(int id)

getDatasetId

public int getDatasetId()

setDatasetId

public void setDatasetId(int id)

getAxisId

public int getAxisId()

setAxisId

public void setAxisId(int id)

getHeader

public java.lang.String getHeader()

setHeader

public void setHeader(java.lang.String hdr)

setUnit

public void setUnit(java.lang.String un)
set property unit


getUnit

public java.lang.String getUnit()
get property unit


getName

public java.lang.String getName()

setName

public void setName(java.lang.String name)

getValue

public Value getValue()

setValue

public void setValue(Value v)

toString

public java.lang.String toString()
Description copied from interface: HDPersistable
Produce a string representation of the object

Specified by:
toString in interface HDPersistable
Overrides:
toString in class java.lang.Object


Generated 20060512 1623

HEPData