Implement undo of RemovePerUserStorageDirectories
[platform/core/appfw/app-installers.git] / src / common / step / filesystem / step_remove_per_user_storage_directories.h
1 // Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
2 // Use of this source code is governed by an apache 2.0 license that can be
3 // found in the LICENSE file.
4
5 #ifndef COMMON_STEP_FILESYSTEM_STEP_REMOVE_PER_USER_STORAGE_DIRECTORIES_H_
6 #define COMMON_STEP_FILESYSTEM_STEP_REMOVE_PER_USER_STORAGE_DIRECTORIES_H_
7
8 #include <manifest_parser/utils/logging.h>
9
10 #include "common/step/step.h"
11
12 namespace common_installer {
13 namespace filesystem {
14
15 /**
16  * \brief Uninstallation.
17  *        Responsible for removing shared directories (wgt/tpk) for users.
18  *
19  * * process method implements removal of data and shared directories for
20  *   package in case of global installation for each user. Normally, directories
21  *   are removed in StepRemoveFiles.
22  *
23  * * Other methods are empty.
24  *
25  */
26
27 class StepRemovePerUserStorageDirectories : public common_installer::Step {
28  public:
29   using Step::Step;
30
31   Status process() override;
32   Status clean() override { return Status::OK; }
33   Status undo() override;
34   Status precheck() override { return Status::OK; }
35
36   STEP_NAME(RemovePerUserStorageDirectories)
37 };
38
39 }  // namespace filesystem
40 }  // namespace common_installer
41
42 #endif  // COMMON_STEP_FILESYSTEM_STEP_REMOVE_PER_USER_STORAGE_DIRECTORIES_H_