2011-01-22 01:18:58 +03:00
|
|
|
/*
|
2011-01-24 23:48:03 +03:00
|
|
|
* Copyright 2011, Oliver Tappe <zooey@hirschkaefer.de>
|
2011-01-22 01:18:58 +03:00
|
|
|
* Distributed under the terms of the MIT License.
|
|
|
|
*/
|
2011-01-24 23:48:03 +03:00
|
|
|
#ifndef _HAIKU__PACKAGE__PRIVATE__FETCH_FILE_JOB_H_
|
|
|
|
#define _HAIKU__PACKAGE__PRIVATE__FETCH_FILE_JOB_H_
|
2011-01-22 01:18:58 +03:00
|
|
|
|
|
|
|
|
|
|
|
#include <Entry.h>
|
|
|
|
#include <String.h>
|
|
|
|
|
|
|
|
#include <package/Job.h>
|
|
|
|
|
|
|
|
|
|
|
|
namespace Haiku {
|
|
|
|
|
|
|
|
namespace Package {
|
|
|
|
|
2011-01-24 23:48:03 +03:00
|
|
|
namespace Private {
|
|
|
|
|
2011-01-22 01:18:58 +03:00
|
|
|
|
|
|
|
class FetchFileJob : public Job {
|
|
|
|
typedef Job inherited;
|
|
|
|
|
|
|
|
public:
|
2011-01-22 22:30:21 +03:00
|
|
|
FetchFileJob(const Context& context,
|
|
|
|
const BString& title,
|
2011-01-22 01:18:58 +03:00
|
|
|
const BString& fileURL,
|
|
|
|
const BEntry& targetEntry);
|
|
|
|
virtual ~FetchFileJob();
|
|
|
|
|
|
|
|
protected:
|
|
|
|
virtual status_t Execute();
|
|
|
|
virtual void Cleanup(status_t jobResult);
|
|
|
|
|
|
|
|
private:
|
|
|
|
BString fFileURL;
|
|
|
|
BEntry fTargetEntry;
|
|
|
|
};
|
|
|
|
|
|
|
|
|
2011-01-24 23:48:03 +03:00
|
|
|
} // namespace Private
|
|
|
|
|
2011-01-22 01:18:58 +03:00
|
|
|
} // namespace Package
|
|
|
|
|
|
|
|
} // namespace Haiku
|
|
|
|
|
|
|
|
|
2011-01-24 23:48:03 +03:00
|
|
|
#endif // _HAIKU__PACKAGE__PRIVATE__FETCH_FILE_JOB_H_
|