blob: 08569b2e27c2917f3ba37bcbecfc72e6fae8be7e (
plain)
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
|
<?php
class FreshRSS_Factory {
public static function createFeedDao() {
$db = Minz_Configuration::dataBase();
if ($db['type'] === 'sqlite') {
return new FreshRSS_FeedDAOSQLite();
} else {
return new FreshRSS_FeedDAO();
}
}
public static function createEntryDao() {
$db = Minz_Configuration::dataBase();
if ($db['type'] === 'sqlite') {
return new FreshRSS_EntryDAOSQLite();
} else {
return new FreshRSS_EntryDAO();
}
}
public static function createStatsDAO() {
$db = Minz_Configuration::dataBase();
if ($db['type'] === 'sqlite') {
return new FreshRSS_StatsDAOSQLite();
} else {
return new FreshRSS_StatsDAO();
}
}
}
|