10 #ifndef WRENCH_FILE_WRITE_ACTION_H
11 #define WRENCH_FILE_WRITE_ACTION_H
15 #include "wrench/action/Action.h"
28 std::shared_ptr<DataFile>
getFile()
const;
35 FileWriteAction(
const std::string& name, std::shared_ptr<CompoundJob> job,
36 std::shared_ptr<DataFile>file, std::shared_ptr<FileLocation> file_location);
39 void execute(std::shared_ptr<ActionExecutor> action_executor)
override;
40 void terminate(std::shared_ptr<ActionExecutor> action_executor)
override;
43 std::shared_ptr<DataFile>file;
44 std::shared_ptr<FileLocation> file_location;
49 #endif //WRENCH_FILE_WRITE_ACTION_H
void execute(std::shared_ptr< ActionExecutor > action_executor) override
Method to execute the action.
Definition: FileWriteAction.cpp:60
void terminate(std::shared_ptr< ActionExecutor > action_executor) override
Method called when the action terminates.
Definition: FileWriteAction.cpp:71
FileWriteAction(const std::string &name, std::shared_ptr< CompoundJob > job, std::shared_ptr< DataFile >file, std::shared_ptr< FileLocation > file_location)
Constructor.
Definition: FileWriteAction.cpp:32
std::shared_ptr< DataFile > getFile() const
Returns the action's file.
Definition: FileWriteAction.cpp:43
Definition: Action.cpp:28
std::shared_ptr< FileLocation > getFileLocation() const
Returns the action's file location.
Definition: FileWriteAction.cpp:51
bool usesScratch() const override
Determine whether the action uses scratch.
Definition: FileWriteAction.cpp:79
An abstract class that implements the concept of an action.
Definition: Action.h:28
A class that implements a file write action.
Definition: FileWriteAction.h:25
A compound job.
Definition: CompoundJob.h:47