Initial
This commit is contained in:
45
ftp/FTPTHRD.HPP
Normal file
45
ftp/FTPTHRD.HPP
Normal file
@@ -0,0 +1,45 @@
|
||||
#ifndef _FTP_FTPTHREAD_HPP_
|
||||
#define _FTP_FTPTHREAD_HPP_
|
||||
#ifndef _FTP_INTERPRETER_HPP_
|
||||
#include <ftp/interprt.hpp>
|
||||
#endif
|
||||
#ifndef _THREAD_MESSAGETHREAD_HPP_
|
||||
#include <thread/mthread.hpp>
|
||||
#endif
|
||||
|
||||
class EditMonitor;
|
||||
|
||||
class FTPThread : private FTPInterpreter, public MessageThread
|
||||
{
|
||||
public:
|
||||
enum HandlerType{MsgInterpretLine,MsgInterpretFile};
|
||||
enum CompletionCode{LineComplete,FileComplete};
|
||||
FTPThread(void);
|
||||
virtual ~FTPThread();
|
||||
WORD interpretLine(const String &lineString);
|
||||
WORD interpretFile(const String &pathFileName);
|
||||
void setDisplay(Monitor<EditWindow> &displayWindow);
|
||||
void setCompletionHandler(PureCallback *lpCallback);
|
||||
private:
|
||||
FTPThread(const FTPThread &someFTPThread);
|
||||
FTPThread &operator=(const FTPThread &someFTPThread);
|
||||
DWORD threadHandler(ThreadMessage &someThreadMessage);
|
||||
void handleInterpretLine(String *pString);
|
||||
void handleInterpretFile(String *pString);
|
||||
|
||||
ThreadCallback<FTPThread> mThreadHandler;
|
||||
CallbackPointer mCompletionHandler;
|
||||
};
|
||||
|
||||
inline
|
||||
FTPThread &FTPThread::operator=(const FTPThread &/*someFTPThread*/)
|
||||
{ // private implementation
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline
|
||||
void FTPThread::setCompletionHandler(PureCallback *lpCallback)
|
||||
{
|
||||
mCompletionHandler=CallbackPointer(lpCallback);
|
||||
}
|
||||
#endif
|
||||
Reference in New Issue
Block a user