A base class for simulation timestamps regarding file reads. More...

#include <SimulationTimestampTypes.h>

Inheritance diagram for wrench::SimulationTimestampFileRead:
wrench::SimulationTimestampPair wrench::SimulationTimestampType wrench::SimulationTimestampFileReadCompletion wrench::SimulationTimestampFileReadFailure wrench::SimulationTimestampFileReadStart

Public Member Functions

SimulationTimestampFileReadgetEndpoint () override
 Retrieve the matching endpoint, if any. More...
 
WorkflowFilegetFile ()
 retrieves the WorkflowFile being read More...
 
StorageServicegetService ()
 retrieves the storage service for file read More...
 
FileLocationgetSource ()
 retrieves the location from which the WorkflowFile is being copied More...
 
WorkflowTaskgetTask ()
 retrieves task associated w/ file read More...
 
- Public Member Functions inherited from wrench::SimulationTimestampPair
 SimulationTimestampPair ()
 Constructor.
 
 SimulationTimestampPair (SimulationTimestampPair *endpoint)
 Constructor. More...
 
- Public Member Functions inherited from wrench::SimulationTimestampType
 SimulationTimestampType ()
 
More...
 
double getDate ()
 Retrieve the date recorded for this timestamp. More...
 

Protected Member Functions

 SimulationTimestampFileRead (WorkflowFile *file, FileLocation *src, StorageService *service, WorkflowTask *task=nullptr)
 Constructor. More...
 
void setEndpoints ()
 Sets the endpoint of the calling object (SimulationTimestampFileReadFailure, SimulationTimestampFileReadTerminated, SimulationTimestampFileReadStart) with a SimulationTimestampFileReadStart object.
 

Protected Attributes

WorkflowFilefile
 The WorkflowFile that was being read.
 
StorageServiceservice
 Service that initiated the read.
 
FileLocationsource
 The location where the WorkflowFile was being read from.
 
WorkflowTasktask
 Task tied to read.
 
- Protected Attributes inherited from wrench::SimulationTimestampPair
SimulationTimestampPairendpoint = nullptr
 An optional associated "endpoint" simulation timestamp.
 

Static Protected Attributes

static std::unordered_multimap< File, std::pair< SimulationTimestampFileRead *, WorkflowTask * > > pending_file_reads
 the data structure that holds the ongoing file reads. More...
 

Detailed Description

A base class for simulation timestamps regarding file reads.

Constructor & Destructor Documentation

◆ SimulationTimestampFileRead()

wrench::SimulationTimestampFileRead::SimulationTimestampFileRead ( WorkflowFile file,
FileLocation src_location,
StorageService service,
WorkflowTask task = nullptr 
)
protected

Constructor.

Parameters
filethe WorkflowFile associated with this file read
src_locationthe source location
serviceservice requesting file read
taska task associated to this file read (or nullptr)

Member Function Documentation

◆ getEndpoint()

SimulationTimestampFileRead * wrench::SimulationTimestampFileRead::getEndpoint ( )
overridevirtual

Retrieve the matching endpoint, if any.

retrieves the corresponding SimulationTimestampFileRead object

Returns
a pointer to the start or end SimulationTimestampFileRead object

Reimplemented from wrench::SimulationTimestampPair.

◆ getFile()

WorkflowFile * wrench::SimulationTimestampFileRead::getFile ( )

retrieves the WorkflowFile being read

Returns
a pointer to the WorkflowFile associated with this reads

◆ getService()

StorageService * wrench::SimulationTimestampFileRead::getService ( )

retrieves the storage service for file read

Returns
point to the service associated with this read

◆ getSource()

FileLocation * wrench::SimulationTimestampFileRead::getSource ( )

retrieves the location from which the WorkflowFile is being copied

Returns
the read's source location

◆ getTask()

WorkflowTask * wrench::SimulationTimestampFileRead::getTask ( )

retrieves task associated w/ file read

Returns
a pointer to the WorkflowTask associated with this timestamp

Member Data Documentation

◆ pending_file_reads

std::unordered_multimap< File, std::pair< SimulationTimestampFileRead *, WorkflowTask * > > wrench::SimulationTimestampFileRead::pending_file_reads
staticprotected

the data structure that holds the ongoing file reads.

A static unordered multimap of SimulationTimestampFileReadStart objects that have yet to be matched with Failure, Terminated or Completion timestamps.

static std::unordered_multimap<File, std::pair<SimulationTimestampFileRead *, double>, decltype(&file_hash)> pending_file_reads;


The documentation for this class was generated from the following files: