Merged filerepo-work branch:
[lhc/web/wiklou.git] / includes / filerepo / ForeignDBFile.php
1 <?php
2
3 class ForeignDBFile extends LocalFile {
4 function newFromTitle( $title, $repo ) {
5 return new self( $title, $repo );
6 }
7
8 function getCacheKey() {
9 if ( $this->repo->hasSharedCache ) {
10 $hashedName = md5($this->name);
11 return wfForeignMemcKey( $this->repo->dbName, $this->repo->tablePrefix,
12 'file', $hashedName );
13 } else {
14 return false;
15 }
16 }
17
18 function publish( /*...*/ ) {
19 $this->readOnlyError();
20 }
21
22 function recordUpload( /*...*/ ) {
23 $this->readOnlyError();
24 }
25 function restore( /*...*/ ) {
26 $this->readOnlyError();
27 }
28
29 function getDescriptionUrl() {
30 // Restore remote behaviour
31 return File::getDescriptionUrl();
32 }
33
34 function getDescriptionText() {
35 // Restore remote behaviour
36 return File::getDescriptionText();
37 }
38 }
39 ?>