Fast Methods for Cosmological Simulations
FastSim serves as a tool for quick N-body simulations in modified gravity.
std::hash< nlohmann::json > Struct Template Reference

hash value for JSON objects More...

#include <json.hpp>

Public Member Functions

std::size_t operator() (const nlohmann::json &j) const
 return a hash value for a JSON object More...
 

Detailed Description

template<>
struct std::hash< nlohmann::json >

hash value for JSON objects

Definition at line 20165 of file json.hpp.

Member Function Documentation

std::size_t std::hash< nlohmann::json >::operator() ( const nlohmann::json j) const
inline

return a hash value for a JSON object

Since
version 1.0.0

Definition at line 20172 of file json.hpp.

References nlohmann::basic_json< ObjectType, ArrayType, StringType, BooleanType, NumberIntegerType, NumberUnsignedType, NumberFloatType, AllocatorType, JSONSerializer >::dump(), and ccl_test_distances::h.

20173  {
20174  // a naive hashing via the string representation
20175  const auto& h = hash<nlohmann::json::string_t>();
20176  return h(j.dump());
20177  }
string_t dump(const int indent=-1, const char indent_char= ' ', const bool ensure_ascii=false, const error_handler_t error_handler=error_handler_t::strict) const
serialization
Definition: json.hpp:14221

The documentation for this struct was generated from the following file: