|
3.1.1: 2012-03-29 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectnet.sf.basedb.core.BasicItem<ExtraValueTypeData>
net.sf.basedb.core.ExtraValueType
public class ExtraValueType
Defines extra values that can be calculated by plugins or some other
application and inserted as part of a BioAssaySet. All
extra value types must have a unique external id that is used for
identification.
Currently only extra values of Type.INT, Type.FLOAT
and Type.STRING are supported.
ExtraValue,
BioAssaySet.getSpotExtraValueBatcher(Class, ExtraValueType, Job),
BioAssaySet.getPositionExtraValueBatcher(Class, ExtraValueType, Job)| Field Summary | |
|---|---|
private Coloring |
coloring
|
static int |
MAX_EXTERNAL_ID_LENGTH
The maximum length of the external id variable that can be stored in the database. |
static Item |
TYPE
The type of item represented by this class. |
| Fields inherited from interface net.sf.basedb.core.Nameable |
|---|
MAX_DESCRIPTION_LENGTH, MAX_NAME_LENGTH |
| Constructor Summary | |
|---|---|
ExtraValueType(ExtraValueTypeData data)
Creates a new extra value type item. |
|
| Method Summary | |
|---|---|
Formula.AverageMethod |
getAverageMethod()
Get the average method for this extra value type. |
static ExtraValueType |
getByExternalId(DbControl dc,
String externalId)
Get a ExtraValueType when you know the external id. |
static ExtraValueType |
getById(DbControl dc,
int id)
Get an ExtraValueType object when you know the id. |
Coloring |
getColoring()
Get coloring information for this extra value. |
String |
getDescription()
Get the description for the item. |
Date |
getEntryDate()
Get the date that the item was registered in the database. |
String |
getExternalId()
Get the external id for this ExtraValueType item. |
String |
getName()
Get the name of the item. |
static ExtraValueType |
getNew(DbControl dc,
String externalId,
Type valueType)
Create a new ExtraValue item. |
static ItemQuery<ExtraValueType> |
getQuery()
Get a query configured to retrieve extra value types. |
Item |
getType()
Get the type of item represented by the object. |
Set<ItemProxy> |
getUsingItems()
Get all: ExtraValue:s of this type
|
Type |
getValueType()
Get the value type for this extra value type. |
boolean |
isRemoved()
Check if the removed flag is set for this item. |
boolean |
isUsed()
Check if: Any ExtraValue:s of this type exists
|
void |
setAverageMethod(Formula.AverageMethod averageMethod)
Set the average method of the extra value type.. |
void |
setDescription(String description)
Set the description for the item. |
void |
setExternalId(String externalId)
Set the external id for this Client item. |
void |
setName(String name)
Set the name of the item. |
void |
setRemoved(boolean removed)
Set the removed flag for this item. |
private void |
setValueType(Type valueType)
Set the value type for this extra value type. |
| Methods inherited from class net.sf.basedb.core.BasicItem |
|---|
addUsingItems, addUsingItems, checkPermission, equals, getData, getDbControl, getId, getPermissions, getPluginPermissions, getSessionControl, getVersion, hashCode, hasPermission, initPermissions, isDetached, isInDatabase, onAfterCommit, onAfterInsert, onBeforeCommit, onRollback, setDbControl, setProjectDefaults, toString, toTransferable, validate |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface net.sf.basedb.core.Identifiable |
|---|
getId, getVersion |
| Methods inherited from interface net.sf.basedb.core.AccessControlled |
|---|
checkPermission, getPermissions, hasPermission |
| Field Detail |
|---|
public static final Item TYPE
Item.EXTRAVALUETYPE,
getType()public static final int MAX_EXTERNAL_ID_LENGTH
setExternalId(String) method to avoid
exceptions.
private Coloring coloring
| Constructor Detail |
|---|
ExtraValueType(ExtraValueTypeData data)
data - The data| Method Detail |
|---|
public static ExtraValueType getNew(DbControl dc,
String externalId,
Type valueType)
throws BaseException
ExtraValue item. Currently only extra values
of Type.INT, Type.FLOAT and Type.STRING are supported.
dc - The DbControl which will be used for
permission checking and database accessexternalId - A unique string identifying the extra value typevalueType - The Type of the extra value
ExtraValue item
BaseException - If there is an error
public static ExtraValueType getById(DbControl dc,
int id)
throws ItemNotFoundException,
PermissionDeniedException,
BaseException
ExtraValueType 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 load
ExtraValueType item
ItemNotFoundException - If an item with the specified id is not found
PermissionDeniedException - If the logged in user doesn't have
Permission.READ permission to the items
BaseException - If there is an error
public static ExtraValueType getByExternalId(DbControl dc,
String externalId)
throws ItemNotFoundException,
PermissionDeniedException,
BaseException
ExtraValueType when you know the external id.
dc - The DbControl which will be used for
database access.externalId - The external id of the extra value type to load
ExtraValueType item
ItemNotFoundException - If an item with the specified
id is not found
PermissionDeniedException - If the logged in user doesn't
have read permission to the item
BaseException - If there is another errorpublic static ItemQuery<ExtraValueType> getQuery()
ItemQuery objectpublic Item getType()
IdentifiableItem enumeration.
getType in interface Identifiablepublic String getName()
Nameable
getName in interface NameableString with the name of the item
public void setName(String name)
throws PermissionDeniedException,
InvalidDataException
NameableNameable.MAX_NAME_LENGTH constant.
setName in interface Nameablename - The new name for the item
PermissionDeniedException - If the logged in user doesn't
have write permission
InvalidDataException - If the name is null or longer
than specified by the Nameable.MAX_NAME_LENGTH constantpublic String getDescription()
Nameable
getDescription in interface NameableString with a description of the item
public void setDescription(String description)
throws PermissionDeniedException,
InvalidDataException
NameableNameable.MAX_DESCRIPTION_LENGTH constant.
setDescription in interface Nameabledescription - The new description for the item
PermissionDeniedException - If the logged in user doesn't
have write permission
InvalidDataException - If the description longer
than specified by the Nameable.MAX_DESCRIPTION_LENGTH constantpublic boolean isRemoved()
Removable
isRemoved in interface Removable
public void setRemoved(boolean removed)
throws PermissionDeniedException
Removable
setRemoved in interface Removableremoved - TRUE if the item should be flagged as removed,
FALSE otherwise
PermissionDeniedException - If the logged in user doesn't
have Permission.DELETE permission for setting the flag
to TRUE or Permission.WRITE permission for setting the
flag to FALSEpublic Date getEntryDate()
Registered
getEntryDate in interface Registered
public boolean isUsed()
throws BaseException
ExtraValue:s of this type exists
isUsed in class BasicItem<ExtraValueTypeData>BaseException - If not able to tell if item is used or not.BasicItem.getUsingItems()public Set<ItemProxy> getUsingItems()
ExtraValue:s of this type
getUsingItems in class BasicItem<ExtraValueTypeData>BasicItem.addUsingItems(Set, Item, org.hibernate.Query)public Type getValueType()
private void setValueType(Type valueType)
throws InvalidDataException
InvalidDataExceptionVirtualColumn.extraValue(Type)public String getExternalId()
ExtraValueType item.
public void setExternalId(String externalId)
throws PermissionDeniedException,
InvalidDataException
Client item. The value
cannot be null and must not be longer than the value specified by
the MAX_EXTERNAL_ID_LENGTH constant.
externalId - The new external id for this item
PermissionDeniedException - If the logged in user doesn't have
write permission
InvalidDataException - If the new value is null or longer than
MAX_EXTERNAL_ID_LENGTHpublic Coloring getColoring()
Coloring objectpublic Formula.AverageMethod getAverageMethod()
Formula.AverageMethod object
public void setAverageMethod(Formula.AverageMethod averageMethod)
throws PermissionDeniedException,
InvalidDataException
averageMethod - A Formula.AverageMethod object, null is not allowed
PermissionDeniedException - If the logged in user doesn't have
write permission
InvalidDataException - If the averageMethod is null
|
3.1.1: 2012-03-29 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||