TrendFbDatabaseAccessErrorHandler.IsDatabaseAccessEnabled (METH) ¶ METHOD IsDatabaseAccessEnabled : BOOL This method should be evaluated by all the function block instances, that perform an access to the underlying SQLite database. In case of a permanent error (e.g. disk full) this method returns FALSE and a database access should be not performed. InOut: Scope Name Type Return IsDatabaseAccessEnabled BOOL
TrendFbDatabaseAccessErrorHandler.SQLiteErrorHandling (METH) ¶ METHOD SQLiteErrorHandling This method is used to do the error processing of errors coming from the database layer. InOut: Scope Name Type Comment Input iFunction INT An int describing the method or function, where the error occurred eError STO.ERROR The error code coming from sqlite iAction INT An int describing the action, that failed.
private ¶ prvGetActionName (Method) prvGetErrorDescription (Method) prvGetFunctionName (Method)
TrendFbTrendStorageWriterReader (FB) ¶ FUNCTION_BLOCK TrendFbTrendStorageWriterReader IMPLEMENTS ITrendStorageWriterBufferClient This functionblock can be used to read data directly from a ITrendStorageWriter Methods: GetAndResetIsCleared GetMinMaxTimestampsFromBuffer Initialize Read ReleaseDB ShrinkMemory BuildBuffer CleanBuffer InitializeBufferReader Structure: GetAndResetIsCleared (Method) GetMinMaxTimestampsFromBuffer (Method) ITrendStorageWriterBufferClient BuildBuffer (Method) CleanBuffer (Method) InitializeBufferReader (Method) Initialize (Method) Read (Method) ReleaseDB (Method) ShrinkMemory (Method)
TrendFbTrendStorageWriterReader.GetAndResetIsCleared (METH) ¶ METHOD GetAndResetIsCleared : BOOL InOut: Scope Name Type Return GetAndResetIsCleared BOOL
TrendFbTrendStorageWriterReader.GetMinMaxTimestampsFromBuffer (METH) ¶ METHOD GetMinMaxTimestampsFromBuffer : UDINT This method returns the min/max timestamps of the data in the local buffer InOut: Scope Name Type Comment Return GetMinMaxTimestampsFromBuffer UDINT An error code indicating, whether the processing was successful or not Output liMinTimestamp LINT Returns minimum timestamp liMaxTimestamp LINT Returns maximum timestamp
ITrendStorageWriterBufferClient ¶ BuildBuffer (Method) CleanBuffer (Method) InitializeBufferReader (Method)
ITrendStorageSizeMonitor.GetDatabaseFileSize (METH) ¶ METHOD GetDatabaseFileSize : LINT This function returns the size in byte of the trend DB InOut: Scope Name Type Return GetDatabaseFileSize LINT
ITrendStorageSizeMonitor.LastReorderingTime (PROP) ¶ PROPERTY LastReorderingTime : TIME This property gets/sets the last DB reorganization time
ITrendStorageSizeMonitor.PercDBLimit (PROP) ¶ PROPERTY PercDBLimit : INT This property gets/sets the percentage used to check the DB size: the DB size is reduced by this percentage if the set limit is exceeded.