Vegastrike 0.5.1 rc1
1.0
Original sources for Vegastrike Evolved
|
#include <vsnet_notify.h>
Public Member Functions | |
Item (SOCKETALT sock, const std::string &filename, VSFileSystem::VSFileType=VSFileSystem::UnknownFile, NotifyPtr notify=NotifyPtr()) | |
virtual | ~Item () |
State | state () const |
VSError | error () const |
void | changeState (State s) |
void | changeState (State s, VSError e) |
void | setFileType (VSFileSystem::VSFileType ft) |
VSFileSystem::VSFileType | getFileType () |
void | setSize (int len) |
void | append (unsigned char *buffer, int bufsize) |
const std::string & | getFilename () const |
SOCKETALT | getSock () const |
int | get_fd () const |
Protected Member Functions | |
virtual void | childSetSize (int len)=0 |
virtual void | childAppend (unsigned char *buffer, int bufsize)=0 |
void | protected_replace_notifier (NotifyPtr ptr) |
Protected Attributes | |
VSFileSystem::VSFileType | _filetype |
Definition at line 172 of file vsnet_notify.h.
VsnetDownload::Client::Item::Item | ( | SOCKETALT | sock, |
const std::string & | filename, | ||
VSFileSystem::VSFileType | = VSFileSystem::UnknownFile , |
||
NotifyPtr | notify = NotifyPtr() |
||
) |
Definition at line 45 of file vsnet_notify.cpp.
|
virtual |
Definition at line 54 of file vsnet_notify.cpp.
void VsnetDownload::Client::Item::append | ( | unsigned char * | buffer, |
int | bufsize | ||
) |
Definition at line 88 of file vsnet_notify.cpp.
References childAppend().
void VsnetDownload::Client::Item::changeState | ( | State | s) |
Definition at line 94 of file vsnet_notify.cpp.
References COUT, e, int, VSMutex::lock(), and VSMutex::unlock().
Referenced by VsnetDownload::Client::Manager::addItems().
Definition at line 105 of file vsnet_notify.cpp.
References COUT, int, VSMutex::lock(), and VSMutex::unlock().
|
protectedpure virtual |
Implemented in VsnetDownload::Client::TestItem, VsnetDownload::Client::Buffer, and VsnetDownload::Client::File.
Referenced by append().
|
protectedpure virtual |
Implemented in VsnetDownload::Client::TestItem, VsnetDownload::Client::Buffer, and VsnetDownload::Client::File.
Referenced by setSize().
VSError VsnetDownload::Client::Item::error | ( | ) | const |
Definition at line 65 of file vsnet_notify.cpp.
References VSMutex::lock(), and VSMutex::unlock().
int VsnetDownload::Client::Item::get_fd | ( | ) | const |
Definition at line 126 of file vsnet_notify.cpp.
References SOCKETALT::get_fd().
const string & VsnetDownload::Client::Item::getFilename | ( | ) | const |
Definition at line 116 of file vsnet_notify.cpp.
Referenced by VsnetDownload::Client::Manager::addItems().
VSFileSystem::VSFileType VsnetDownload::Client::Item::getFileType | ( | ) |
Definition at line 77 of file vsnet_notify.cpp.
References _filetype.
SOCKETALT VsnetDownload::Client::Item::getSock | ( | ) | const |
Definition at line 121 of file vsnet_notify.cpp.
|
protected |
Definition at line 131 of file vsnet_notify.cpp.
Referenced by VsnetDownload::Client::Buffer::Buffer(), and VsnetDownload::Client::NoteFile::NoteFile().
void VsnetDownload::Client::Item::setFileType | ( | VSFileSystem::VSFileType | ft) |
void VsnetDownload::Client::Item::setSize | ( | int | len) |
Definition at line 82 of file vsnet_notify.cpp.
References childSetSize().
State VsnetDownload::Client::Item::state | ( | ) | const |
Definition at line 57 of file vsnet_notify.cpp.
References VSMutex::lock(), and VSMutex::unlock().
|
protected |
Definition at line 199 of file vsnet_notify.h.
Referenced by VsnetDownload::Client::File::childSetSize(), getFileType(), and setFileType().