public class ArrayBatch extends AnnotatedItem implements Registered
Modifier and Type | Field and Description |
---|---|
private boolean |
protocolHasBeenSet |
private boolean |
robotHasBeenSet |
static Item |
TYPE
The type of item represented by this class.
|
MAX_DESCRIPTION_LENGTH, MAX_NAME_LENGTH
Constructor and Description |
---|
ArrayBatch(ArrayBatchData annotatedData) |
Modifier and Type | Method and Description |
---|---|
Set<Annotatable> |
getAnnotatableParents()
Get the array design.
|
ArrayDesign |
getArrayDesign()
Get the
ArrayDesign item that was used for this batch. |
ItemQuery<ArraySlide> |
getArraySlides()
Get a query that returns the slides in this batch.
|
static ArrayBatch |
getById(DbControl dc,
int id)
Get a
ArrayBatch object when you know the ID. |
(package private) ArrayBatchData |
getData()
Get the
BasicData object that holds all data for this item. |
Date |
getEntryDate()
Get the date that the item was registered in the database.
|
static ArrayBatch |
getNew(DbControl dc,
ArrayDesign arrayDesign)
Create a new
ArrayBatch item. |
Hardware |
getPrintRobot()
Get the
print robot used for printing the arrays. |
Protocol |
getProtocol()
Get the
Protocol used for printing the arrays. |
static ItemQuery<ArrayBatch> |
getQuery()
Get a
ItemQuery that returns array batches. |
Item |
getType()
Get the type of item represented by the object.
|
Set<ItemProxy> |
getUsingItems()
Get all:
ArraySlide :s in this batch
|
boolean |
isUsed()
Check if this item is used by some other item.
|
ArraySlide |
newArraySlide()
Create a new
ArraySlide item for this batch. |
private void |
setArrayDesign(ArrayDesign arrayDesign)
Set the
ArrayDesign used in this ArrayBatch. |
void |
setPrintRobot(Hardware printRobot)
Set the
print robot used for this array batch. |
(package private) void |
setProjectDefaults(Project activeProject)
Set print robot and protocol from project default settings.
|
void |
setProtocol(Protocol protocol)
Set the
Protocol used for printing the arrays. |
getAnnotationSet, isAnnotated, removeAnnotations
getDescription, getName, getRemovedBy, isRemoved, setDescription, setName, setRemoved
getItemKey, getProjectKey, initPermissions, isShared, onBeforeCommit, setItemKey, setProjectKey
getOwner, isOwner, setOwner, takeOwnership
addAnnotatableParents, addUsingItems, addUsingItems, breakCircularReferences, checkBatchAnnotatableUsage, checkPermission, equals, getBasicData, getDbControl, getId, getPermissions, getPluginPermissions, getSessionControl, getVersion, hashCode, hasPermission, isDetached, isInDatabase, onAfterCommit, onAfterInsert, onRollback, setDbControl, toString, validate
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
getId, getVersion
checkPermission, getPermissions, hasPermission
getOwner, isOwner, setOwner, takeOwnership
public static final Item TYPE
Item.ARRAYBATCH
,
getType()
private boolean protocolHasBeenSet
private boolean robotHasBeenSet
ArrayBatch(ArrayBatchData annotatedData)
public static ArrayBatch getNew(DbControl dc, ArrayDesign arrayDesign) throws BaseException
ArrayBatch
item.dc
- The DbControl
which will be used for
permission checking and database accessarrayDesign
- The ArrayDesign
used for the batchArrayBatch
itemPermissionDeniedException
- If the logged in user doesn't
have create permission for this type
of item, or use permission for the designBaseException
- If there is another errorpublic static ArrayBatch getById(DbControl dc, int id) throws ItemNotFoundException, PermissionDeniedException, BaseException
ArrayBatch
object 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 loadArrayBatch
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<ArrayBatch> getQuery()
ItemQuery
that returns array batches.ItemQuery
objectArrayBatchData getData()
BasicItem
BasicData
object that holds all data for this item.getData
in class AnnotatedItem
public Item getType()
Identifiable
Item
enumeration.getType
in interface Identifiable
public Set<Annotatable> getAnnotatableParents() throws BaseException
getAnnotatableParents
in interface Annotatable
BaseException
- If there is an errorpublic Date getEntryDate()
Registered
getEntryDate
in interface Registered
public boolean isUsed() throws BaseException
BasicItem
super.isUsed()
, unless it has decided
that the item is used by some other means.isUsed
in class BasicItem
BaseException
- If not able to tell if item is used or not.BasicItem.getUsingItems()
public Set<ItemProxy> getUsingItems()
ArraySlide
:s in this batch
getUsingItems
in class BasicItem
BasicItem.addUsingItems(Set, Item, org.hibernate.Query)
void setProjectDefaults(Project activeProject) throws BaseException
setProjectDefaults
in class BasicItem
activeProject
- The currently active projectBaseException
public ArrayDesign getArrayDesign() throws PermissionDeniedException, BaseException
ArrayDesign
item that was used for this batch.ArrayDesign
itemPermissionDeniedException
- If
the logged in user doesn't have read
permission to the itemBaseException
- If there is an errorprivate void setArrayDesign(ArrayDesign arrayDesign) throws InvalidDataException, PermissionDeniedException
ArrayDesign
used in this ArrayBatch.arrayDesign
- the arrayDesign to be set. Cannot be null.InvalidDataException
- if arrayDesign is null.PermissionDeniedException
- If the
logged in user doesn't have use
permission for the array design.public Protocol getProtocol() throws PermissionDeniedException, BaseException
Protocol
used for printing the arrays.getProtocol
in interface Annotatable
getProtocol
in class AnnotatedItem
Protocol
itemPermissionDeniedException
- If
the logged in user doesn't have read
permission to the itemBaseException
- If there is an errorpublic void setProtocol(Protocol protocol) throws PermissionDeniedException
Protocol
used for printing the arrays.protocol
- A Protocol
item of the Protocol.PRINTING
protocol typePermissionDeniedException
- If the
logged in user doesn't have write
permission on this array batch or use
permission for the protocolpublic Hardware getPrintRobot() throws PermissionDeniedException, BaseException
print robot
used for printing the arrays.Hardware
item of type
Hardware.PRINT_ROBOT
PermissionDeniedException
- If
the logged in user doesn't have read
permission to the itemBaseException
- If there is an errorpublic void setPrintRobot(Hardware printRobot) throws PermissionDeniedException
print robot
used for this array batch.printRobot
- A Hardware
item of type
Hardware.PRINT_ROBOT
PermissionDeniedException
- If the
logged in user doesn't have write
permission on this array batch or use
permission for the hardwarepublic ArraySlide newArraySlide() throws PermissionDeniedException, BaseException
ArraySlide
item for this batch.ArraySlide
itemPermissionDeniedException
- If
the logged in user doesn't have use
permission for this batchBaseException
- If there is another
errorpublic ItemQuery<ArraySlide> getArraySlides()
ItemQuery
object