Data_deduplication_service
Service that will use hashes to deduplicate files
timing Namespace Reference

timing namespace More...

Classes

struct  cmpArr
 Comparator functor arrays. More...
 
class  clockArray
 Clock array template class. More...
 

Typedefs

using timepointType = std::chrono::system_clock::time_point
 
using locationType = std::array< std::string, 5 >
 
template<typename chrono_duration_type = std::milli>
using chronoClockTemplate = timing::clockArray< int64_t, timepointType, &std::chrono::high_resolution_clock::now, &getFileState, &doubleCastChrono< chrono_duration_type > >
 

Functions

locationType getFileState (std::source_location location=std::source_location::current())
 
template<typename to_dur = std::milli, typename doubleType >
doubleType doubleCastChrono (timepointType curr, timepointType prev)
 

Detailed Description

timing namespace

Typedef Documentation

◆ chronoClockTemplate

template<typename chrono_duration_type = std::milli>
using timing::chronoClockTemplate = typedef timing::clockArray<int64_t, timepointType, &std::chrono::high_resolution_clock::now, &getFileState, &doubleCastChrono<chrono_duration_type> >
Template Parameters
chrono_duration_type

◆ locationType

using timing::locationType = typedef std::array<std::string, 5>

◆ timepointType

using timing::timepointType = typedef std::chrono::system_clock::time_point

Function Documentation

◆ doubleCastChrono()

template<typename to_dur = std::milli, typename doubleType >
doubleType timing::doubleCastChrono ( timepointType  curr,
timepointType  prev 
)

Cast timepointType difference to double

Template Parameters
to_dur
doubleType
Parameters
curr
prev
Returns

◆ getFileState()

locationType timing::getFileState ( std::source_location  location = std::source_location::current())

Formats source location fields for more readability

Parameters
location