9 A data container
object that links together an adaptor, a table and a preferred insertion method (insert/insert-ignore/replace).
10 This
object is generated from specially designed datalow URLs.
14 Copyright [1999-2015] Wellcome Trust Sanger Institute and the EMBL-European Bioinformatics Institute
15 Copyright [2016-2024] EMBL-European Bioinformatics Institute
17 Licensed under the Apache License,
Version 2.0 (the
"License"); you may not use
this file except in compliance with the License.
18 You may obtain a copy of the License at
22 Unless required by applicable law or agreed to in writing, software distributed under the License
23 is distributed on an
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
24 See the License
for the specific language governing permissions and limitations under the License.
28 Please subscribe to the
Hive mailing list: http:
33 package Bio::EnsEMBL::Hive::NakedTable;
38 use base (
'Bio::EnsEMBL::Hive::Storable' );
41 sub unikey { #
override the
default from
Cacheable parent
42 return [
'table_name' ];
50 $self->{
'_table_name'} = shift @_;
52 return $self->{
'_table_name'};
56 sub insertion_method {
60 $self->{
'_insertion_method'} = shift @_;
62 return $self->{
'_insertion_method'} ||
'INSERT_IGNORE';
66 sub url_query_params {
69 return { # direct access to the actual (possibly missing) values
70 'table_name' => $self->table_name,
71 'insertion_method' => $self->{
'_insertion_method'},
78 return $self->table_name;
83 my ( $self, $output_ids, $emitting_job ) = @_;
85 my $adaptor = $self->adaptor();
86 my @column_names = keys %{$self->adaptor->column_set};
89 foreach my $output_id (@$output_ids) {
91 foreach my $column (@column_names) {
92 $row_hash{ $column } = $emitting_job->_param_possibly_overridden($column, $output_id);
94 push @rows, \%row_hash;
96 $adaptor->store( \@rows );
103 return 'NakedTable('.$self->table_name.
')';