Go to the documentation of this file.
167 operator bool()
const;
243 virtual ~
ExDca()
throw();
445 bool signal(
unsigned int signal )
const;
847 class dbconnection_p;
909 class updatemodule_p;
990 class updateresults_p;
1029 class updateresult_p;
1075 class updateresult_detail_p;
std::string password
proxy password associated for the given username
@ SMI_MailDb
ID for a mail database.
int DCA_MODULE_ID_TYPE
Type for module ids.
Is used to create a License object. A license first must be created with DcaInstance::createLicense t...
const int ERR_CONNECTION_PROXY
This error may occur whenever a DCA function or class attempts to connect to a remote resource via a ...
LogLevel setLogLevel(LogLevel newLevel)
Sets the logging level for the given class instance. The old value will be returned.
Exception class used in the DCA.
const DbType DBT_Mail
Used for DbConnection classes for ZLA classification.
@ SMI_UrlDb
ID for a URL database.
int DbType
Type for DbConnection classes.
@ LOG_Warning
Warnings will be logged.
bool cancelUpdate() const
Cancels a currently running update process. If there is currently no update running,...
@ SMI_IprDb
ID for a IPR database.
const int ERR_PARAMS
One or more parameter values is invalid, or a combination of parameter values is invalid.
LogLevel setLogLevel(LogLevel newLevel)
Sets the logging level for the given class instance. The old value will be returned.
const int ERR_CUSTOMDB_INVALID_CATEGORIES
Error code: The given categories are invalid.
@ SMI_MalwareDb
ID for a Malware database.
std::string oldVersion() const
Returns the version active (installed) before the update was invoked.
std::string initDir
the directory in which the DCA init files are stored
FunctionResult schedule(ScheduleEventSubscriberIntf *pScheduleEventSubscriber=NULL) const
Invokes scheduled tasks, e.g. Database updates and processes that can take a long time.
bool signal(unsigned int signal) const
Cancels functions which could potentially take a long time to return, such as DcaInstance::schedule()...
const int ERR_CONNECTION
This error may occur whenever a DCA function or class attempts to connect to a local or remote resour...
const int ERR_MEMORY_SHORTAGE
This error is returned whenever it was not possible to allocate a required amount of memory....
static UpdateModule create(const DcaInstance &aDcaInstance, const License &aLicense, const ProxySettings &proxySettings=ProxySettings())
int getMaxSessions() const
Returns the maximum allowed sessions associated with your ticket/license.
VersionInfoResults getVersionInfo() const
Returns enumerable version information about all currently loaded modules.
time_t getExpirationDate() const
Returns the expiration date of the license in UTC.
std::string getDescription() const
Returns a description of the error.
bool getCustomData(std::string &customData) const
Returns CustomData as string if available. Whether custom data are available or not depends on your t...
UpdateResultDetail at(DCA_INDEX_TYPE index) const
Allows access to the details of the result.
std::string configDir
Specifies the complete folder path where the custom database is located, or the folder in which it sh...
DbConnectionLocalData localData
Fill out this structure only if you are using a local (non-custom) database.
bool downloaded() const
true if an update sucessfully downloaded for this component, false otherwise
const int ERR_DB_UPDATE_ABORTED
Error code: A (scheduled) database update was aborted unexpectly.
UpdateResult at(DCA_INDEX_TYPE index) const
Allows access to the result with given index.
int returnCode() const
The internal code of the update, this can be any internal error code, 0 in case of success or DCA_UPD...
CategoriesInfo getCategoriesInfo(DCA_CATEGORIES_INFO_TYPE categoryType) const
Returns the DCA internal categories, groups and locales.
DatabaseInformation getDatabaseInformation() const
Returns information about the underlying database.
Encapsulates the details of a result of an update process.
DbConnectionCustomData customData
Fill out this structure only if you are using a custom database.
const int ERR_DATABASE_ALREADY_EXISTING
Error code: The specified database already exists.
DCA_RESULT_TYPE getReturnCode() const
Returns the last error code (if any).
unsigned int cacheEntryExpirationMinutes
The cache is also used to cache URL requests. This setting defines when an entry will be considered a...
bool restartRequired() const
true if an update has been installed that requires a restart of the DCA, false otherwise.
The update module is used to download and install DCA content and engine updates.
@ SAT_StopDbDownload
A complete database download has successfully finished.
bool installed() const
true if an update sucessfully installed for this component, false otherwise
@ LOG_Initial
Initial internal log level, do not use.
std::string binDir
the directory in which the DCA binary (*.dca) files are stored
@ SMI_WacDb
ID for a WAC database.
LogLevel setLogLevel(LogLevel newLevel)
Sets the logging level for the given class instance. The old value will be returned.
unsigned int encryptionKey
The encryption key to be used (provided with your license)
Encapsulates the results of an update process.
A container class that allows access to the contained Categories, Groups and Locales.
@ LOG_Notice
Write notices / important information to the log file.
@ LOG_Critical
Critical events will be logged out.
const unsigned int DCA_SIG_ABORT
Currently the only supported signal parameter for the DcaInstance::signal() function.
const int ERR_WRAPPER_UNEXPECTED
The DCA consists of a wrapper layer that makes function calls on the dynamically loaded shared object...
Stores the connection data for a database.
ScheduleModuleId
This defines the module id of a schedule event.
ScheduleActionType
This defines the action type of a schedule event.
const int DCA_UPDATE_DOWNLOAD_SCHEDULED
Internal DCA status code to indicate that a potentially time consuming download has been scheduled....
time_t dbUpdateStartLocalTime
The start time for the database merge process. If left at 0, the current time plus a small random off...
const int ERR_CONNECTION_TIMEOUT
This error may occur whenever a DCA function or class attempts to connect to a remote resource....
int getMaxUsers() const
Returns the maximum allowed users associated with your ticket/license.
@ SAT_ProgressDbDownload
Complete database download progress information.
Class to store the Database connection data for a custom database.
FunctionResult setDefaultProxySettings(const ProxySettings &newProxySettings)
Sets default proxy settings for all locations where proxy settings are used.
@ SAT_StopDbMerge
A database merge process has successfully finished.
Database connection class for a local or remote database.
const int ERR_DB_DOWNLOAD_ABORTED
Error code: A download of a database update was aborted unexpectly.
unsigned int dbUpdateIntervalMinutes
This is the interval of the database merge process, specified in minutes. Minimum is one minute,...
bool contentUpdated() const
If true the update(s) include a content update.
const int ERR_NOT_LICENSED
This code is returned if the specified license data is invalid, or the license has expired.
@ LOG_Extensive
Use extensive logging, this may greatly increase the size of the log file.
@ LOG_Error
Errors will be logged out.
@ SAT_StartDbDownload
A complete database download has started.
unsigned int cacheMaxEntries
This is the maximum number of entries the cache can be filled up with (by using the maintenance inter...
DCA_RESULT_TYPE getReturnCode() const
Gets the code of the error.
std::string newVersion() const
Returns the version currently active (installed).
bool available() const
true if an update was available for this component, false otherwise
const int ERR_SIG_ABORT_DETECTED
This code is returned when you use the dca::DcaInstance::signal() call and a task is terminated as a ...
@ SAT_ErrorDbMerge
An error occured during the database merge process.
time_t dbUpdateStartLocalTime
Class that contains all version information of all initialized DCA modules.
const int ERR_URL_INVALID
Error code: The URL is invalid.
unsigned int updateFileWriteMaxEntries
The maximum number of entries. If exceeded, the database will be saved to an update file....
Encapsulates one of the results of an update process.
@ SAT_UserCancel
The user has cancelled the operation.
LogLevel
This enum is used in all setLogLevel() functions to change the verbosity level of the classes.
Stores the remote server data for the connection to a remote database.
Use a License to initialize a classification package or a toolbox package.
unsigned int dbUpdateIntervalMinutes
const DbType DBT_Custom
Used for DbConnection classes of custom databases.
const int ERR_INVALID_FOLDER
Error code: One (or more) of the specified folders were invalid (types or inaccessable)
FunctionResult performUpdate(bool force, UpdateResults &results) const
Performs an update for all licensed and initialized DCA modules and classifiers.
If you are using one or more proxy servers set up this structure and use it for e....
bool isLicensed(DCA_MODULE_ID_TYPE id=0, bool force=false) const
Checks whether the given License is valid for the given module id.
std::string ticket
The ticket as provided in the license.
bool useLocalDatabase
Set to true to connect to a local or custom database, set to false to use a remote database.
Encapsulates the init and deinit of the DCA API.
unsigned int proxyPort
the proxy server port to be used
std::string product
The product code used with the license.
static DCA_MODULE_ID_TYPE ID
This is the module id of the update module.
@ LOG_Info
Write less important information to the log file.
const DbType DBT_Url
Used for DbConnection classes for URL classification.
const int ERR_INVALID_XML_FILES
Error code: The specified XML files are missing or corrupt.
std::string logDir
the directory in which the DCA log file should be created
const int ERR_URL_UNSUPPORTED_PROTOCOL
Error code: The protocol of the URL is unsupported.
std::string getLastMessage() const
Returns the last message received from our license server or if none available the last available mes...
size_t DCA_INDEX_TYPE
Type for index access (used for arrays and collections).
const int DCA_SUCCESS
A return code to indicate a successful function call.
@ SAT_ErrorDbDownload
An error occured during a complete db download.
std::string user
proxy username
DbType dbType
The type of the database.
DCA_SIZE_TYPE size() const
Returns the number of available details (if any).
std::string getDescription() const
Returns the description for the error or warning.
size_t DCA_SIZE_TYPE
Type for size (used for size of array and collections).
const int ERR_UNEXPECTED
This error is returned if an unexpcted error occurs. This should never happen, but if it does occur,...
const int ERR_INVALID_DATABASE
Error code: An attempt to connect to a local or custom database was not successful.
Stores the connection data for a local database.
unsigned int updateFileWriteIntervalMinutes
This is the interval (specified in minutes) in which the modifications made to the database are saved...
bool engineUpdated() const
If true the update(s) include an engine update.
@ SMI_CustomDb
ID for a custom database database.
DbConnectionRemoteServerData remoteServerData
If you are creating a remote database connection, this structure must be filled out with the encrypti...
void setReturnCode(DCA_RESULT_TYPE value)
Sets the return code.
std::string getTicket() const
Returns the ticket of the license as string.
const int ERR_NOT_INITIALIZED
If you e.g. forget to initialize an instance before using a member function this error will be return...
#define PRIVATE_PTR
Type for private pointer implementations, for internal use only.
Standard function result.
std::string getSession() const
Returns the session of the license as string.
virtual void onEvent(ScheduleActionType actionType, ScheduleModuleId moduleId, const std::string &version, const std::string &text)=0
Called by the schedule framework when a schedule event occurs.
std::string name() const
Returns the name of the DCA module that is related to current updates.
An interface for schedule event notifications. Derive a class from this interface and implement onEve...
char * DCA_CATEGORIES_INFO_TYPE
Type for CategoryInfo objects.
int DCA_RESULT_TYPE
Type for return codes.
const int ERR_CREATION
An error occured when attempting too create a class or instance in the DCA API.
DbConnection createDbConnection(const License &aLicense, const DbConnectionData &dbcData, const ProxySettings &proxySettings=ProxySettings(), LogLevel aLogLevel=LOG_Initial) const
Creates a DbConnection object using the given DbConnectionData.
This structure is used to initialize the DcaInstance.
std::string proxyServer
the proxy server (IP address or the fully qualified domain name)
std::string getDatabaseVersion() const
Returns the currently used database version.
static DcaInstance create(const InitData &initData)
Creates a DcaInstance, starts up the DCA API and initializes the required main module.
@ SAT_StartDbMerge
A database merge process has started.
DCA_SIZE_TYPE size() const
Returns the number of results available .
std::string encryptionData
The encryption data to be used (provided with your license)
License createLicense(const LicenseData &licData, const ProxySettings &proxySettings=ProxySettings(), LogLevel aLogLevel=LOG_Initial) const
Creates a License object using the given LicenseData.
DCA_MODULE_ID_TYPE id() const
Returns the module ID for which the updates have been installed.
std::string component() const
Returns the name of the component the detail applies to.