Merge pull request #42 from solgenomics/topic/duplicate_image_warning
[cxgn-corelibs.git] / lib / SGN / Schema / LinkageGroup.pm
blob29def20fe87ed61f56469d384b19866768790c67
1 package SGN::Schema::LinkageGroup;
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::LinkageGroup
16 =cut
18 __PACKAGE__->table("linkage_group");
20 =head1 ACCESSORS
22 =head2 lg_id
24 data_type: 'integer'
25 is_auto_increment: 1
26 is_nullable: 0
27 sequence: 'linkage_group_lg_id_seq'
29 =head2 map_version_id
31 data_type: 'integer'
32 is_foreign_key: 1
33 is_nullable: 1
35 =head2 lg_order
37 data_type: 'integer'
38 is_nullable: 0
40 =head2 lg_name
42 data_type: 'text'
43 is_nullable: 1
45 =head2 north_location_id
47 data_type: 'integer'
48 is_foreign_key: 1
49 is_nullable: 1
51 =head2 south_location_id
53 data_type: 'integer'
54 is_foreign_key: 1
55 is_nullable: 1
57 =cut
59 __PACKAGE__->add_columns(
60 "lg_id",
62 data_type => "integer",
63 is_auto_increment => 1,
64 is_nullable => 0,
65 sequence => "linkage_group_lg_id_seq",
67 "map_version_id",
68 { data_type => "integer", is_foreign_key => 1, is_nullable => 1 },
69 "lg_order",
70 { data_type => "integer", is_nullable => 0 },
71 "lg_name",
72 { data_type => "text", is_nullable => 1 },
73 "north_location_id",
74 { data_type => "integer", is_foreign_key => 1, is_nullable => 1 },
75 "south_location_id",
76 { data_type => "integer", is_foreign_key => 1, is_nullable => 1 },
78 __PACKAGE__->set_primary_key("lg_id");
79 __PACKAGE__->add_unique_constraint(
80 "linkage_group_map_version_id_key",
81 ["map_version_id", "lg_order"],
83 __PACKAGE__->add_unique_constraint(
84 "linkage_group_map_version_id_key1",
85 ["map_version_id", "lg_name"],
88 =head1 RELATIONS
90 =head2 north_location
92 Type: belongs_to
94 Related object: L<SGN::Schema::MarkerLocation>
96 =cut
98 __PACKAGE__->belongs_to(
99 "north_location",
100 "SGN::Schema::MarkerLocation",
101 { location_id => "north_location_id" },
103 is_deferrable => 1,
104 join_type => "LEFT",
105 on_delete => "CASCADE",
106 on_update => "CASCADE",
110 =head2 map_version
112 Type: belongs_to
114 Related object: L<SGN::Schema::MapVersion>
116 =cut
118 __PACKAGE__->belongs_to(
119 "map_version",
120 "SGN::Schema::MapVersion",
121 { map_version_id => "map_version_id" },
123 is_deferrable => 1,
124 join_type => "LEFT",
125 on_delete => "CASCADE",
126 on_update => "CASCADE",
130 =head2 south_location
132 Type: belongs_to
134 Related object: L<SGN::Schema::MarkerLocation>
136 =cut
138 __PACKAGE__->belongs_to(
139 "south_location",
140 "SGN::Schema::MarkerLocation",
141 { location_id => "south_location_id" },
143 is_deferrable => 1,
144 join_type => "LEFT",
145 on_delete => "CASCADE",
146 on_update => "CASCADE",
150 =head2 marker_locations
152 Type: has_many
154 Related object: L<SGN::Schema::MarkerLocation>
156 =cut
158 __PACKAGE__->has_many(
159 "marker_locations",
160 "SGN::Schema::MarkerLocation",
161 { "foreign.lg_id" => "self.lg_id" },
162 { cascade_copy => 0, cascade_delete => 0 },
166 # Created by DBIx::Class::Schema::Loader v0.07002 @ 2012-03-03 12:35:39
167 # DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:AeXr/gcdemGIXiaObXaycw
170 # You can replace this text with custom content, and it will be preserved on regeneration