346ecb54079c47de121d7c5df26d9ee14016883e
[mir.git] / source / mircoders / storage / DatabaseImageFormat.java
1 package mircoders.storage;
2
3 import java.lang.*;
4 import java.sql.*;
5 import java.io.*;
6 import java.util.*;
7
8 import freemarker.template.*;
9
10 import mir.storage.*;
11 import mir.entity.*;
12 import mir.misc.*;
13
14 /**
15  * <b>Diese Klasse implementiert die Datenbankverbindung zur MetaObjekt-Tabelle
16  *
17  *
18  */
19
20 public class DatabaseImageFormat extends Database implements StorageObject{
21
22         private static DatabaseImageFormat instance;
23         private static SimpleList publisherPopupData;
24
25         // the following *has* to be sychronized cause this static method
26         // could get preemted and we could end up with 2 instances of DatabaseFoo..
27         // see the "Singletons with needles and thread" article at JavaWorld -mh
28         public synchronized static DatabaseImageFormat getInstance() 
29           throws StorageObjectException
30         {
31                 if (instance == null) {
32                         instance = new DatabaseImageFormat();
33                         instance.myselfDatabase = instance;
34                 }
35                 return instance;
36         }
37
38         private DatabaseImageFormat() throws StorageObjectException
39         {
40                 super();
41                 this.hasTimestamp = false;
42                 this.theTable="img_format";
43         }
44
45         public SimpleList getPopupData()
46         throws StorageObjectException { return getPopupData("name",true); }
47
48
49 }