183
191
long sqlite3_quota_ftell(quota_FILE*);
194
** Truncate a file previously opened by sqlite3_quota_fopen(). Return
195
** zero on success and non-zero on any kind of failure.
197
** The newSize argument must be less than or equal to the current file size.
198
** Any attempt to "truncate" a file to a larger size results in
199
** undefined behavior.
201
int sqlite3_quota_ftrunate(quota_FILE*, sqlite3_int64 newSize);
204
** Return the last modification time of the opened file, in seconds
207
int sqlite3_quota_file_mtime(quota_FILE*, time_t *pTime);
210
** Return the size of the file as it is known to the quota system.
212
** This size might be different from the true size of the file on
213
** disk if some outside process has modified the file without using the
214
** quota mechanism, or if calls to sqlite3_quota_fwrite() have occurred
215
** which have increased the file size, but those writes have not yet been
216
** forced to disk using sqlite3_quota_fflush().
218
** Return -1 if the file is not participating in quota management.
220
sqlite3_int64 sqlite3_quota_file_size(quota_FILE*);
223
** Return the true size of the file.
225
** The true size should be the same as the size of the file as known
226
** to the quota system, however the sizes might be different if the
227
** file has been extended or truncated via some outside process or if
228
** pending writes have not yet been flushed to disk.
230
** Return -1 if the file does not exist or if the size of the file
231
** cannot be determined for some reason.
233
sqlite3_int64 sqlite3_quota_file_truesize(quota_FILE*);
186
236
** Delete a file from the disk, if that file is under quota management.
187
237
** Adjust quotas accordingly.