Last update: 2011-06-23

org.proteios.core
Class SearchDatabase

java.lang.Object
  extended by org.proteios.core.BasicItem<D>
      extended by org.proteios.core.OwnedItem<D>
          extended by org.proteios.core.SharedItem<D>
              extended by org.proteios.core.CommonItem<SearchDatabaseData>
                  extended by org.proteios.core.SearchDatabase
All Implemented Interfaces:
AccessControlled, Identifiable, Nameable, Ownable, Removable, Shareable

public class SearchDatabase
extends CommonItem<SearchDatabaseData>

This class represent spectrumsearch.

Version:
2.0
Author:
Fredrik
Last modified
$Date: 2010-06-09 14:17:16 +0200 (Wed, 09 Jun 2010) $

Field Summary
static int MAX_NAME_LENGTH
          The maximum length of the name string that can be stored in the database.
static int MAX_TAXONOMY_LENGTH
          The maximum length of the taxonomy string that can be stored in the database.
static Item TYPE
          The type of item represented by this class.
 
Fields inherited from interface org.proteios.core.Nameable
MAX_DESCRIPTION_LENGTH
 
Method Summary
 Set<Annotatable> getAnnotatableParents()
          Always null.
 String getName()
          Get the Name of this SearchDatabase.
 int getNumberOfEntries()
           
 int getNumberOfEntriesAfterTaxonomy()
           
 long getNumberOfResidues()
           
static ItemQuery<SearchDatabase> getQuery()
          Get a query that returns spectrumsearchset items.
 Date getReleaseDate()
           
 SpectrumSearch getSpectrumSearch()
          Get the SpectrumSearch this SearchDatabase is associated with.
 String getTaxonomy()
          Get the taxonomy of this SearchDatabase.
 Item getType()
          Get the type of item represented by the object.
 String getVersionIdentifier()
           
 boolean isUsed()
          Check that: no item has been created from this peaklistset
 void setName(String name)
          Set the name for this DigrestParameter item.
 void setNumberOfEntries(int numberOfEntries)
           
 void setNumberOfEntriesAfterTaxonomy(int numberOfEntriesAfterTaxonomy)
           
 void setNumberOfResidues(long numberOfResidues)
           
 void setReleaseDate(Date date)
           
 void setSpectrumSearch(SpectrumSearch spectrumSearch)
          Set the SpectrumSearch this SearchDatabase is associated with.
 void setTaxonomy(String taxonomy)
          Set the taxonomy for this SearchDatabase item.
 void setVersionIdentifier(String versionIdentifier)
           
 
Methods inherited from class org.proteios.core.CommonItem
getDescription, isRemoved, setDescription, setRemoved
 
Methods inherited from class org.proteios.core.SharedItem
getItemKey, getProjectKey, isShared, setItemKey, setProjectKey
 
Methods inherited from class org.proteios.core.OwnedItem
getOwner, setOwner
 
Methods inherited from class org.proteios.core.BasicItem
checkPermission, equals, getDbControl, getId, getPermissions, getSessionControl, getVersion, hashCode, hasPermission, isDetached, isInDatabase, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.proteios.core.Identifiable
getId, getVersion
 
Methods inherited from interface org.proteios.core.AccessControlled
checkPermission, hasPermission
 
Methods inherited from interface org.proteios.core.Ownable
getOwner, setOwner
 

Field Detail

TYPE

public static final Item TYPE
The type of item represented by this class.

See Also:
Item.PROTEIOS_SEARCHDATABASE, getType()

MAX_NAME_LENGTH

public static final int MAX_NAME_LENGTH
The maximum length of the name string that can be stored in the database.

See Also:
setName(String), Constant Field Values

MAX_TAXONOMY_LENGTH

public static final int MAX_TAXONOMY_LENGTH
The maximum length of the taxonomy string that can be stored in the database.

See Also:
setTaxonomy(String), Constant Field Values
Method Detail

getQuery

public static ItemQuery<SearchDatabase> getQuery()
Get a query that returns spectrumsearchset items.

Returns:
An ItemQuery object.

getType

public Item getType()
Description copied from interface: Identifiable
Get the type of item represented by the object. The returned value is one of the values defined in the Item enumeration.

Returns:
A value indicating the type of item

getAnnotatableParents

public Set<Annotatable> getAnnotatableParents()
                                       throws BaseException
Always null.

Throws:
BaseException

isUsed

public boolean isUsed()
               throws BaseException
Check that:

Specified by:
isUsed in class BasicItem<SearchDatabaseData>
Returns:
TRUE if this item is used, FALSE otherwise
Throws:
BaseException

getSpectrumSearch

public SpectrumSearch getSpectrumSearch()
                                 throws BaseException
Get the SpectrumSearch this SearchDatabase is associated with.

Returns:
The SpectrumSearch item or null if not known
Throws:
BaseException - If there is another error

setSpectrumSearch

public void setSpectrumSearch(SpectrumSearch spectrumSearch)
                       throws BaseException
Set the SpectrumSearch this SearchDatabase is associated with.

Parameters:
spectrumSearch - The new SpectrumSearch item
Throws:
BaseException - If there is another error

getNumberOfEntries

public int getNumberOfEntries()
Returns:
Returns the numberOfEntries.

setNumberOfEntries

public void setNumberOfEntries(int numberOfEntries)
Parameters:
numberOfEntries - The numberOfEntries to set.

getNumberOfEntriesAfterTaxonomy

public int getNumberOfEntriesAfterTaxonomy()
Returns:
Returns the numberOfEntriesAfterTaxonomy.

setNumberOfEntriesAfterTaxonomy

public void setNumberOfEntriesAfterTaxonomy(int numberOfEntriesAfterTaxonomy)
Parameters:
numberOfEntriesAfterTaxonomy - The numberOfEntriesAfterTaxonomy to set.

getNumberOfResidues

public long getNumberOfResidues()
Returns:
Returns the numberOfResidues.

setNumberOfResidues

public void setNumberOfResidues(long numberOfResidues)
Parameters:
numberOfResidues - The numberOfResidues to set.

getName

public String getName()
Get the Name of this SearchDatabase.

Specified by:
getName in interface Nameable
Overrides:
getName in class CommonItem<SearchDatabaseData>
Returns:
the name of this digest parameter

setName

public void setName(String name)
             throws InvalidDataException
Set the name for this DigrestParameter item. The value may be null but must not be longer than the value specified by the MAX_NAME_LENGTH constant.

Specified by:
setName in interface Nameable
Overrides:
setName in class CommonItem<SearchDatabaseData>
Parameters:
name - The new name for this item
Throws:
InvalidDataException - If the name is longer than MAX_NAME_LENGTH

getTaxonomy

public String getTaxonomy()
Get the taxonomy of this SearchDatabase.

Returns:
the taxonomy description

setTaxonomy

public void setTaxonomy(String taxonomy)
                 throws InvalidDataException
Set the taxonomy for this SearchDatabase item. The value may be null but must not be longer than the value specified by the MAX_TAXONOMY_LENGTH constant.

Parameters:
taxonomy - The new taxonomy for this item
Throws:
InvalidDataException - If the taxonomy is longer than MAX_TAXONOMY_LENGTH

getReleaseDate

public Date getReleaseDate()
Returns:
Returns the release date.

setReleaseDate

public void setReleaseDate(Date date)
Parameters:
date - The release date.

getVersionIdentifier

public String getVersionIdentifier()
Returns:
Returns the database version identifier.

setVersionIdentifier

public void setVersionIdentifier(String versionIdentifier)
Parameters:
versionIdentifier - The database version identifier to set.

Last update: 2011-06-23