FOSSology  4.4.0
Open Source License Compliance by Open Source Software
NinkaDatabaseHandler Class Reference
Inheritance diagram for NinkaDatabaseHandler:
Inheritance graph
Collaboration diagram for NinkaDatabaseHandler:
Collaboration graph

Public Member Functions

 NinkaDatabaseHandler (fo::DbManager dbManager)
 
 NinkaDatabaseHandler (NinkaDatabaseHandler &&other)
 
NinkaDatabaseHandler spawn () const
 
std::vector< unsigned long > queryFileIdsForUpload (int uploadId)
 
bool saveLicenseMatch (int agentId, long pFileId, long licenseId, unsigned percentMatch)
 
void insertOrCacheLicenseIdForName (std::string const &rfShortName)
 
unsigned long getCachedLicenseIdForName (std::string const &rfShortName) const
 
- Public Member Functions inherited from fo::AgentDatabaseHandler
 AgentDatabaseHandler (DbManager dbManager)
 
 AgentDatabaseHandler (AgentDatabaseHandler &&other)
 
 AgentDatabaseHandler (const AgentDatabaseHandler &)=delete
 
virtual ~AgentDatabaseHandler ()
 
AgentDatabaseHandler operator= (const AgentDatabaseHandler &)=delete
 
bool begin () const
 BEGIN a transaction block in DB. More...
 
bool commit () const
 COMMIT a transaction block in DB. More...
 
bool rollback () const
 ROLLBACK a transaction block in DB. More...
 
char * getPFileNameForFileId (unsigned long pfileId) const
 Get the file name of a give pfile id. More...
 
std::string queryUploadTreeTableName (int uploadId)
 Get the upload tree table name for a given upload id. More...
 
std::vector< unsigned long > queryFileIdsVectorForUpload (int uploadId, bool ignoreFilesWithMimeType) const
 Get pfile ids for a given upload id. More...
 
std::vector< unsigned long > queryFileIdsVectorForUpload (int uploadId, int agentId, bool ignoreFilesWithMimeType) const
 Get pfile ids for a given upload id which agent has not scanned. More...
 

Private Member Functions

unsigned long selectOrInsertLicenseIdForName (std::string rfShortname)
 

Private Attributes

std::unordered_map< std::string, long > licenseRefCache
 

Additional Inherited Members

- Protected Attributes inherited from fo::AgentDatabaseHandler
DbManager dbManager
 DbManager to use.
 

Detailed Description

Definition at line 16 of file databasehandler.hpp.


The documentation for this class was generated from the following files: