ensembl-hive  2.6
Bio::EnsEMBL::Storable Class Reference
+ Inheritance diagram for Bio::EnsEMBL::Storable:

Public Member Functions

public Bio::EnsEMBL::Storable new ()
 
public Instance new_fast ()
 
public Int dbID ()
 
public Bio::EnsEMBL::DBSQL::BaseAdaptor adaptor ()
 
public Boolean is_stored ()
 
public get_all_DAS_Features ()
 

Detailed Description

Synopsis

my $dbID = $storable_object->dbID();
my $adaptor = $storable_object->adaptor();
if ( $storable_object->is_stored($db_adaptor) ) { ... }

Description

This is a storable base class.  All objects which are storable
in the database should inherit from this class.  It provides two
getter/setters: dbID() adaptor().  And a is_stored() method that can be
used to determine if an object is already stored in a database.

Definition at line 23 of file Storable.pm.

Member Function Documentation

◆ adaptor()

public Bio::EnsEMBL::DBSQL::BaseAdaptor Bio::EnsEMBL::Storable::adaptor ( )
  Arg [1]    : Bio::EnsEMBL::DBSQL::BaseAdaptor $adaptor
  Description: get/set for this objects Adaptor
  Returntype : Bio::EnsEMBL::DBSQL::BaseAdaptor
  Exceptions : none
  Caller     : general, set from adaptor on store
  Status     : Stable
 
Code:
click to view

◆ dbID()

public Int Bio::EnsEMBL::Storable::dbID ( )
  Arg [1]    : int $dbID
  Description: getter/setter for the database internal id
  Returntype : int
  Exceptions : none
  Caller     : general, set from adaptor on store
  Status     : Stable
 
Code:
click to view

◆ get_all_DAS_Features()

public Bio::EnsEMBL::Storable::get_all_DAS_Features ( )

Undocumented method

Code:
click to view

◆ is_stored()

public Boolean Bio::EnsEMBL::Storable::is_stored ( )
  Arg [1]    : Bio::EnsEMBL::DBSQL::DBConnection 
             : or Bio::EnsEMBL::DBSQL::DBAdaptor
  Example    :
do_something if($object->is_stored($db));
  Description: Returns true if this object is stored in the provided database.
               This works under the assumption that if the adaptor and dbID are
               set and the database of the adaptor shares the port, dbname and
               hostname with the provided database, this object is stored in
               that database.
  Returntype : 1 or 0
  Exceptions : throw if dbID is set but adaptor is not
               throw if adaptor is set but dbID is not
               throw if incorrect argument is passed
  Caller     : store methods
  Status     : Stable
 
Code:
click to view

◆ new()

public Bio::EnsEMBL::Storable Bio::EnsEMBL::Storable::new ( )
  Arg [-ADAPTOR] : Bio::EnsEMBL::DBSQL::BaseAdaptor
  Arg [-dbID]    : database internal id
  Caller         : internal calls
  Description    : create a new Storable object 
  Returntype     : Bio::EnsEMBL::Storable
  Exceptions     : Adaptor not a Bio::EnsEMBL::DBSQL::BaseAdaptor
  Status         : Stable
 
Code:
click to view

◆ new_fast()

public Instance Bio::EnsEMBL::Storable::new_fast ( )
  Arg [1]    : hashref to be blessed
  Description: Construct a new Bio::EnsEMBL::Storable object using the hashref.
               This is a very quick constructor that requires internal knowledge 
               of the class. This is used in speed critical sections of the code
               where many objects need to be created quickly.
  Exceptions : none
  Returntype : Instance of Bio::EnsEMBL::Storable subclass
  Caller     : general, subclass constructors
  Status     : Stable
 
Code:
click to view

The documentation for this class was generated from the following file:
Bio::EnsEMBL::Storable::dbID
public Int dbID()
Bio::EnsEMBL::Storable::is_stored
public Boolean is_stored()
Bio::EnsEMBL::Storable::new_fast
public Instance new_fast()
Bio::EnsEMBL::Storable::adaptor
public Bio::EnsEMBL::DBSQL::BaseAdaptor adaptor()
Bio::EnsEMBL::Storable::get_all_DAS_Features
public get_all_DAS_Features()