The saga::replica class implements the saga::attributes interface. More...
#include <cpr_checkpoint.hpp>
Public Member Functions | |
checkpoint (session const &s, saga::url url, int mode=Read) | |
Creates the object. | |
checkpoint (saga::url url, int mode=Read) | |
Creates the object. | |
checkpoint (saga::object const &o) | |
Creates the object. | |
checkpoint (void) | |
Creates the object. | |
~checkpoint (void) | |
Destroys the object. | |
checkpoint & | operator= (saga::object const &o) |
Brief description starts here. | |
void | set_parent (saga::url url, int generation=1) |
set the previous checkpoint url | |
saga::url | get_parent (int generation=1) |
get the previous checkpoint url | |
std::vector< saga::url > | list_files (void) |
list the available checkpoint files | |
int | add_file (saga::url url) |
register a checkpoint file | |
saga::url | get_file (int id) |
get the url for a specific checkpoint file | |
saga::filesystem::file | open_file (int id, int flags=CreateParents|Lock|ReadWrite) |
open a specific checkpoint file by id | |
saga::filesystem::file | open_file (saga::url url, int flags=CreateParents|Lock|ReadWrite) |
open a specific checkpoint file by name | |
void | remove_file (int id) |
remove a specific checkpoint file by id | |
void | remove_file (saga::url url) |
remove a specific checkpoint file by name | |
void | update_file (int id, saga::url new_url) |
update a specific checkpoint file by id | |
void | update_file (saga::url old_url, saga::url new_url) |
update a specific checkpoint file by name | |
void | stage_file (int id, saga::url new_url) |
stage a specific checkpoint file by id | |
void | stage_file (saga::url old_url, saga::url new_url) |
stage a specific checkpoint file by name | |
void | stage_file (saga::url new_url) |
stage all checkpoint files | |
Static Public Member Functions | |
static checkpoint | create (session const &s, saga::url url, int mode=Read) |
Factory function resembling checkpoint(session, url, int) constructor. | |
static checkpoint | create (saga::url url, int mode=Read) |
Factory function resembling checkpoint(url, int) constructor. | |
template<typename Tag > | |
static saga::task | create (saga::url url, int mode=Read) |
Factory function resembling entry(url, int) constructor. |
The saga::replica class implements the saga::attributes interface.
A checkpoint represents merely an entry in a name space which has (a) an associated set of registered (physical) checkpoint files of that checkpoint, and (b) an associated set of meta data describing that checkpoint. Both sets can be empty. To access the content of a checkpoint, a saga::file needs to be created with one of the registered file locations.
Creates the object.
References saga::cpr::attributes::cpr_children, saga::cpr::attributes::cpr_mode, saga::cpr::attributes::cpr_nfliles, saga::cpr::attributes::cpr_parent, and saga::cpr::attributes::cpr_time.
saga::cpr::checkpoint::checkpoint | ( | saga::url | url, | |
int | mode = Read | |||
) | [explicit] |
Creates the object.
References saga::cpr::attributes::cpr_children, saga::cpr::attributes::cpr_mode, saga::cpr::attributes::cpr_nfliles, saga::cpr::attributes::cpr_parent, and saga::cpr::attributes::cpr_time.
saga::cpr::checkpoint::checkpoint | ( | saga::object const & | o | ) | [explicit] |
Creates the object.
References saga::BadParameter, saga::object::CPRCheckpoint, and saga::object::get_type().
saga::cpr::checkpoint::checkpoint | ( | void | ) |
Creates the object.
saga::cpr::checkpoint::~checkpoint | ( | void | ) |
Destroys the object.
static checkpoint saga::cpr::checkpoint::create | ( | session const & | s, | |
saga::url | url, | |||
int | mode = Read | |||
) | [inline, static] |
Factory function resembling checkpoint(session, url, int) constructor.
Reimplemented from saga::name_space::entry.
References saga::cpr::metrics::checkpoint.
static checkpoint saga::cpr::checkpoint::create | ( | saga::url | url, | |
int | mode = Read | |||
) | [inline, static] |
Factory function resembling checkpoint(url, int) constructor.
Reimplemented from saga::name_space::entry.
References saga::cpr::metrics::checkpoint.
static saga::task saga::cpr::checkpoint::create | ( | saga::url | url, | |
int | mode = Read | |||
) | [inline, static] |
Factory function resembling entry(url, int) constructor.
Reimplemented from saga::name_space::entry.
checkpoint & saga::cpr::checkpoint::operator= | ( | saga::object const & | o | ) |
Brief description starts here.
Reimplemented from saga::name_space::entry.
void saga::cpr::checkpoint::set_parent | ( | saga::url | url, | |
int | generation = 1 | |||
) | [inline] |
set the previous checkpoint url
generation | number of generations to go backwards |
References saga::task::get_result().
saga::url saga::cpr::checkpoint::get_parent | ( | int | generation = 1 |
) | [inline] |
get the previous checkpoint url
generation | number of generations to go backwards |
References saga::task::get_result().
std::vector<saga::url> saga::cpr::checkpoint::list_files | ( | void | ) | [inline] |
list the available checkpoint files
References saga::task::get_result().
int saga::cpr::checkpoint::add_file | ( | saga::url | url | ) | [inline] |
saga::url saga::cpr::checkpoint::get_file | ( | int | id | ) | [inline] |
saga::filesystem::file saga::cpr::checkpoint::open_file | ( | int | id, | |
int | flags = CreateParents | Lock | ReadWrite | |||
) | [inline] |
open a specific checkpoint file by id
file | id | |
open | flags |
References saga::task::get_result().
saga::filesystem::file saga::cpr::checkpoint::open_file | ( | saga::url | url, | |
int | flags = CreateParents | Lock | ReadWrite | |||
) | [inline] |
open a specific checkpoint file by name
file | url | |
open | flags |
References saga::task::get_result().
void saga::cpr::checkpoint::remove_file | ( | int | id | ) | [inline] |
remove a specific checkpoint file by id
checkpoint | url | |
file | id |
References saga::task::get_result().
void saga::cpr::checkpoint::remove_file | ( | saga::url | url | ) | [inline] |
void saga::cpr::checkpoint::update_file | ( | int | id, | |
saga::url | new_url | |||
) | [inline] |
update a specific checkpoint file by id
file | id | |
new | url |
References saga::task::get_result().
update a specific checkpoint file by name
old | url | |
new | url |
References saga::task::get_result().
void saga::cpr::checkpoint::stage_file | ( | int | id, | |
saga::url | new_url | |||
) | [inline] |
stage a specific checkpoint file by id
file | id | |
target | url |
References saga::task::get_result().
stage a specific checkpoint file by name
source | url | |
target | url |
References saga::task::get_result().
void saga::cpr::checkpoint::stage_file | ( | saga::url | new_url | ) | [inline] |