2013-05-23 23:29:18 +04:00
|
|
|
/*
|
|
|
|
* Copyright 2013, Haiku, Inc.
|
|
|
|
* Distributed under the terms of the MIT License.
|
|
|
|
*/
|
|
|
|
#ifndef _PACKAGE__USER_SETTINGS_FILE_INFO_H_
|
|
|
|
#define _PACKAGE__USER_SETTINGS_FILE_INFO_H_
|
|
|
|
|
|
|
|
|
|
|
|
#include <String.h>
|
|
|
|
|
|
|
|
|
|
|
|
namespace BPackageKit {
|
|
|
|
|
|
|
|
|
2013-05-28 04:44:13 +04:00
|
|
|
namespace BHPKG {
|
|
|
|
struct BUserSettingsFileInfoData;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
2013-05-23 23:29:18 +04:00
|
|
|
class BUserSettingsFileInfo {
|
|
|
|
public:
|
|
|
|
BUserSettingsFileInfo();
|
2013-05-28 04:44:13 +04:00
|
|
|
BUserSettingsFileInfo(
|
|
|
|
const BHPKG::BUserSettingsFileInfoData&
|
|
|
|
infoData);
|
2013-05-23 23:29:18 +04:00
|
|
|
BUserSettingsFileInfo(const BString& path,
|
|
|
|
const BString& templatePath = BString());
|
2013-06-06 02:16:28 +04:00
|
|
|
BUserSettingsFileInfo(const BString& path,
|
|
|
|
bool isDirectory);
|
2013-05-23 23:29:18 +04:00
|
|
|
~BUserSettingsFileInfo();
|
|
|
|
|
|
|
|
status_t InitCheck() const;
|
|
|
|
|
|
|
|
const BString& Path() const;
|
|
|
|
const BString& TemplatePath() const;
|
2013-06-06 02:16:28 +04:00
|
|
|
bool IsDirectory() const;
|
2013-05-23 23:29:18 +04:00
|
|
|
|
|
|
|
void SetTo(const BString& path,
|
|
|
|
const BString& templatePath = BString());
|
2013-06-06 02:16:28 +04:00
|
|
|
void SetTo(const BString& path,
|
|
|
|
bool isDirectory);
|
2013-05-23 23:29:18 +04:00
|
|
|
|
|
|
|
private:
|
|
|
|
BString fPath;
|
|
|
|
BString fTemplatePath;
|
2013-06-06 02:16:28 +04:00
|
|
|
bool fIsDirectory;
|
2013-05-23 23:29:18 +04:00
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
} // namespace BPackageKit
|
|
|
|
|
|
|
|
|
|
|
|
#endif // _PACKAGE__USER_SETTINGS_FILE_INFO_H_
|