Remove boost dependency
[platform/core/appfw/app-installers.git] / src / common / step / filesystem / step_unzip.h
1 /* 2014, Copyright © Intel Coporation, license APACHE-2.0, see LICENSE file */
2 // Copyright (c) 2015 Samsung Electronics Co., Ltd All Rights Reserved
3 // Use of this source code is governed by a apache 2.0 license that can be
4 // found in the LICENSE file.
5
6 #ifndef COMMON_STEP_FILESYSTEM_STEP_UNZIP_H_
7 #define COMMON_STEP_FILESYSTEM_STEP_UNZIP_H_
8
9 #include <manifest_parser/utils/logging.h>
10
11 #include "common/installer_context.h"
12 #include "common/step/step.h"
13
14 namespace common_installer {
15 namespace filesystem {
16
17 /**
18  * \brief Installation and Update.
19  *        Responsible for unpacking the archive (wgt/tpk)
20  *
21  * process method implements unpacking the archive. It also checks the
22  * rough space requirements vs availability.
23  * Since process method unpacks the package to given directory, undo method
24  * removes them.
25  *
26  * Unzip unpacks resources to following directory:
27  * * TZ_SYS_RW/tmpuniquedir (/usr/apps/tmpuniquedir)
28  * * TZ_SER_APPS/tmpdir  (/{HOME}/apps_rw/tmpuniquedir)
29  * InstallerContext::unpacked_dir_path points to this location.
30  */
31 class StepUnzip : public Step {
32  public:
33   using Step::Step;
34   Status process() override;
35   Status clean() override { return Status::OK; }
36   Status undo() override;
37   Status precheck() override;
38
39   STEP_NAME(Unzip)
40 };
41
42 }  // namespace filesystem
43 }  // namespace common_installer
44
45
46 #endif  // COMMON_STEP_FILESYSTEM_STEP_UNZIP_H_