public class Extract extends MeasuredBioMaterial
Sample
or by combining other extracts
(pooling). It is also possible to create
standalone extracts, with no reference to a sample or to other
extracts.MeasuredBioMaterial.RemainingQuantityAction
Modifier and Type | Field and Description |
---|---|
static String |
LABELED
The id for the
ExtractType item representing a
labeled extract. |
static String |
LIBRARY
The id for the
ExtractType item representing a library. |
static Item |
TYPE
The type of item represented by this class.
|
MAX_EXTERNAL_ID_LENGTH
MAX_DESCRIPTION_LENGTH, MAX_NAME_LENGTH
Constructor and Description |
---|
Extract(ExtractData extractData) |
Modifier and Type | Method and Description |
---|---|
long |
countChildren(boolean extractsOnly)
Count the number of child extracts.
|
long |
countExtracts()
Counts all extracts that have been created from this extract.
|
Set<Annotatable> |
getAnnotatableParents()
Get the tag and parent extracts.
|
static Extract |
getById(DbControl dc,
int id)
Get an
Extract item when you know the id. |
ItemQuery<Extract> |
getChildExtracts()
Creates a query that returns all child (pooled) extracts that
has this extracts as one of it's sources.
|
(package private) ExtractData |
getData()
Get the
BasicData object that holds all data for this item. |
ItemSubtype |
getItemSubtype()
Get the subtype of the item.
|
static Extract |
getNew(DbControl dc)
Create a new
Extract item. |
static Extract |
getNew(DbControl dc,
BioPlateEventParticipant master)
Create a new
Extract item as part
of a master bioplate event. |
ItemQuery<PhysicalBioAssay> |
getPhysicalBioAssays()
Get a query that returns all bioassays created from this
extract.
|
static ItemQuery<Extract> |
getQuery()
Get a query that returns extracts.
|
Tag |
getTag()
Get the tag that has been applied to this extract in order
to be able to distinguish it from other extracts on a
physical bioassay.
|
Item |
getType()
Get the type of item represented by the object.
|
Set<ItemProxy> |
getUsingItems()
Get all:
Child extracts created from the extract
PhysicalBioAssay :s created from this extract
DerivedBioAssay :s referencing the extract
RawBioAssay :s referencing the extract
|
boolean |
isUsed()
Check that:
no
PhysicalBioAssay :s has been created from this item
no Extract :s has been created from this item
no DerivedBioAssay is referencing this item
no RawBioAssay is referencing this item
|
void |
setTag(Tag tag)
Set the tag that was applied to this extract in order
to be able to distinguish it from other extracts on a
physical bioassay.
|
breakCircularReferences, getAnnotatableParents, getBioWell, getCreationEvent, getEntryDate, getEvents, getOriginalQuantity, getParent, getParentType, getProtocol, getRemainingQuantity, hasSingleParent, isInWell, isLockedInWell, newEvent, newEvent, onBeforeCommit, setBioPlateEventParticipant, setBioWell, setOriginalQuantity, updateRemainingQuantity
getChildCreationEvents, getExternalId, setExternalId, setItemSubtype
getAnnotationSet, isAnnotated, removeAnnotations
getDescription, getName, getRemovedBy, isRemoved, setDescription, setName, setRemoved
getItemKey, getProjectKey, initPermissions, isShared, setItemKey, setProjectKey
getOwner, isOwner, setOwner, takeOwnership
addAnnotatableParents, addUsingItems, addUsingItems, checkBatchAnnotatableUsage, checkPermission, equals, getBasicData, getDbControl, getId, getPermissions, getPluginPermissions, getSessionControl, getVersion, hashCode, hasPermission, isDetached, isInDatabase, onAfterCommit, onAfterInsert, onRollback, setDbControl, setProjectDefaults, toString, validate
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
getId, getVersion
checkPermission, getPermissions, hasPermission
getDescription, getName, setDescription, setName
getOwner, isOwner, setOwner, takeOwnership
public static final Item TYPE
Item.EXTRACT
,
getType()
public static final String LABELED
ExtractType
item representing a
labeled extract.public static final String LIBRARY
ExtractType
item representing a library.Extract(ExtractData extractData)
public static Extract getNew(DbControl dc) throws BaseException
Extract
item.dc
- The DbControl
which will be used for
permission checking and database accessExtract
itemBaseException
- If there is an errorpublic static Extract getNew(DbControl dc, BioPlateEventParticipant master) throws BaseException
Extract
item as part
of a master bioplate event.dc
- The DbControl
which will be used for
permission checking and database accessmaster
- The master bioplate event participant or nullExtract
itemBaseException
- If there is an errorpublic static Extract getById(DbControl dc, int id) throws ItemNotFoundException, PermissionDeniedException, BaseException
Extract
item when you know the id.dc
- The DbControl
which will be used for
permission checking and database access.id
- The id of the item to loadExtract
itemItemNotFoundException
- If an item with the specified
id is not foundPermissionDeniedException
- If the logged in user doesn't
have read permission to the itemBaseException
- If there is another errorpublic static ItemQuery<Extract> getQuery()
ItemQuery
object.ExtractData getData()
BasicItem
BasicData
object that holds all data for this item.getData
in class MeasuredBioMaterial
public Item getType()
Identifiable
Item
enumeration.@SupportsPushAnnotations @SubtypableRelatedItems(value={PROTOCOL,KIT,HARDWARE,TAG,SAMPLE,EXTRACT}) public ItemSubtype getItemSubtype()
Subtypable
getItemSubtype
in interface Subtypable
getItemSubtype
in class MeasuredBioMaterial
SubtypableRelatedItems
public boolean isUsed() throws BaseException
PhysicalBioAssay
:s has been created from this item
Extract
:s has been created from this item
DerivedBioAssay
is referencing this item
RawBioAssay
is referencing this item
isUsed
in class MeasuredBioMaterial
BaseException
- If not able to tell if item is used or not.BasicItem.getUsingItems()
public Set<ItemProxy> getUsingItems()
PhysicalBioAssay
:s created from this extract
DerivedBioAssay
:s referencing the extract
RawBioAssay
:s referencing the extract
getUsingItems
in class MeasuredBioMaterial
BasicItem.addUsingItems(Set, Item, org.hibernate.Query)
public Tag getTag()
public void setTag(Tag tag)
tag
- The tag, or null if the extract is not taggedpublic ItemQuery<Extract> getChildExtracts()
public long countExtracts() throws BaseException
BaseException
- If there is some kind of error.public long countChildren(boolean extractsOnly)
countChildren
in class BioMaterial
extractsOnly
- If TRUE, the count is for biomaterials of the same type,
if FALSE the count is for biomaterials of the child typepublic ItemQuery<PhysicalBioAssay> getPhysicalBioAssays()
ItemQuery
objectpublic Set<Annotatable> getAnnotatableParents() throws BaseException
getAnnotatableParents
in interface Annotatable
getAnnotatableParents
in class MeasuredBioMaterial
BaseException
- If there is an error