NAME
Bio::Das::ProServer::SourceAdaptor::Transport::ensembl
VERSION
$LastChangedRevision: 535 $
SYNOPSIS
A transport for using the Registry to retrieve Ensembl data.
DESCRIPTION
This class is a Transport that provides an interface to the Ensembl API. It uses the Ensembl Resistry to determine the location of the appropriate databases, and can be used in a species specific or cross-species manner. The main advantage of using this Transport is that the registry automatically provides access to the latest data available to the installed API.
SUBROUTINES/METHODS
init - Post-construction initialisation.
$oTransport->init();
Loads the registry from the Ensembl database, and applies a custom database
override if specified.
adaptor - Gets an Ensembl adaptor.
$oAdaptor = $oTransport->adaptor();
$oAdaptor = $oTransport->adaptor('human', 'core');
Arguments:
species (optional, default configured in INI or 'human')
database group (optional, default configured in INI or 'core')
Returns:
L<Bio::EnsEMBL::DBSQL::DBAdaptor>
slice_adaptor - Gets an Ensembl slice adaptor.
$oAdaptor = $oTransport->slice_adaptor();
$oAdaptor = $oTransport->slice_adaptor('human', 'core');
Arguments:
species (optional, default configured in INI or 'human')
database group (optional, default configured in INI or 'core')
Returns:
L<Bio::EnsEMBL::DBSQL::SliceAdaptor>
gene_adaptor - Gets an Ensembl gene adaptor.
$oAdaptor = $oTransport->gene_adaptor();
$oAdaptor = $oTransport->gene_adaptor('human', 'core');
Arguments:
species (optional, default configured in INI or 'human')
database group (optional, default configured in INI or 'core')
Returns:
L<Bio::EnsEMBL::DBSQL::GeneAdaptor>
chromosome_by_region - Gets a chromosome slice.
$oSlice = $oTransport->chromosome_by_region('X');
$oSlice = $oTransport->chromosome_by_region('X', 123453, 132424);
$oSlice = $oTransport->chromosome_by_region('X', 123453, 132424, 'human', 'core');
Arguments:
chromosome # (required)
start (optional)
end (optional)
species (optional, default configured in INI or 'human')
database group (optional, default configured in INI or 'core')
Returns:
L<Bio::EnsEMBL::Slice>
chromosomes - Gets all chromosomes.
$aSlices = $oTransport->chromosomes();
$aSlices = $oTransport->chromosomes('human', 'core');
Arguments:
species (optional, default configured in INI or 'human')
database group (optional, default configured in INI or 'core')
Returns:
listref of L<Bio::EnsEMBL::Slice> objects
gene_by_id - Gets a gene.
$oGene = $oTransport->gene_by_id('ENSG00000139618'); # BRCA2
$oGene = $oTransport->gene_by_id('ENSG00000139618', 'human', 'core');
Arguments:
gene stable ID (required)
species (optional, default configured in INI or 'human')
database group (optional, default configured in INI or 'core')
Returns:
L<Bio::EnsEMBL::Gene>
genes - Gets all genes.
$aGenes = $oTransport->genes();
$aGenes = $oTransport->genes('human', 'core');
Arguments:
species (optional, default configured in INI or 'human')
database group (optional, default configured in INI or 'core')
Returns:
listref of L<Bio::EnsEMBL::Gene> objects
version - Gets the Ensembl API's release number.
$sVersion = $oTransport->version();
last_modified - Gets a last modified date from the database.
$sVersion = $oTransport->version();
disconnect - ProServer hook to disconnect all connected databases.
$oTransport->disconnect();
CONFIGURATION AND ENVIRONMENT
Configured as part of each source's ProServer 2 INI file.
The transport will automatically load database connection settings from
the Ensembl Registry at ensembldb.ensembl.org. To skip this, set the
'skip_registry' INI property.
A specific database may also be overridden using these INI properties:
dbname
host (defaults to localhost)
port (defaults to 3306)
username (defaults to ensro)
password
The 'default database' used in the transport's data access methods may be
configured using these INI properties:
species (defaults to human)
group (defaults to core)
DIAGNOSTICS
CONFIGURATION AND ENVIRONMENT
DEPENDENCIES
- Carp
- Bio::Das::ProServer::SourceAdaptor::Transport::generic
- Ensembl core API
- Additional Ensembl APIs if used
INCOMPATIBILITIES
None reported
BUGS AND LIMITATIONS
None reported
REFERENCES
AUTHOR
Andy Jenkinson <andy.jenkinson@ebi.ac.uk>
LICENSE AND COPYRIGHT
Copyright (c) 2007 EMBL-EBI