Archive Ensembl HomeArchive Ensembl Home
Bio::EnsEMBL::Compara::DBSQL::TagAdaptor Class Reference
Inheritance diagram for Bio::EnsEMBL::Compara::DBSQL::TagAdaptor:

List of all members.


Class Summary

Description

Generic adaptor that gives a database backend for tags / attributes (to
use with Bio::EnsEMBL::Compara::Taggable). There can be any number of
values for tags, but at most one for each attribute.
 

Definition at line 12 of file TagAdaptor.pm.

Available Methods

protected void _delete_tagvalue ()
protected void _load_tagvalues ()
protected void _read_attr_list ()
protected void _store_tagvalue ()
protected Array _tag_capabilities ()
public void sync_tags_to_database ()

Method Documentation

protected void Bio::EnsEMBL::Compara::DBSQL::TagAdaptor::_delete_tagvalue ( )
  Description: removes a tag from the database
  Arg [1]    : <scalar> object
  Arg [2]    : <string> tag
  Arg [3]    : (optional) <string> value
  Example    : $speciesset_adaptor->_delete_tagvalue($species_set, "colour");
  Returntype : none
  Exceptions : none
  Caller     : internal
 
Code:
click to view
protected void Bio::EnsEMBL::Compara::DBSQL::TagAdaptor::_load_tagvalues ( )
  Description: retrieves all the tags and attributes from the database and
               calls add_tag to store them in the PERL hash
  Arg [1]    : <scalar> reference object
  Example    : $genetree_adaptor->_load_tagvalues($tree);
  Returntype : none
  Exceptions : none
  Caller     : internal
 
Code:
click to view

Reimplemented in Bio::EnsEMBL::Compara::DBSQL::NCBITaxonAdaptor.

protected void Bio::EnsEMBL::Compara::DBSQL::TagAdaptor::_read_attr_list ( )
  Description: retrieves the column names of an attribute table
  Arg [1]    : <scalar> table name
  Example    : $genetree_adaptor->_read_attr_list('protein_tree_node_attr');
  Returntype : none
  Exceptions : none
  Caller     : internal
 
Code:
click to view
protected void Bio::EnsEMBL::Compara::DBSQL::TagAdaptor::_store_tagvalue ( )
  Arg [1]    : <scalar> object
  Arg [2]    : <string> tag
  Arg [3]    : <string> value
  Arg [4]    : (optional) <int> allows overloading the tag with different values
               default is 0 (no overloading allowed, one tag points to one value)
  Example    : $speciesset_adaptor->_store_tagvalue($species_set, "colour", "red");
  Returntype : none
  Exceptions : none
  Caller     : internal
 
Code:
click to view
protected Array Bio::EnsEMBL::Compara::DBSQL::TagAdaptor::_tag_capabilities ( )
  Description: returns the tag/attributes capabilities for the object. The
               return value is an array with 4 entries:

  • the name of the table to store tag
  • the name of the table to store attribute
  • the name of the key column in the tables
  • the name of the perl method to have the key value Arg [1] : <scalar> reference object Example : return ("species_set_tag", undef, "species_set_id", "dbID"); Returntype : Array of 4 entries Exceptions : none Caller : internal
 
Code:
click to view

Reimplemented in Bio::EnsEMBL::Compara::DBSQL::GeneTreeAdaptor, Bio::EnsEMBL::Compara::DBSQL::MethodLinkSpeciesSetAdaptor, and Bio::EnsEMBL::Compara::DBSQL::SpeciesSetAdaptor.

public void Bio::EnsEMBL::Compara::DBSQL::TagAdaptor::sync_tags_to_database ( )
  Description: rewrites all the tags from memory to the database
  Arg [1]    : <scalar> object
  Example    : $speciesset_adaptor->sync_tags_to_database($species_set);
  Returntype : none
  Exceptions : none
  Caller     : general
 
Code:
click to view

The documentation for this class was generated from the following file: