ATLAS Offline Software
Loading...
Searching...
No Matches
blobaccess.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
3*/
4
5#ifndef CORALUTILITIES_BLOBACCESS_H
6#define CORALUTILITIES_BLOBACCESS_H
7
8#include <string>
9#include <memory>
10#include <string_view>
11#include "nlohmann/json.hpp"
12
13class TTree;
14class TMemFile;
15
16namespace coral {
17 class Blob;
18}
19
20namespace CoralUtilities {
21
22 bool compressBlob (const char* , coral::Blob&);
23 bool writeBlobFromString (const std::string_view, coral::Blob&);
24 bool writeBlobFromJson (const nlohmann::json& , coral::Blob&);
25 bool writeBlobFromTTree ( TTree* , coral::Blob&);
26
27 bool uncompressBlob (const coral::Blob&, std::unique_ptr<unsigned char[]>&, unsigned long&);
28 bool readBlobAsString (const coral::Blob&, std::string& );
29 bool readBlobAsJson (const coral::Blob&, nlohmann::json& );
37 bool readBlobAsTTree(const coral::Blob& blob, std::unique_ptr<TTree>& tree,
38 const std::string_view name = "tree");
39
40}
41
42#endif
bool writeBlobFromJson(const nlohmann::json &, coral::Blob &)
bool readBlobAsString(const coral::Blob &, std::string &)
bool writeBlobFromTTree(TTree *, coral::Blob &)
bool uncompressBlob(const coral::Blob &, std::unique_ptr< unsigned char[]> &, unsigned long &)
bool compressBlob(const char *, coral::Blob &)
bool readBlobAsTTree(const coral::Blob &blob, std::unique_ptr< TTree > &tree, const std::string_view name="tree")
Interprets the coral::Blob as a TTree instance.
bool writeBlobFromString(const std::string_view, coral::Blob &)
bool readBlobAsJson(const coral::Blob &, nlohmann::json &)
TChain * tree