Merge pull request #42 from solgenomics/topic/duplicate_image_warning
[cxgn-corelibs.git] / lib / SGN / Schema / BlastAnnotation.pm
blob8c5074ee85fa5a20190c019029e752c75798bce8
1 package SGN::Schema::BlastAnnotation;
3 # Created by DBIx::Class::Schema::Loader
4 # DO NOT MODIFY THE FIRST PART OF THIS FILE
6 use strict;
7 use warnings;
9 use base 'DBIx::Class::Core';
12 =head1 NAME
14 SGN::Schema::BlastAnnotation
16 =cut
18 __PACKAGE__->table("blast_annotations");
20 =head1 ACCESSORS
22 =head2 blast_annotation_id
24 data_type: 'integer'
25 is_auto_increment: 1
26 is_nullable: 0
27 sequence: 'blast_annotations_blast_annotation_id_seq'
29 =head2 apply_id
31 data_type: 'integer'
32 is_foreign_key: 1
33 is_nullable: 1
35 =head2 apply_type
37 data_type: 'integer'
38 is_nullable: 1
40 =head2 blast_target_id
42 data_type: 'integer'
43 is_nullable: 1
45 =head2 n_hits
47 data_type: 'integer'
48 is_nullable: 1
50 =head2 hits_stored
52 data_type: 'integer'
53 is_nullable: 1
55 =head2 last_updated
57 data_type: 'integer'
58 is_nullable: 1
60 =head2 host
62 data_type: 'varchar'
63 is_nullable: 1
64 size: 20
66 =head2 pid
68 data_type: 'integer'
69 is_nullable: 1
71 =cut
73 __PACKAGE__->add_columns(
74 "blast_annotation_id",
76 data_type => "integer",
77 is_auto_increment => 1,
78 is_nullable => 0,
79 sequence => "blast_annotations_blast_annotation_id_seq",
81 "apply_id",
82 { data_type => "integer", is_foreign_key => 1, is_nullable => 1 },
83 "apply_type",
84 { data_type => "integer", is_nullable => 1 },
85 "blast_target_id",
86 { data_type => "integer", is_nullable => 1 },
87 "n_hits",
88 { data_type => "integer", is_nullable => 1 },
89 "hits_stored",
90 { data_type => "integer", is_nullable => 1 },
91 "last_updated",
92 { data_type => "integer", is_nullable => 1 },
93 "host",
94 { data_type => "varchar", is_nullable => 1, size => 20 },
95 "pid",
96 { data_type => "integer", is_nullable => 1 },
98 __PACKAGE__->set_primary_key("blast_annotation_id");
99 __PACKAGE__->add_unique_constraint(
100 "blast_annotations_apply_id_blast_target_id_uq",
101 ["apply_id", "blast_target_id"],
104 =head1 RELATIONS
106 =head2 apply
108 Type: belongs_to
110 Related object: L<SGN::Schema::Unigene>
112 =cut
114 __PACKAGE__->belongs_to(
115 "apply",
116 "SGN::Schema::Unigene",
117 { unigene_id => "apply_id" },
119 is_deferrable => 1,
120 join_type => "LEFT",
121 on_delete => "CASCADE",
122 on_update => "CASCADE",
126 =head2 blast_hits
128 Type: has_many
130 Related object: L<SGN::Schema::BlastHit>
132 =cut
134 __PACKAGE__->has_many(
135 "blast_hits",
136 "SGN::Schema::BlastHit",
137 { "foreign.blast_annotation_id" => "self.blast_annotation_id" },
138 { cascade_copy => 0, cascade_delete => 0 },
142 # Created by DBIx::Class::Schema::Loader v0.07002 @ 2012-03-03 12:32:42
143 # DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:43aWHj56ncTWYbyZmIAs4Q
146 # You can replace this text with custom content, and it will be preserved on regeneration