GDAL

cpl_vsil_curl_priv.h
1/******************************************************************************
2 * $Id$
3 *
4 * Project: CPL - Common Portability Library
5 * Purpose: Private API for VSICurl
6 * Author: Even Rouault, even.rouault at spatialys.com
7 *
8 ******************************************************************************
9 * Copyright (c) 2012, Even Rouault <even dot rouault at spatialys.com>
10 *
11 * SPDX-License-Identifier: MIT
12 ****************************************************************************/
13
14#ifndef CPL_VSIL_CURL_PRIV_H_INCLUDED
15#define CPL_VSIL_CURL_PRIV_H_INCLUDED
16
17#include "cpl_vsi_virtual.h"
18
19/* NOTE: this is private API for GDAL internal use. */
20/* May change without notice. */
21/* Used by the MBTiles driver for now. */
22
23/* Return TRUE to go on downloading, FALSE to stop. */
24 typedef int (*VSICurlReadCbkFunc)(VSILFILE *fp, void *pabyBuffer,
25 size_t nBufferSize, void *pfnUserData);
26
27/* fp must be a VSICurl file handle, otherwise bad things will happen. */
28/* bStopOnInterruptUntilUninstall must be set to TRUE if all downloads */
29/* must be canceled after a first one has been stopped by the callback */
30/* function. In that case, downloads will restart after uninstalling the */
31/* callback. */
32 int VSICurlInstallReadCbk(VSILFILE *fp, VSICurlReadCbkFunc pfnReadCbk,
33 void *pfnUserData,
34 int bStopOnInterruptUntilUninstall);
35 int VSICurlUninstallReadCbk(VSILFILE *fp);
36
37 void VSICurlAuthParametersChanged();
38
39#endif // CPL_VSIL_CURL_PRIV_H_INCLUDED
VSIVirtualHandle
Virtual file handle.
Definition: cpl_vsi_virtual.h:47