2.8.3: 2008-10-15

net.sf.basedb.core.data
Class BioMaterialEventData

java.lang.Object
  extended by net.sf.basedb.core.data.BasicData
      extended by net.sf.basedb.core.data.BioMaterialEventData
All Implemented Interfaces:
IdentifiableData

public class BioMaterialEventData
extends BasicData

This class is used to register events for measured biomaterials.

Version:
2.0
Author:
Nicklas
See Also:
BioMaterialEvent, Biomaterials overview
Last modified
$Date: 2008-09-05 17:16:27 +0200 (Fri, 05 Sep 2008) $
Hibernate: class
table="`BioMaterialEvents`" lazy="false"

Field Summary
private  MeasuredBioMaterialData bioMaterial
           
private  String comment
           
private  Date entryDate
           
private  Date eventDate
           
private  int eventType
           
private  HardwareData hardware
           
private  HybridizationData hybridization
           
static int MAX_COMMENT_LENGTH
          The maximum length of the comment about this event.
private  ProtocolData protocol
           
private  Map<MeasuredBioMaterialData,UsedQuantity> sources
           
private  Float usedQuantity
           
private  UserData user
           
 
Constructor Summary
BioMaterialEventData()
           
 
Method Summary
 MeasuredBioMaterialData getBioMaterial()
          Get the biomaterial produced or affected by this event.
 String getComment()
          Get the comment about this event.
 Date getEntryDate()
          Get the date this event was added to the database.
 Date getEventDate()
          Get the date this event happened in the lab.
 int getEventType()
          Get the type of event, 1=creation event, 2=hybridization event, 3=other event
 HardwareData getHardware()
          Get the hardware used in this event
 HybridizationData getHybridization()
          Get the hybridization that was created by this event.
 ProtocolData getProtocol()
          Get the protocol used in this event.
 Map<MeasuredBioMaterialData,UsedQuantity> getSources()
          Get a map containing the source biomaterials and the used quantity for this event.
 Float getUsedQuantity()
          Get the used quantity of the biomaterial affected by this event.
 UserData getUser()
          Get the user that is responsible for this event, typically this is the user that entered the information in the database.
 void setBioMaterial(MeasuredBioMaterialData bioMaterial)
           
 void setComment(String comment)
           
 void setEntryDate(Date entryDate)
           
 void setEventDate(Date eventDate)
           
 void setEventType(int eventType)
           
 void setHardware(HardwareData hardware)
           
 void setHybridization(HybridizationData hybridization)
           
 void setProtocol(ProtocolData protocol)
           
(package private)  void setSources(Map<MeasuredBioMaterialData,UsedQuantity> sources)
           
 void setUsedQuantity(Float usedQuantity)
           
 void setUser(UserData user)
           
 
Methods inherited from class net.sf.basedb.core.data.BasicData
equals, getId, getVersion, hashCode, setId, setVersion, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

eventType

private int eventType

bioMaterial

private MeasuredBioMaterialData bioMaterial

usedQuantity

private Float usedQuantity

hybridization

private HybridizationData hybridization

user

private UserData user

protocol

private ProtocolData protocol

hardware

private HardwareData hardware

entryDate

private Date entryDate

eventDate

private Date eventDate

MAX_COMMENT_LENGTH

public static final int MAX_COMMENT_LENGTH
The maximum length of the comment about this event.

See Also:
Constant Field Values

comment

private String comment

sources

private Map<MeasuredBioMaterialData,UsedQuantity> sources
Constructor Detail

BioMaterialEventData

public BioMaterialEventData()
Method Detail

getEventType

public int getEventType()
Get the type of event, 1=creation event, 2=hybridization event, 3=other event

Hibernate: property
column="`event_type`" type="int" not-null="true" update="false"

setEventType

public void setEventType(int eventType)

getBioMaterial

public MeasuredBioMaterialData getBioMaterial()
Get the biomaterial produced or affected by this event.

Hibernate: many-to-one
column="`biomaterial_id`" not-null="false" outer-join="false" update="false"

setBioMaterial

public void setBioMaterial(MeasuredBioMaterialData bioMaterial)

getUsedQuantity

public Float getUsedQuantity()
Get the used quantity of the biomaterial affected by this event. This can be both positive and negative.

Hibernate: property
column="`used_quantity`" type="float" not-null="false"

setUsedQuantity

public void setUsedQuantity(Float usedQuantity)

getHybridization

public HybridizationData getHybridization()
Get the hybridization that was created by this event.

Hibernate: many-to-one
column="`hybridization_id`" not-null="false" outer-join="false" update="false"

setHybridization

public void setHybridization(HybridizationData hybridization)

getUser

public UserData getUser()
Get the user that is responsible for this event, typically this is the user that entered the information in the database.

Hibernate: many-to-one
column="`user_id`" not-null="false" outer-join="false" update="false"

setUser

public void setUser(UserData user)

getProtocol

public ProtocolData getProtocol()
Get the protocol used in this event.

Hibernate: many-to-one
column="`protocol_id`" not-null="false" outer-join="false"

setProtocol

public void setProtocol(ProtocolData protocol)

getHardware

public HardwareData getHardware()
Get the hardware used in this event

Hibernate: many-to-one
column="`hardware_id`" not-null="false" outer-join="false"

setHardware

public void setHardware(HardwareData hardware)

getEntryDate

public Date getEntryDate()
Get the date this event was added to the database.

Hibernate: property
column="`entry_date`" type="date" not-null="true" update="false"

setEntryDate

public void setEntryDate(Date entryDate)

getEventDate

public Date getEventDate()
Get the date this event happened in the lab.

Hibernate: property
column="`event_date`" type="date" not-null="false"

setEventDate

public void setEventDate(Date eventDate)

getComment

public String getComment()
Get the comment about this event.

Hibernate: property
column="`comment`" type="text" not-null="false"

setComment

public void setComment(String comment)

getSources

public Map<MeasuredBioMaterialData,UsedQuantity> getSources()
Get a map containing the source biomaterials and the used quantity for this event.

Hibernate: map
table="`BioMaterialEventSources`" lazy="true" cascade="delete"
Hibernate: index-many-to-many
column="`biomaterial_id`" class="net.sf.basedb.core.data.MeasuredBioMaterialData"
Hibernate: collection-key
column="`event_id`"
Hibernate: collection-composite-element
class="net.sf.basedb.core.data.UsedQuantity"

setSources

void setSources(Map<MeasuredBioMaterialData,UsedQuantity> sources)

2.8.3: 2008-10-15