projects
/
platform
/
core
/
appfw
/
pkgmgr-info.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Refactor pkgmgr-info
[platform/core/appfw/pkgmgr-info.git]
/
src
/
server
/
database
/
abstract_db_handler.hh
diff --git
a/src/server/database/abstract_db_handler.hh
b/src/server/database/abstract_db_handler.hh
index
e552a78
..
c9d2680
100644
(file)
--- a/
src/server/database/abstract_db_handler.hh
+++ b/
src/server/database/abstract_db_handler.hh
@@
-24,6
+24,7
@@
#include <sys/types.h>
#include <sqlite3.h>
#include <sys/types.h>
#include <sqlite3.h>
+#include <database.hpp>
#include "db_type.hh"
#include "query_parcelable.hh"
#include "db_type.hh"
#include "query_parcelable.hh"
@@
-49,27
+50,28
@@
class EXPORT_API AbstractDBHandler {
protected:
virtual bool Connect();
protected:
virtual bool Connect();
+ virtual const std::vector<std::pair<tizen_base::Database, uid_t>>&
+ GetConnection();
int GetPID();
uid_t GetUID();
int GetPID();
uid_t GetUID();
-
virtual std::vector<std::pair<sqlite3*, uid_t>> GetConnection
();
+
std::vector<std::pair<std::string, uid_t>> GetDBPath
();
void ClearDBHandle();
const std::string& GetLocale();
void ClearDBHandle();
const std::string& GetLocale();
+ static uid_t GetDefaultUser();
- static std::shared_timed_mutex lock_;
+ protected:
+ static std::shared_mutex lock_;
private:
private:
- std::vector<std::pair<std::string, uid_t>> GetDBPath();
-
pkgmgr_common::DBType db_type_;
pkgmgr_common::DBOperationType op_type_;
uid_t uid_;
pid_t pid_;
std::string locale_;
pkgmgr_common::DBType db_type_;
pkgmgr_common::DBOperationType op_type_;
uid_t uid_;
pid_t pid_;
std::string locale_;
- std::vector<std::pair<
sqlite3*
, uid_t>> db_handle_list_;
+ std::vector<std::pair<
tizen_base::Database
, uid_t>> db_handle_list_;
};
} // namespace database
} // namespace pkgmgr_server
#endif // ABSTRACT_DB_HANDLER_HH_
};
} // namespace database
} // namespace pkgmgr_server
#endif // ABSTRACT_DB_HANDLER_HH_
-