#include <HostBrowser.h>
Inheritance diagram for CHostBrowser:
Public Types | |
enum | { hbsNull, hbsConnecting, hbsRequesting, hbsHeaders, hbsContent } |
Public Member Functions | |
CHostBrowser (CBrowseHostWnd *pNotify=NULL, IN_ADDR *pAddress=NULL, WORD nPort=0, BOOL bMustPush=FALSE, GGUID *pClientID=NULL) | |
virtual | ~CHostBrowser () |
BOOL | Browse () |
void | Stop (BOOL bCompleted=FALSE) |
BOOL | IsBrowsing () const |
float | GetProgress () const |
virtual BOOL | OnPush (GGUID *pClientID, CConnection *pConnection) |
Public Attributes | |
int | m_nState |
CBrowseHostWnd * | m_pNotify |
CGProfile * | m_pProfile |
BOOL | m_bNewBrowse |
IN_ADDR | m_pAddress |
WORD | m_nPort |
BOOL | m_bMustPush |
BOOL | m_bCanPush |
GGUID | m_pPushID |
GGUID | m_pClientID |
DWORD | m_tPushed |
BOOL | m_bConnect |
int | m_nHits |
CVendor * | m_pVendor |
BOOL | m_bCanChat |
CString | m_sServer |
DWORD | m_nProtocol |
BOOL | m_bDeflate |
DWORD | m_nLength |
DWORD | m_nReceived |
CBuffer * | m_pBuffer |
LPVOID | m_pInflate |
Protected Member Functions | |
BOOL | SendPush (BOOL bMessage) |
void | SendRequest () |
BOOL | ReadResponseLine () |
BOOL | ReadContent () |
BOOL | StreamContent () |
BOOL | StreamPacketsG1 () |
BOOL | StreamPacketsG2 () |
BOOL | StreamHTML () |
BOOL | OnPacket (CG1Packet *pPacket) |
BOOL | OnPacket (CG2Packet *pPacket) |
void | OnProfilePacket (CG2Packet *pPacket) |
virtual BOOL | OnConnected () |
virtual BOOL | OnRead () |
virtual void | OnDropped (BOOL bError) |
virtual BOOL | OnHeaderLine (CString &strHeader, CString &strValue) |
virtual BOOL | OnHeadersComplete () |
virtual BOOL | OnRun () |
|
Definition at line 71 of file HostBrowser.h. |
|
Definition at line 50 of file HostBrowser.cpp. References hbsNull, m_bCanChat, m_bCanPush, m_bConnect, m_bMustPush, m_bNewBrowse, m_nHits, m_nPort, m_nState, m_pAddress, m_pBuffer, m_pClientID, m_pInflate, m_pNotify, m_pProfile, m_pVendor, m_tPushed, and NULL. |
|
Definition at line 78 of file HostBrowser.cpp. References m_pProfile, and Stop(). |
|
Definition at line 88 of file HostBrowser.cpp. References CTransfer::ConnectTo(), hbsConnecting, IDS_BROWSE_CANT_CONNECT_TO, IDS_BROWSE_CANT_PUSH_TO, IDS_BROWSE_CONNECTING_TO, IDS_BROWSE_PUSHED_TO, m_bMustPush, CConnection::m_hSocket, m_nHits, m_nPort, m_nState, m_pAddress, m_pProfile, CTransfers::m_pSection, CConnection::m_sAddress, CShareazaApp::Message(), MSG_ERROR, MSG_SYSTEM, NULL, SendPush(), theApp, and Transfers. Referenced by CBrowseHostWnd::OnBrowseHostRefresh(), and CBrowseHostWnd::OnCreate(). |
|
Definition at line 164 of file HostBrowser.cpp. References hbsContent, m_nLength, m_nReceived, and m_nState. Referenced by CBrowseHeaderCtrl::Update(), and CBrowseHostWnd::UpdateMessages(). |
|
Definition at line 159 of file HostBrowser.cpp. References hbsNull, and m_nState. Referenced by CBrowseHostWnd::OnUpdateBrowseHostStop(). |
|
Reimplemented from CConnection. Definition at line 174 of file HostBrowser.cpp. References CConnection::OnConnected(), and SendRequest(). |
|
Reimplemented from CConnection. Definition at line 205 of file HostBrowser.cpp. References hbsConnecting, IDS_BROWSE_CANT_CONNECT_TO, IDS_BROWSE_DROPPED, CConnection::m_hSocket, CBuffer::m_nLength, m_nLength, m_nState, CConnection::m_pInput, CConnection::m_sAddress, m_tPushed, CShareazaApp::Message(), MSG_ERROR, ReadContent(), SendPush(), Stop(), and theApp. Referenced by OnRun(). |
|
Reimplemented from CTransfer. Definition at line 406 of file HostBrowser.cpp. References CVendorCache::LookupByName(), m_bDeflate, m_nLength, m_nProtocol, m_pVendor, CConnection::m_sAddress, m_sServer, CShareazaApp::Message(), MSG_DEBUG, PROTOCOL_G1, PROTOCOL_G2, theApp, and VendorCache. |
|
Reimplemented from CConnection. Definition at line 440 of file HostBrowser.cpp. References hbsContent, IDS_BROWSE_BAD_RESPONSE, IDS_BROWSE_DOWNLOADING_FROM, inflateInit, m_bDeflate, CConnection::m_mInput, m_nLength, m_nProtocol, m_nReceived, m_nState, m_pBuffer, m_pInflate, CConnection::m_sAddress, CShareazaApp::Message(), MSG_DEFAULT, MSG_ERROR, NULL, PROTOCOL_G1, PROTOCOL_G2, Stop(), theApp, TCPBandwidthMeter::tLast, and Z_OK. |
|
|
Definition at line 626 of file HostBrowser.cpp. References Downloads, CQueryHit::FromPacket(), G1_PACKET_HIT, IDS_BROWSE_PACKET_ERROR, m_bCanChat, m_bCanPush, CQueryHit::m_bChat, m_nHits, CPacket::m_nLength, CG1Packet::m_nType, CQueryHit::m_pClientID, m_pClientID, CQueryHit::m_pNext, m_pNotify, CConnection::m_sAddress, CShareazaApp::Message(), MSG_ERROR, NULL, CBrowseHostWnd::OnBrowseHits(), CDownloads::OnQueryHits(), and theApp. Referenced by StreamPacketsG1(), and StreamPacketsG2(). |
|
Definition at line 714 of file HostBrowser.cpp. References CXMLElement::FromString(), CGProfile::FromXML(), CGProfile::IsValid(), m_pProfile, and NULL. Referenced by OnPacket(). |
|
Definition at line 288 of file HostBrowser.cpp. References CTransfer::AttachTo(), CConnection::m_hSocket, m_nPort, m_pAddress, m_pClientID, CConnection::m_pHost, m_tPushed, and SendRequest(). Referenced by CBrowseHostWnd::OnPush(). |
|
Reimplemented from CConnection. Definition at line 181 of file HostBrowser.cpp. References hbsContent, hbsHeaders, hbsRequesting, m_nState, CConnection::m_pInput, CConnection::m_pOutput, NULL, CConnection::OnRead(), ReadContent(), CConnection::ReadHeaders(), and ReadResponseLine(). |
|
Reimplemented from CConnection. Definition at line 229 of file HostBrowser.cpp. References CSettings::Connection, hbsConnecting, hbsContent, hbsHeaders, hbsRequesting, IDS_BROWSE_TIMEOUT, CConnection::m_mInput, m_nState, CConnection::m_sAddress, CConnection::m_tConnected, CShareazaApp::Message(), MSG_ERROR, OnDropped(), CConnection::OnRun(), Settings, Stop(), theApp, CSettings::sConnection::TimeoutConnect, CSettings::sConnection::TimeoutHandshake, CSettings::sConnection::TimeoutTraffic, and TCPBandwidthMeter::tLast. |
|
Definition at line 491 of file HostBrowser.cpp. References CBuffer::AddBuffer(), CBuffer::EnsureBuffer(), IDS_BROWSE_FINISHED, inflate(), CGProfile::IsValid(), m_bDeflate, CBuffer::m_nBuffer, m_nHits, CBuffer::m_nLength, m_nLength, m_nProtocol, m_nReceived, CBuffer::m_pBuffer, m_pBuffer, m_pInflate, CConnection::m_pInput, m_pNotify, m_pProfile, CConnection::m_sAddress, CShareazaApp::Message(), MSG_SYSTEM, NULL, CBrowseHostWnd::OnProfileReceived(), PROTOCOL_G1, PROTOCOL_G2, CBuffer::Remove(), Stop(), StreamHTML(), StreamPacketsG1(), StreamPacketsG2(), theApp, and Z_SYNC_FLUSH. Referenced by OnDropped(), and OnRead(). |
|
Definition at line 352 of file HostBrowser.cpp. References hbsHeaders, IDS_BROWSE_HTTPCODE, IDS_BROWSE_NOT_HTTP, m_nState, CConnection::m_pInput, CShareazaApp::Message(), MSG_DEBUG, MSG_ERROR, CBuffer::ReadLine(), Stop(), and theApp. Referenced by OnRead(). |
|
Definition at line 268 of file HostBrowser.cpp. References CTransfer::Close(), IDS_BROWSE_PUSHED_TO, m_bCanPush, m_pClientID, CConnection::m_sAddress, m_tPushed, CShareazaApp::Message(), MSG_DEFAULT, Network, CNetwork::SendPush(), and theApp. Referenced by Browse(), and OnDropped(). |
|
|
Definition at line 130 of file HostBrowser.cpp. References CTransfer::Close(), hbsNull, IDS_BROWSE_CLOSED, inflateEnd(), CConnection::m_hSocket, m_nState, m_pBuffer, m_pInflate, CTransfers::m_pSection, CConnection::m_sAddress, m_tPushed, CShareazaApp::Message(), MSG_DEFAULT, NULL, theApp, and Transfers. Referenced by CBrowseHostWnd::OnBrowseHostRefresh(), CBrowseHostWnd::OnBrowseHostStop(), CBrowseHostWnd::OnDestroy(), OnDropped(), OnHeadersComplete(), OnRun(), ReadContent(), ReadResponseLine(), StreamPacketsG1(), StreamPacketsG2(), and ~CHostBrowser(). |
|
|
|
|
Definition at line 554 of file HostBrowser.cpp. References CSettings::Gnutella1, IDS_BROWSE_PACKET_ERROR, CBuffer::m_nLength, CBuffer::m_pBuffer, m_pBuffer, CConnection::m_sAddress, CSettings::sGnutella1::MaximumPacket, CShareazaApp::Message(), MSG_ERROR, CG1Packet::New(), OnPacket(), CPacket::Release(), CBuffer::Remove(), Settings, Stop(), and theApp. Referenced by ReadContent(). |
|
Definition at line 594 of file HostBrowser.cpp. References m_pBuffer, OnPacket(), CG2Packet::ReadBuffer(), CPacket::Release(), and Stop(). Referenced by ReadContent(). |
|
Definition at line 61 of file HostBrowser.h. Referenced by CHostBrowser(), OnPacket(), and CBrowseHostWnd::OnUpdateSearchChat(). |
|
Definition at line 54 of file HostBrowser.h. Referenced by CHostBrowser(), OnPacket(), SendPush(), and StreamHTML(). |
|
Definition at line 58 of file HostBrowser.h. Referenced by CHostBrowser(), SendRequest(), and CBrowseHostWnd::UpdateMessages(). |
|
Definition at line 65 of file HostBrowser.h. Referenced by OnHeaderLine(), OnHeadersComplete(), ReadContent(), and SendRequest(). |
|
Definition at line 53 of file HostBrowser.h. Referenced by Browse(), CHostBrowser(), and CBrowseHostWnd::OnSearchChat(). |
|
Definition at line 50 of file HostBrowser.h. Referenced by CHostBrowser(), and SendRequest(). |
|
Definition at line 59 of file HostBrowser.h. Referenced by Browse(), CHostBrowser(), OnPacket(), ReadContent(), StreamHTML(), and CBrowseHeaderCtrl::Update(). |
|
Definition at line 66 of file HostBrowser.h. Referenced by GetProgress(), OnDropped(), OnHeaderLine(), OnHeadersComplete(), ReadContent(), and SendRequest(). |
|
Definition at line 52 of file HostBrowser.h. Referenced by Browse(), CHostBrowser(), OnPush(), CBrowseHostWnd::OnSearchChat(), and CBrowseHostWnd::UpdateMessages(). |
|
Definition at line 64 of file HostBrowser.h. Referenced by OnHeaderLine(), OnHeadersComplete(), CBrowseHostWnd::OnSearchChat(), ReadContent(), and SendRequest(). |
|
Definition at line 67 of file HostBrowser.h. Referenced by GetProgress(), OnHeadersComplete(), and ReadContent(). |
|
Definition at line 46 of file HostBrowser.h. Referenced by Browse(), CHostBrowser(), GetProgress(), IsBrowsing(), OnDropped(), OnHeadersComplete(), OnRead(), OnRun(), ReadResponseLine(), SendRequest(), Stop(), and CBrowseHostWnd::UpdateMessages(). |
|
Definition at line 51 of file HostBrowser.h. Referenced by Browse(), CHostBrowser(), OnPush(), CBrowseHostWnd::OnSearchChat(), CBrowseHeaderCtrl::Update(), and CBrowseHostWnd::UpdateMessages(). |
|
Definition at line 68 of file HostBrowser.h. Referenced by CHostBrowser(), OnHeadersComplete(), ReadContent(), Stop(), StreamHTML(), StreamPacketsG1(), and StreamPacketsG2(). |
|
Definition at line 56 of file HostBrowser.h. Referenced by CHostBrowser(), OnPacket(), OnPush(), CBrowseHostWnd::OnSearchChat(), SendPush(), and StreamHTML(). |
|
Definition at line 69 of file HostBrowser.h. Referenced by CHostBrowser(), OnHeadersComplete(), ReadContent(), and Stop(). |
|
Definition at line 47 of file HostBrowser.h. Referenced by CHostBrowser(), OnPacket(), ReadContent(), and StreamHTML(). |
|
Definition at line 48 of file HostBrowser.h. Referenced by Browse(), CHostBrowser(), OnPacket(), OnProfilePacket(), ReadContent(), CBrowseHeaderCtrl::Update(), CBrowseHostWnd::UpdateMessages(), and ~CHostBrowser(). |
|
Definition at line 55 of file HostBrowser.h. |
|
Definition at line 60 of file HostBrowser.h. Referenced by CHostBrowser(), OnHeaderLine(), and StreamHTML(). |
|
Definition at line 63 of file HostBrowser.h. Referenced by OnHeaderLine(). |
|
Definition at line 57 of file HostBrowser.h. Referenced by CHostBrowser(), OnDropped(), OnPush(), SendPush(), Stop(), StreamHTML(), and CBrowseHostWnd::UpdateMessages(). |