karazeh
A cross-platform software updating library.
create.hpp
Go to the documentation of this file.
1 
21 #ifndef H_KARAZEH_OPERATION_CREATE_H
22 #define H_KARAZEH_OPERATION_CREATE_H
23 
24 #include "karazeh_export.h"
25 #include "karazeh/operation.hpp"
26 #include "karazeh/logger.hpp"
27 
28 namespace kzh {
29 
30  class KARAZEH_EXPORT create_operation : public operation, protected logger {
31  public:
33  virtual ~create_operation();
34 
51  virtual STAGE_RC stage();
52  virtual STAGE_RC deploy();
53  virtual void rollback();
54  virtual void commit();
55 
56  virtual string_t tostring();
57 
63 
64  void marked_for_deletion();
65  protected:
66  bool has_deployed() const;
67  path_t get_destination() const;
68 
69  private:
70  path_t dst_dir_;
71  path_t cache_dir_;
72  path_t cache_path_;
73 
74  bool created_directory_;
75  bool marked_for_deletion_;
76  };
77 
78 } // end of namespace kzh
79 
80 #endif
boost::filesystem::path path_t
Definition: karazeh.hpp:57
STAGE_RC
Definition: operation.hpp:33
Definition: operation.hpp:50
std::string string_t
Definition: karazeh.hpp:55
Definition: config.hpp:32
uint64_t src_size
Definition: create.hpp:59
string_t src_checksum
Definition: create.hpp:58
Definition: release_manifest.hpp:32
string_t dst_path
Definition: create.hpp:61
string_t src_uri
Definition: create.hpp:60
bool is_executable
Definition: create.hpp:62
unsigned long uint64_t
Definition: karazeh.hpp:56
Definition: logger.hpp:35
Definition: create.hpp:30
Definition: config.hpp:27