LCOV - code coverage report
Current view: top level - frmts/icechunk - icechunkutils.h (source / functions) Hit Total Coverage
Test: gdal_filtered.info Lines: 2 2 100.0 %
Date: 2026-07-24 18:27:47 Functions: 4 4 100.0 %

          Line data    Source code
       1             : /******************************************************************************
       2             :  *
       3             :  * Project:  GDAL
       4             :  * Purpose:  Icechunk driver
       5             :  * Author:   Even Rouault <even dot rouault at spatialys.com>
       6             :  *
       7             :  ******************************************************************************
       8             :  * Copyright (c) 2026, Even Rouault <even dot rouault at spatialys.com>
       9             :  *
      10             :  * SPDX-License-Identifier: MIT
      11             :  ****************************************************************************/
      12             : 
      13             : #ifndef ICECHUNKUTILS_H
      14             : #define ICECHUNKUTILS_H
      15             : 
      16             : #include "cpl_vsi_virtual.h"
      17             : 
      18             : #include <memory>
      19             : #include <string>
      20             : #include <utility>
      21             : #include <vector>
      22             : 
      23             : namespace gdal::icechunk
      24             : {
      25             : #ifdef DEBUG
      26             : constexpr bool IS_DEBUG_BUILD = true;
      27             : #else
      28             : constexpr bool IS_DEBUG_BUILD = false;
      29             : #endif
      30             : 
      31             : void VSIInstallIcechunkFileSystem();
      32             : void VSIIcechunkFileSystemClearCaches();
      33             : 
      34             : std::string GetFilenameFromDatasetName(const std::string &osDatasetName,
      35             :                                        std::string &osBranchName,
      36             :                                        std::string &osTagName,
      37             :                                        bool &ignoreTimestampEtag);
      38             : 
      39             : std::pair<std::unique_ptr<unsigned char, VSIFreeReleaser>, size_t>
      40             : DecompressFile(const char *pszFilename, VSIVirtualHandle *poFile,
      41             :                int nExpectedFileType, int *pnVersion = nullptr);
      42             : 
      43             : std::string CrockfordBase32Encode(const uint8_t *data, size_t size);
      44             : 
      45     1224484 : template <class T> static std::string CrockfordBase32Encode(const T &buffer)
      46             : {
      47     1224484 :     return CrockfordBase32Encode(buffer.data(), buffer.size());
      48             : }
      49             : }  // namespace gdal::icechunk
      50             : 
      51             : #endif

Generated by: LCOV version 1.14