1 /* 2 * Copyright 2013, Haiku, Inc. 3 * Distributed under the terms of the MIT License. 4 */ 5 #ifndef _PACKAGE__GLOBAL_WRITABLE_FILE_INFO_H_ 6 #define _PACKAGE__GLOBAL_WRITABLE_FILE_INFO_H_ 7 8 9 #include <package/WritableFileUpdateType.h> 10 #include <String.h> 11 12 13 namespace BPackageKit { 14 15 16 namespace BHPKG { 17 struct BGlobalWritableFileInfoData; 18 } 19 20 21 class BGlobalWritableFileInfo { 22 public: 23 BGlobalWritableFileInfo(); 24 BGlobalWritableFileInfo( 25 const BHPKG::BGlobalWritableFileInfoData& 26 infoData); 27 BGlobalWritableFileInfo(const BString& path, 28 BWritableFileUpdateType updateType, 29 bool isDirectory); 30 ~BGlobalWritableFileInfo(); 31 32 status_t InitCheck() const; 33 34 const BString& Path() const; 35 bool IsIncluded() const; 36 BWritableFileUpdateType UpdateType() const; 37 bool IsDirectory() const; 38 39 void SetTo(const BString& path, 40 BWritableFileUpdateType updateType, 41 bool isDirectory); 42 43 private: 44 BString fPath; 45 BWritableFileUpdateType fUpdateType; 46 bool fIsDirectory; 47 }; 48 49 50 } // namespace BPackageKit 51 52 53 #endif // _PACKAGE__GLOBAL_WRITABLE_FILE_INFO_H_ 54