BioPerl-DB

 view release on metacpan or  search on metacpan

lib/Bio/DB/BioSQL/mysql/AnnotationCollectionAdaptorDriver.pm  view on Meta::CPAN

use vars qw(@ISA);
use strict;

# Object preamble - inherits from Bio::Root::Root

use Bio::DB::BioSQL::mysql::BasePersistenceAdaptorDriver;

@ISA = qw(Bio::DB::BioSQL::mysql::BasePersistenceAdaptorDriver);

# new() is inherited

=head2 insert_object

 Title   : insert_object
 Usage   :
 Function: See parent class. We override this here because
           AnnotationCollection in the mysql biosql schema doesn''t
           really correspond to its own entity. I.e., we do (almost)
           nothing here.

 Example :
 Returns : The primary key of the newly inserted record.
 Args    : A Bio::DB::BioSQL::BasePersistenceAdaptor derived object
           (basically, it needs to implement dbh(), sth($key, $sth),
	    dbcontext(), and get_persistent_slots()).
	   The object to be inserted.
           A reference to an array of foreign key objects; if any of those
           foreign key values is NULL (some foreign keys may be nullable),
           then give the class name.


=cut

sub insert_object{
    my ($self,$adp,$obj,$fkobjs) = @_;

    # return a virtual PK
    return -1;
}

=head2 update_object

 Title   : update_object
 Usage   :
 Function: See parent class. We override this here to not do anything in
           particular, as AnnotationCollection is only a virtual entity.

 Example :
 Returns : The number of updated rows
 Args    : A Bio::DB::BioSQL::BasePersistenceAdaptor derived object
           (basically, it needs to implement dbh(), sth($key, $sth),
	    dbcontext(), and get_persistent_slots()).
	   The object to be updated.
           A reference to an array of foreign key objects; if any of those
           foreign key values is NULL (some foreign keys may be nullable),
           then give the class name.


=cut

sub update_object{
    my ($self,$adp,$obj,$fkobjs) = @_;
    
    return 1;
}


1;



( run in 1.091 second using v1.01-cache-2.11-cpan-39bf76dae61 )