aqnwb 0.1.0
Loading...
Searching...
No Matches
Utils.hpp File Reference
#include <algorithm>
#include <chrono>
#include <cmath>
#include <cstdint>
#include <ctime>
#include <iomanip>
#include <regex>
#include <sstream>
#include <string>
#include <boost/date_time.hpp>
#include <boost/endian/conversion.hpp>
#include <boost/uuid/uuid.hpp>
#include <boost/uuid/uuid_generators.hpp>
#include <boost/uuid/uuid_io.hpp>
#include "boost/date_time/c_local_time_adjustor.hpp"
#include "io/BaseIO.hpp"
#include "io/hdf5/HDF5IO.hpp"
Include dependency graph for Utils.hpp:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Namespaces

namespace  AQNWB
 The main namespace for AqNWB.
 

Functions

static std::string AQNWB::generateUuid ()
 Generates a UUID (Universally Unique Identifier) as a string.
 
static std::string AQNWB::getCurrentTime ()
 Get the current time in ISO 8601 format with the UTC offset.
 
static bool AQNWB::isISO8601Date (const std::string &dateStr)
 Check that a string is formatted in ISO8601 format.
 
static std::shared_ptr< IO::BaseIOAQNWB::createIO (const std::string &type, const std::string &filename)
 Factory method to create an IO object.
 
static std::string AQNWB::mergePaths (const std::string &path1, const std::string &path2)
 Merge two paths into a single path, handling extra trailing and starting "/".
 
static void AQNWB::convertFloatToInt16LE (const float *source, void *dest, SizeType numSamples)
 Method to convert float values to uint16 values. This method was adapted from JUCE AudioDataConverters using a default value of destBytesPerSample = 2.
 
static std::unique_ptr< int16_t[]> AQNWB::transformToInt16 (SizeType numSamples, float conversion_factor, const float *data)
 Method to scale float values and convert to int16 values.