net.sf.basedb.core.data
Class UnitSymbolData
java.lang.Object
net.sf.basedb.core.data.BasicData
net.sf.basedb.core.data.UnitSymbolData
- All Implemented Interfaces:
- IdentifiableData
public class UnitSymbolData
- extends BasicData
This class holds information the symbol that are used with units.
A symbol must be unique within a given QuantityData
. To make
it easier for user to input we will also register alternative symbols
for units. For example:
Temperature: °C -- C
Surface area: m² -- m2
- Version:
- 2.9
- Author:
- Nicklas
- Last modified
- $Date $
- Hibernate: class
- table="`UnitSymbols`" lazy="false"
quantity
private QuantityData quantity
symbol
private String symbol
unit
private UnitData unit
UnitSymbolData
public UnitSymbolData()
getQuantity
public QuantityData getQuantity()
- Get the quantity this symbol belongs to.
- Hibernate: column
- name="`quantity_id`" not-null="true" unique-key="uniquesymbol"
- Hibernate: many-to-one
- outer-join="false" update="false"
setQuantity
public void setQuantity(QuantityData quantity)
getSymbol
public String getSymbol()
- The symbol, which must be unique for a given quantity.
- Hibernate: property
- type="string"
- Hibernate: column
- name="`symbol`" length="255" not-null="true" unique-key="uniquesymbol"
setSymbol
public void setSymbol(String symbol)
getUnit
public UnitData getUnit()
- Get the unit this symbol belongs to.
- Hibernate: many-to-one
- column="`unit_id`" update="false" not-null="true" outer-join="false"
setUnit
public void setUnit(UnitData unit)