]> git.donarmstrong.com Git - debbugs.git/blob - Debbugs/DB/Result/BinVer.pm
0ac574580b2687871a9fe3a21f560b87bf06e601
[debbugs.git] / Debbugs / DB / Result / BinVer.pm
1 use utf8;
2 package Debbugs::DB::Result::BinVer;
3
4 # Created by DBIx::Class::Schema::Loader
5 # DO NOT MODIFY THE FIRST PART OF THIS FILE
6
7 =head1 NAME
8
9 Debbugs::DB::Result::BinVer
10
11 =cut
12
13 use strict;
14 use warnings;
15
16 use base 'DBIx::Class::Core';
17
18 =head1 COMPONENTS LOADED
19
20 =over 4
21
22 =item * L<DBIx::Class::InflateColumn::DateTime>
23
24 =back
25
26 =cut
27
28 __PACKAGE__->load_components("InflateColumn::DateTime");
29
30 =head1 TABLE: C<bin_ver>
31
32 =cut
33
34 __PACKAGE__->table("bin_ver");
35
36 =head1 ACCESSORS
37
38 =head2 id
39
40   data_type: 'integer'
41   is_auto_increment: 1
42   is_nullable: 0
43   sequence: 'bin_ver_id_seq'
44
45 =head2 bin_pkg_id
46
47   data_type: 'integer'
48   is_foreign_key: 1
49   is_nullable: 0
50
51 =head2 src_ver_id
52
53   data_type: 'integer'
54   is_foreign_key: 1
55   is_nullable: 0
56
57 =head2 arch_id
58
59   data_type: 'integer'
60   is_foreign_key: 1
61   is_nullable: 0
62
63 =head2 ver
64
65   data_type: 'debversion'
66   is_nullable: 0
67
68 =cut
69
70 __PACKAGE__->add_columns(
71   "id",
72   {
73     data_type         => "integer",
74     is_auto_increment => 1,
75     is_nullable       => 0,
76     sequence          => "bin_ver_id_seq",
77   },
78   "bin_pkg_id",
79   { data_type => "integer", is_foreign_key => 1, is_nullable => 0 },
80   "src_ver_id",
81   { data_type => "integer", is_foreign_key => 1, is_nullable => 0 },
82   "arch_id",
83   { data_type => "integer", is_foreign_key => 1, is_nullable => 0 },
84   "ver",
85   { data_type => "debversion", is_nullable => 0 },
86 );
87
88 =head1 PRIMARY KEY
89
90 =over 4
91
92 =item * L</id>
93
94 =back
95
96 =cut
97
98 __PACKAGE__->set_primary_key("id");
99
100 =head1 UNIQUE CONSTRAINTS
101
102 =head2 C<bin_ver_bin_pkg_id_arch_idx>
103
104 =over 4
105
106 =item * L</bin_pkg_id>
107
108 =item * L</arch_id>
109
110 =item * L</ver>
111
112 =back
113
114 =cut
115
116 __PACKAGE__->add_unique_constraint(
117   "bin_ver_bin_pkg_id_arch_idx",
118   ["bin_pkg_id", "arch_id", "ver"],
119 );
120
121 =head2 C<bin_ver_src_ver_id_arch_idx>
122
123 =over 4
124
125 =item * L</src_ver_id>
126
127 =item * L</arch_id>
128
129 =back
130
131 =cut
132
133 __PACKAGE__->add_unique_constraint("bin_ver_src_ver_id_arch_idx", ["src_ver_id", "arch_id"]);
134
135 =head1 RELATIONS
136
137 =head2 arch
138
139 Type: belongs_to
140
141 Related object: L<Debbugs::DB::Result::Arch>
142
143 =cut
144
145 __PACKAGE__->belongs_to(
146   "arch",
147   "Debbugs::DB::Result::Arch",
148   { id => "arch_id" },
149   { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" },
150 );
151
152 =head2 bin_associations
153
154 Type: has_many
155
156 Related object: L<Debbugs::DB::Result::BinAssociation>
157
158 =cut
159
160 __PACKAGE__->has_many(
161   "bin_associations",
162   "Debbugs::DB::Result::BinAssociation",
163   { "foreign.bin" => "self.id" },
164   { cascade_copy => 0, cascade_delete => 0 },
165 );
166
167 =head2 bin_pkg
168
169 Type: belongs_to
170
171 Related object: L<Debbugs::DB::Result::BinPkg>
172
173 =cut
174
175 __PACKAGE__->belongs_to(
176   "bin_pkg",
177   "Debbugs::DB::Result::BinPkg",
178   { id => "bin_pkg_id" },
179   { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" },
180 );
181
182 =head2 src_ver
183
184 Type: belongs_to
185
186 Related object: L<Debbugs::DB::Result::SrcVer>
187
188 =cut
189
190 __PACKAGE__->belongs_to(
191   "src_ver",
192   "Debbugs::DB::Result::SrcVer",
193   { id => "src_ver_id" },
194   { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" },
195 );
196
197
198 # Created by DBIx::Class::Schema::Loader v0.07025 @ 2012-11-25 00:09:07
199 # DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:ID7wx8HJaYZgpdhHqCq8GQ
200
201
202 # You can replace this text with custom code or comments, and it will be preserved on regeneration
203 1;