-
Notifications
You must be signed in to change notification settings - Fork 0
/
fedoraobject.install
108 lines (104 loc) · 2.98 KB
/
fedoraobject.install
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
<?php
function fedoraobject_schema() {
$schema['fedoraobject'] = array(
'description' => 'The base table for Fedora objects',
'fields' => array(
'foid' => array(
'description' => 'The primary identifier for a fedora object within Drupal.',
'type' => 'serial',
'unsigned' => TRUE,
'not null' => TRUE,
),
'vid' => array(
'description' => 'The current {fedoraobject_revision}.vid version identifier.',
'type' => 'int',
'unsigned' => TRUE,
'not null' => TRUE,
'default' => 0,
),
'pid' => array(
'description' => 'The persistent identifier (PID) of the object within Fedora',
'type' => 'varchar',
'length' => 64,
'not null' => TRUE,
'default' => '',
),
'type' => array(
'description' => 'The content model of this fedora object.',
'type' => 'varchar',
'length' => 32,
'not null'=> TRUE,
'default' => '',
),
'title' => array(
'description' => 'The title of the fedora object',
'type' => 'varchar',
'length' => 255,
'not null' => TRUE,
'default' => '',
),
'created' => array(
'description' => 'The Unix timestamp when the fedora object was created',
'type' => 'int',
'not null' => TRUE,
'default' => 0,
),
'changed' => array(
'description' => 'The Unix timestamp when the fedora object was most recently changed.',
'type' => 'int',
'not null' => TRUE,
'default' => 0,
),
),
'unique keys' => array(
'foid_vid' => array('foid', 'vid'),
'foid' => array('foid'),
'pid' => array('pid'),
),
'primary_key' => array('foid'),
);
$schema['fedoraobject_revision'] = array(
'description' => 'Stores information about each saved version of a {fedoraobject}.',
'fields' => array(
'foid' => array(
'description' => 'The fedora object this version belongs to.',
'type' => 'int',
'unsigned' => TRUE,
'not null' => TRUE,
'default' => 0,
),
'vid' => array(
'description' => 'The primary identifier for this version.',
'type' => 'serial',
'unsigned' => TRUE,
'not null' => TRUE,
),
'title' => array(
'description' => 'The title of this version.',
'type' => 'varchar',
'length' => 255,
'not null' => TRUE,
'default' => '',
),
'created' => array(
'description' => 'The Unix timestamp when the fedora object was created.',
'type' => 'int',
'not null' => TRUE,
'default' => 0,
),
),
'indexes' => array(
'foid' => array('foid'),
),
'primary key' => array('vid'),
'foreign keys' => array(
'fedoraobject' => array(
'table' => 'fedoraobject',
'columns' => array(
'foid' => 'foid',
),
),
),
);
return $schema;
}