// Command // // Douglas Thrift // // $Id$ #ifndef _Command_hpp_ #define _Command_hpp_ #include #ifdef MENES_PRAGMA_ONCE #pragma once #endif #include #include #include #include "Subversion/Client.hpp" #include "Url.hpp" struct Command : public ext::ReferenceCounted { const api::Path root; const cse::String path; protected: #ifdef __FreeBSD__ Command(const cse::String &root) : root(api::Path(root).GetRealPath()), path(root) {} #else Command(const cse::String &root) : root((root.IsEmpty() ? api::Path(_B(".")) : api::Path(root)).GetRealPath()), path(root) {} #endif }; class CommandRunner { protected: const cse::String &sitemap; ext::Queue &queue; api::ThreadMutex &queueLock; Subversion::Client client; CommandRunner(const cse::String &sitemap, ext::Queue &queue, api::ThreadMutex &queueLock) : sitemap(sitemap), queue(queue), queueLock(queueLock) {} template Type GetProperties(const cse::String &property, const cse::String &target); cse::String GetPassword(const api::Path &directory); }; #endif//_Command_hpp_