CompTorrent: abstractpeer.h Source File
file:///C|/Users/stevensc/Desktop/Goldsmith/code/thesis_code/doxygen/html/abstractpeer_8h_source.html[26/11/2014 1:14:08 PM]
Main Page Classes Files
File List
abstractpeer.h
00001 /*
00002 * abstractpeer.h 00003 *
00004 */ 00005
00006 #ifndef _simplep2p_h_ 00007 #define _simplep2p_h_ 00008
00009 #include "controller.h" 00010 #include "comptorrentpeer.h" 00011
00012 #include <iostream> 00013 #include <cc++/socket.h> 00014
00015
00016 #define SERVER 0
00017 #define CONNECT 1
00018 #define PEER 2
00019 #define PEER_LISTENER 4
00020 #define CLIENT 8
00021 00022 #define TRANSMIT 0
00023 #define RECEIVE 1 00024
00025 using namespace std; 00026 using namespace ost; 00027
00028 enum duplex { d_listen, d_talk}; 00029
00030 class AbstractPeer : public TCPSession 00031 {
00032 public: 00033
00034 AbstractPeer(TCPSocket &server, Controller* p, short node_type_); 00035 AbstractPeer(InetHostAddress i, tpport_t port, Controller* p, short node_type_);
00036 ~AbstractPeer(); 00037
00038 void kill_yourself() { die = true; }; 00039
00040 void set_my_ip(string ip, string port) { my_ip = ip; my_port = port; } 00041 void throttle_wait(int time_) { current_wait = time_; }
00042
00043 void push_msg(string msg) { out_box.push_back(msg); } 00044 string get_my_ip() {return my_ip; }
00045 string get_my_port() { return my_port; } 00046 Controller* get_parent() {return parent; } 00047
00048 MessageCollection out_box; 00049 MessageCollection in_box; 00050
00051 protected: 00052
00053 int current_wait; 00054 void run();
00055 void log(const string s) { cout << s << endl; } 00056
00057 bool die;
00058 short sync_mode; 00059
00060 CompTorrentPeer* dt; 00061 Controller* parent; 00062 short node_type; 00063 int virtcount;
00064 unsigned int max_chunk_size; 00065
00066 string my_ip, my_port; 00067 unsigned short timeout; 00068
00069 unsigned long num_messages; 00070
CompTorrent: abstractpeer.h Source File
file:///C|/Users/stevensc/Desktop/Goldsmith/code/thesis_code/doxygen/html/abstractpeer_8h_source.html[26/11/2014 1:14:08 PM]
00072 }; 00073
00074 #endif 00075
file:///C|/Users/stevensc/Desktop/Goldsmith/code/thesis_code/doxygen/html/search/all_63.html[26/11/2014 1:14:08 PM] CompTorrentParser
file:///C|/Users/stevensc/Desktop/Goldsmith/code/thesis_code/doxygen/html/search/all_66.html[26/11/2014 1:14:08 PM] file_chunk
file:///C|/Users/stevensc/Desktop/Goldsmith/code/thesis_code/doxygen/html/search/all_70.html[26/11/2014 1:14:09 PM] peer
CompTorrent: Class List
file:///C|/Users/stevensc/Desktop/Goldsmith/code/thesis_code/doxygen/html/annotated.html[26/11/2014 1:14:10 PM] Main Page Classes Files
Class List Class Members
Class List
Here are the classes, structs, unions and interfaces with brief descriptions:
AbstractPeer
CompTorrentParser CompTorrentPeer Controller
file_chunk
file_chunk_request known_peer
Listener
MessageCollection NetworkSocket orig_data_chunk peer
Processor Router
TrackerParser WorkerThread
BLOBs for PHPLIB
file:///C|/Users/stevensc/Desktop/Goldsmith/code/thesis_code/comptracker/phplib-7.2d/doc/blob.html[26/11/2014 1:14:10 PM] Next Previous Contents
BLOBs for PHPLIB
Sascha Schumann,
[email protected]
$Date: 2000/04/17 16:40:06 $, $Revision: 1.1.1.1 $
RFD on a BLOB API for PHPLIB
1.
BLOB (Binary Large OBjects)
1.1 Defining the problem 1.2 Proposed extension API 1.3 Design notes
file:///C|/Users/stevensc/Desktop/Goldsmith/code/thesis_code/comptracker/phplib-7.2d/doc/blob.txt[26/11/2014 1:14:11 PM] BLOBs for PHPLIB
Sascha Schumann, [email protected]
$Date: 2000/04/17 16:40:06 $, $Revision: 1.1.1.1 $
RFD on a BLOB API for PHPLIB
11.. BBLLOOBB ((BBiinnaarryy LLaarrggee OOBBjjeeccttss))
This chapter is intended to give you a quick introduction to BLOBs, their interface as proposed for PHPLIB.
11..11.. DDeeffiinniinngg tthhee pprroobblleemm
Achieving the goal of creating portable applications is hindered by the fact that no portable way of storing large amount of data exists.
Every database vendor defines his own application programming interface (API) to access binary large objects, or uses other, standard ways to enable the use of BLOBs.
Enhancing the existing vendor neutral support for databases in PHPLIB to also include BLOB support could be a short-term solution to the problem.
11..22.. PPrrooppoosseedd eexxtteennssiioonn AAPPII
An overview over the function calls follows.
bblloobb__ccrreeaattee(())
This will create a new BLOB and return its ID. If it is
impossible to create a new BLOB, this function will halt() the execution and generate an error message.
bblloobb__ooppeenn(($$IIDD))
Opens the specified BLOB for reading and writing and returns true or false on success or failure, respectively.
bblloobb__cclloossee(($$IIDD))
Closes the referenced BLOB. Do not forget this - it might be necessary for some databases or you might face data loss.
file:///C|/Users/stevensc/Desktop/Goldsmith/code/thesis_code/comptracker/phplib-7.2d/doc/blob.txt[26/11/2014 1:14:11 PM] Deletes the specified BLOB. All associated resources are freed.
The BLOB must not be referenced at a later time.
bblloobb__rreeaadd(($$IIDD))
Reads the entire data of BLOB and returns it.
bblloobb__wwrriittee(($$IIDD,, $$DDAATTAA))
Overwrites the whole BLOB with $DATA.
11..33.. DDeessiiggnn nnootteess
BLOBs for PHPLIB: BLOB (Binary Large OBjects)
file:///C|/Users/stevensc/Desktop/Goldsmith/code/thesis_code/comptracker/phplib-7.2d/doc/blob-1.html[26/11/2014 1:14:11 PM] Next Previous Contents
1. BLOB (Binary Large OBjects)
This chapter is intended to give you a quick introduction to BLOBs, their interface as proposed for PHPLIB.
1.1 Defining the problem
Achieving the goal of creating portable applications is hindered by the fact that no portable way of storing large amount of data exists.
Every database vendor defines his own application programming interface (API) to access binary large objects, or uses other, non-standard ways to enable the use of BLOBs.
Enhancing the existing vendor neutral support for databases in PHPLIB to also include BLOB support could be a short-term solution to the problem.
1.2 Proposed extension API
An overview over the function calls follows.
blob_create()
This will create a new BLOB and return its ID. If it is impossible to create a new BLOB, this function will halt() the execution and generate an error message.
blob_open($ID)
Opens the specified BLOB for reading and writing and returns true or false on success or failure, respectively.
blob_close($ID)
Closes the referenced BLOB. Do not forget this - it might be necessary for some databases or you might face data loss.
blob_delete($ID)
Deletes the specified BLOB. All associated resources are freed. The BLOB must not be referenced at a later time.
blob_read($ID)
Reads the entire data of BLOB and returns it.
blob_write($ID, $DATA)
Overwrites the whole BLOB with $DATA.
1.3 Design notes
BLOBs for PHPLIB: BLOB (Binary Large OBjects)
file:///C|/Users/stevensc/Desktop/Goldsmith/code/thesis_code/comptracker/phplib-7.2d/doc/blob-1.html[26/11/2014 1:14:11 PM]
natively. Keep in mind that it should be able to cover as many databases as possible and therefore only implements a subset of functionality provided by modern databases.
file:///C|/Users/stevensc/Desktop/Goldsmith/code/support_libs/EasyBMP_1.06/BSD_(revised)_license.txt[26/11/2014 1:14:11 PM] Copyright (c) 2005, The EasyBMP Project (http://easybmp.sourceforge.net)
All rights reserved.
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
3. The name of the author may not be used to endorse or promote products derived from this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
file:///C|/Users/stevensc/Desktop/Goldsmith/code/support_libs/tinyxml/changes.txt[26/11/2014 1:14:11 PM] Changes in version 1.0.1:
- Fixed comment tags which were outputing as '<?--' instead of the correct '<!--'.
- Implemented the Next and Prev methods of the TiXmlAttribute class. - Renamed 'LastAttribtute' to 'LastAttribute'
- Fixed bad pointer to 'isspace' that could occur while parsing text. - Errors finding beginning and end of tags no longer throw it into an infinite loop. (Hopefully.)
Changes in version 1.0.2 - Minor documentation fixes.
Changes in version 1.0.3
- After nodes are added to a document, they return a pointer to the new node instead of a bool for success.
- Elements can be constructed with a value, which is the element name. Every element must have a value or it will be invalid, but the code changes to enforce this are not fully in place.
Changes in version 1.1.0
- Added the TiXmlAttributeSet class to pull the attributes into a seperate container.
- Moved the doubly liked list out of XmlBase. Now XmlBase only requires the Print() function and defines some utility functions.
- Moved errors into a seperate file. (With the idea of internationalization to the other latin-1 languages.)
- Added the "NodeType"
- Fixed white space parsing in text to conform with the standard. Basically, all white space becomes just one space.
- Added the TiXmlDeclaration class to read xml declarations.
Changes in version 1.2.0
- Removed the factory. The factory was not really in the spirit of small and simple, confused the code, and was of limited value. - Added FirstChildElement and NextSiblingElement, because they are such common functions.
- Re-wrote the example to test and demonstrate more functionality.
Changes in version 1.2.1
- Fixed a bug where comments couldn't be inside elements. - Loading now clears out existing XML rather than appending. - Added the "Clear" method on a node to delete all its children.
Changes in version 1.2.2
- Fixed TiXmlAttribute::Previous actually returning "next." Thanks to Rickard Troedsson for the bug fix.
Changes in version 1.2.3
- Added the TIXML prefix to the error strings to resolve conflicts with #defines in OS headers. Thanks to Steve Lhomme.
file:///C|/Users/stevensc/Desktop/Goldsmith/code/support_libs/tinyxml/changes.txt[26/11/2014 1:14:11 PM] Changes in version 1.2.4
- ReplaceChild() was almost guarenteed to fail. Should be fixed, thanks to Joe Smith. Joe also pointed out that the Print() functions should take stream references: I agree, and would like to overload the Print() method to take either format, but I don't want to do this in a dot release.
- Some compilers seem to need an extra <ctype.h> include. Thanks to Steve Lhomme for that.
Changes in version 2.0.0 BETA
- Made the ToXXX() casts safe if 'this' is null.
When "LoadFile" is called with a filename, the value will correctly get set. Thanks to Brian Yoder.
- Fixed bug where isalpha() and isalnum() would get called with a negative value for high ascii numbers. Thanks to Alesky Aksenov.
- Fixed some errors codes that were not getting set. - Made methods "const" that were not.
- Added a switch to enable or disable the ignoring of white space. ( TiXmlDocument::SetIgnoreWhiteSpace() ) - Greater standardization and code re-use in the parser.
- Added a stream out operator. - Added a stream in operator.
- Entity support, of predefined entites. &#x entities are untouched by input or output. - Improved text out formatting.
- Fixed ReplaceChild bug, thanks to Tao Chen.
Changes in version 2.0.1
- Fixed hanging on loading a 0 length file. Thanks to Jeff Scozzafava.
- Fixed crashing on InsertBeforeChild and InsertAfterChild. Also possibility of bad links being created by same function. Thanks to Frank De prins.
- Added missing licence text. Thanks to Lars Willemsens. - Added <ctype.h> include, at the suggestion of Steve Walters.
Changes in version 2.1.0
- Yves Berquin brings us the STL switch. The forum on SourceForge, and various emails to me, have long debated all out STL vs. no STL at all. And now you can have it both ways. TinyXml will compile either way.
Changes in version 2.1.1 - Compilation warnings.
Changes in version 2.1.2
- Uneeded code is not compiled in the STL case.
- Changed headers so that STL can be turned on or off in tinyxml.h
Changes in version 2.1.3
- Fixed non-const reference in API; now uses a pointer.
- Copy constructor of TiXmlString not checking for assignment to self.
- Nimrod Cohen found a truly evil bug in the STL implementation that occurs when a string is converted to a c_str and then assigned to self. Search for STL_STRING_BUG for a full description. I'm asserting this is a Microsoft STL bug, since &string and string.c_str() should never be the same. Nevertheless, the code works around it.
file:///C|/Users/stevensc/Desktop/Goldsmith/code/support_libs/tinyxml/changes.txt[26/11/2014 1:14:11 PM] the isblank macro, which was wiping out the TiXmlString::isblank() method. The method was unused and has been removed.
Changes in version 2.1.4
- Reworked the entity code. Entities were not correctly surving round trip input and output. Will now automatically create entities for high ascii in output.
Changes in version 2.1.5
- Bug fix by kylotan : infinite loop on some input (tinyxmlparser.cpp rev 1.27)
- Contributed by Ivica Aracic (bytelord) : 1 new VC++ project to compile versions as static libraries (tinyxml_lib.dsp), and an example usage in xmltest.dsp
(Patch request ID 678605)
- A suggestion by Ronald Fenner Jr (dormlock) to add #include <istream> and <ostream> for Apple's Project Builder (Patch request ID 697642)
- A patch from ohommes that allows to parse correctly dots in element names and attribute names (Patch request 602600 and kylotan 701728)
- A patch from hermitgeek ( James ) and wasteland for improper error reporting - Reviewed by Lee, with the following changes:
- Got sick of fighting the STL/non-STL thing in the windows build. Broke them out as seperate projects.
- I have too long not included the dsw. Added. - TinyXmlText had a protected Print. Odd.
- Made LinkEndChild public, with docs and appropriate warnings. - Updated the docs.
2.2.0
- Fixed an uninitialized pointer in the TiXmlAttributes
- Fixed STL compilation problem in MinGW (and gcc 3?) - thanks Brian Yoder for finding this one - Fixed a syntax error in TiXmlDeclaration - thanks Brian Yoder
- Fletcher Dunn proposed and submitted new error handling that tracked the row and column. Lee modified it to not have performance impact.
- General cleanup suggestions from Fletcher Dunn.
- In error handling, general errors will no longer clear the error state of specific ones.
- Fix error in documentation : comments starting with "<?--" instead of "<!--" (thanks ion_pulse) - Added the TiXmlHandle. An easy, safe way to browse XML DOMs with less code.
- Added QueryAttribute calls which have better error messaging. (Proposed by Fletcher Dunn) - Nodes and attributes can now print themselves to strings. (Yves suggestion)
- Fixed bug where entities with one character would confuse parser. (Thanks Roman)
2.2.1
- Additional testing (no more bugs found to be fixed in this release) - Significant performance improvement to the cursor code.
2.3.0
- User Data are now defined in TiXmlBase instead of TiXmlNode - Character Entities are now UCS-2
- Character Entities can be decimal or hexadecimal - UTF-8 conversion.
- Fixed many, many bugs.
2.3.1
file:///C|/Users/stevensc/Desktop/Goldsmith/code/support_libs/tinyxml/changes.txt[26/11/2014 1:14:11 PM] - Many fixes and input from John-Philip Leonard Johansson (JP) and Ellers, including UTF-8 feedback, bug reports, and patches. Thanks!
- Added version # constants - a suggestion from JP and Ellers. - [ 979180 ] Missing ; in entity reference, fix from Rob Laveaux.
- Copy constructors and assignment have been a long time coming. Thanks to Fokke and JP.
2.3.2
- Made the IsAlpha and IsAlphaNum much more tolerant of non-UTF-8 encodings. Thanks Volker Boerchers for finding the issue.
- Ran the program though the magnificent Valgrind - http://valgrind.kde.org - to check for memory errors. Fixed some minor issues.
2.3.3
- Fixed crash when test program was run from incorrect directory.
- Fixed bug 1070717 - empty document not returned correctly - thanks Katsuhisa Yuasa. - Bug 1079301 resolved - deprecated stdlib calls. Thanks Adrian Boeing.
- Bug 1035218 fixed - documentation errors. Xunji Luo
- Other bug fixes have accumulated and been fixed on the way as well; my apologies to authors not credited!
- Big fix / addition is to correctly return const values. TinyXml could basically
remove const in a method like this: TiXmlElement* Foo() const, where the returned element was a pointer to internal data. That is now: const TiXmlElement* Foo() const and
TiXmlElement* Foo().
2.3.4
- Fixed additional const errors, thanks Kent Gibson.
- Correctly re-enable warnings after tinyxml header. Thanks Cory Nelson. - Variety of type cleanup and warning fixes. Thanks Warren Stevens.
- Cleaned up unneeded constructor calls in TinyString - thanks to Geoff Carlton and the discussion group on sourceforge.
2.4.0
- Improved string class, thanks Tyge Lovset (whose name gets mangled in English - sorry) - Type cast compiler warning, thanks Rob van den Bogaard
- Added GetText() convenience function. Thanks Ilya Parniuk & Andrew Ellers for input. - Many thanks to marlonism for finding an infinite loop in bad xml.
- A patch to cleanup warnings from Robert Gebis.
- Added ValueStr() to get the value of a node as a string. - TiXmlText can now parse and output as CDATA - Additional string improvement from James (z2895) - Removed extraneous 'const', thanks David Aldrich
- First pass at switching to the "safe" stdlib functions. Many people have suggested and pushed on this, but Warren Stevens put together the first proposal.
- TinyXml now will do EOL normalization before parsing, consistent with the W3C XML spec. - Documents loaded with the UTF-8 BOM will now save with the UTF-8 BOM. Good suggestion from 'instructor_'
- Ellers submitted his very popular tutorials, which have been added to the distribution.
2.4.1
- Fixed CDATA output formatting
CompTorrent: AbstractPeer Class Reference
file:///C|/Users/stevensc/Desktop/Goldsmith/code/thesis_code/doxygen/html/classAbstractPeer.html[26/11/2014 1:14:12 PM] Main Page Classes Files
Class List Class Members
AbstractPeer Class Reference
Collaboration diagram for AbstractPeer:
[legend]
List of all members.
Public Member Functions
AbstractPeer (TCPSocket &server, Controller *p, short node_type_)
AbstractPeer (InetHostAddress i, tpport_t port, Controller *p, short node_type_) void kill_yourself ()
void set_my_ip (string ip, string port) void throttle_wait (int time_) void push_msg (string msg) string get_my_ip ()
string get_my_port ()
Controller * get_parent () Public Attributes
MessageCollection out_box
MessageCollection in_box
Protected Member Functions void run ()
void log (const string s) Protected Attributes
int current_wait
bool die
short sync_mode
CompTorrentPeer * dt
Controller * parent
short node_type
int virtcount
unsigned int max_chunk_size
string my_ip
string my_port
unsigned short timeout
unsigned long num_messages
int threadid
The documentation for this class was generated from the following files:
abstractpeer.h
abstractpeer.cpp
Controller
CompTorrentParser
parent
Router parent
Listener parent
Processor parent
TrackerParser parent comp_torrent
known_peer
last_tracker_suggestion
my_peer_record
AbstractPeer
CompTorrentPeer simplep2p dt
Controller
parent
parent CompTorrentParser
parent
Router parent
Listener parent
Processor parent
TrackerParser parent comp_torrent
known_peer
last_tracker_suggestion
my_peer_record
router listener processor tracker
MessageCollection
CompTorrent: Member List
file:///C|/Users/stevensc/Desktop/Goldsmith/code/thesis_code/doxygen/html/classAbstractPeer-members.html[26/11/2014 1:14:17 PM] Main Page Classes Files
Class List Class Members
AbstractPeer Member List
This is the complete list of members for AbstractPeer, including all inherited members. AbstractPeer(TCPSocket &server, Controller *p, short node_type_) (defined in
AbstractPeer) AbstractPeer
AbstractPeer(InetHostAddress i, tpport_t port, Controller *p, short node_type_)
(defined in AbstractPeer) AbstractPeer
current_wait (defined in AbstractPeer) AbstractPeer[protected]
die (defined in AbstractPeer) AbstractPeer[protected]
dt (defined in AbstractPeer) AbstractPeer[protected]
get_my_ip() (defined in AbstractPeer) AbstractPeer[inline]
get_my_port() (defined in AbstractPeer) AbstractPeer[inline]
get_parent() (defined in AbstractPeer) AbstractPeer[inline]
in_box (defined in AbstractPeer) AbstractPeer
kill_yourself() (defined in AbstractPeer) AbstractPeer[inline]
log(const string s) (defined in AbstractPeer) AbstractPeer[inline,
protected]
max_chunk_size (defined in AbstractPeer) AbstractPeer[protected]
my_ip (defined in AbstractPeer) AbstractPeer[protected]
my_port (defined in AbstractPeer) AbstractPeer[protected]
node_type (defined in AbstractPeer) AbstractPeer[protected]
num_messages (defined in AbstractPeer) AbstractPeer[protected]
out_box (defined in AbstractPeer) AbstractPeer
parent (defined in AbstractPeer) AbstractPeer[protected]
push_msg(string msg) (defined in AbstractPeer) AbstractPeer[inline]
run() (defined in AbstractPeer) AbstractPeer[protected]
set_my_ip(string ip, string port) (defined in AbstractPeer) AbstractPeer[inline]
sync_mode (defined in AbstractPeer) AbstractPeer[protected]
threadid (defined in AbstractPeer) AbstractPeer[protected]
throttle_wait(int time_) (defined in AbstractPeer) AbstractPeer[inline]
timeout (defined in AbstractPeer) AbstractPeer[protected]
virtcount (defined in AbstractPeer) AbstractPeer[protected]
~AbstractPeer() (defined in AbstractPeer) AbstractPeer
CompTorrent: CompTorrentParser Class Reference
file:///C|/Users/stevensc/Desktop/Goldsmith/code/thesis_code/doxygen/html/classCompTorrentParser.html[26/11/2014 1:14:17 PM] Main Page Classes Files
Class List Class Members
CompTorrentParser Class Reference
Collaboration diagram for CompTorrentParser:
[legend]
List of all members.
Public Member Functions
CompTorrentParser (Controller *parent_) bool load_xml (string)
bool create_working () string get_version () string get_tracker_url () string get_tracker_port () string get_name ()
string get_size () string get_md5 ()
string get_algorithm_base64 () string get_algorithm_filename () string get_execution ()
unsigned long get_num_orig_file_chunks () bool comp_data_exists (string filename) bool orig_data_exists (string filename) bool known_peer_exists (known_peer kp) void add_known_peer (known_peer kp) void remove_known_peer (known_peer kp) unsigned long get_num_known_peers ()
unsigned long get_num_connected_peers ()
string chunk_name (unsigned long chunk_num) string chunk_orig_hash (string chunk_name)
bool get_orig_hash (string chunk_name, string &resulthash)
void update_chunk (unsigned long chunk_num, computation_state state, bool orig_file_exists, bool comp_file_exists)
CompTorrent: CompTorrentParser Class Reference
file:///C|/Users/stevensc/Desktop/Goldsmith/code/thesis_code/doxygen/html/classCompTorrentParser.html[26/11/2014 1:14:17 PM]
void update_comp_chunk (string chunk_name, computation_state state, bool file_exists) void update_orig_chunk (string chunk_name, computation_state state, bool file_exists) unsigned long get_num_chunks ()
bool has_comp_converged (computation_state state) string get_node_uuid ()
unsigned long get_num_computed_chunks () unsigned long get_num_original_chunks ()
void increment_num_computed_chunks ()
void add_directory_to_file (string filename, string comp_or_data, string &filepath) void strip_directory_from_file (string filepath, string &chunk_name)
void calculate_file_hash (string filepath, string &resulthash)
Static Public Member Functions
static int my_file_size (const string filepath)
Public Attributes
vector< orig_data_chunk > data_chunk_list filemap known_files
Protected Member Functions
string get_UUID (string device)
Protected Attributes
bool loaded_ok string version string tracker_url string tracker_port string name
string size string md5
string algorithm_base64 string algorithm_filename string execution
string uuid
vector< known_peer > known_peers
known_peer my_peer_record Mutex status_mutex
unsigned long num_computed_chunks unsigned long num_original_chunks
Controller * parent
Friends
class Processor
class CompTorrent class DistTorrent
The documentation for this class was generated from the following files:
comptorrentparser.h
comptorrentparser.cpp
CompTorrentParser
Controller comp_torrent parent
Router parent
Listener parent
Processor parent
TrackerParser parent
router listener processor known_peer
my_peer_record
last_tracker_suggestion
CompTorrentParser
Controller comp_torrent parent
Router parent
Listener parent
Processor parent
TrackerParser parent
router listener processor known_peer
my_peer_record
last_tracker_suggestion
CompTorrent: Member List
file:///C|/Users/stevensc/Desktop/Goldsmith/code/thesis_code/doxygen/html/classCompTorrentParser-members.html[26/11/2014 1:14:22 PM] Main Page Classes Files
Class List Class Members
CompTorrentParser Member List
This is the complete list of members for CompTorrentParser, including all inherited members. add_directory_to_file(string filename, string comp_or_data, string &filepath)
(defined in CompTorrentParser) CompTorrentParser
add_known_peer(known_peer kp) (defined in CompTorrentParser) CompTorrentParser
algorithm_base64 (defined in CompTorrentParser) CompTorrentParser[protected]
algorithm_filename (defined in CompTorrentParser) CompTorrentParser[protected]
calculate_file_hash(string filepath, string &resulthash) (defined in
CompTorrentParser) CompTorrentParser
chunk_name(unsigned long chunk_num) (defined in CompTorrentParser) CompTorrentParser
chunk_orig_hash(string chunk_name) (defined in CompTorrentParser) CompTorrentParser
comp_data_exists(string filename) (defined in CompTorrentParser) CompTorrentParser
CompTorrent (defined in CompTorrentParser) CompTorrentParser[friend]
CompTorrentParser(Controller *parent_) (defined in CompTorrentParser) CompTorrentParser
create_working() (defined in CompTorrentParser) CompTorrentParser
data_chunk_list (defined in CompTorrentParser) CompTorrentParser
DistTorrent (defined in CompTorrentParser) CompTorrentParser[friend]
execution (defined in CompTorrentParser) CompTorrentParser[protected]
get_algorithm_base64() (defined in CompTorrentParser) CompTorrentParser
get_algorithm_filename() (defined in CompTorrentParser) CompTorrentParser
get_execution() (defined in CompTorrentParser) CompTorrentParser
get_md5() (defined in CompTorrentParser) CompTorrentParser
get_name() (defined in CompTorrentParser) CompTorrentParser
get_node_uuid() (defined in CompTorrentParser) CompTorrentParser
get_num_chunks() (defined in CompTorrentParser) CompTorrentParser
get_num_computed_chunks() (defined in CompTorrentParser) CompTorrentParser
get_num_connected_peers() (defined in CompTorrentParser) CompTorrentParser
get_num_known_peers() (defined in CompTorrentParser) CompTorrentParser
get_num_orig_file_chunks() (defined in CompTorrentParser) CompTorrentParser
get_num_original_chunks() (defined in CompTorrentParser) CompTorrentParser
get_orig_hash(string chunk_name, string &resulthash) (defined in
CompTorrentParser) CompTorrentParser
get_size() (defined in CompTorrentParser) CompTorrentParser
get_tracker_port() (defined in CompTorrentParser) CompTorrentParser
get_tracker_url() (defined in CompTorrentParser) CompTorrentParser
get_UUID(string device) (defined in CompTorrentParser) CompTorrentParser[protected]
get_version() (defined in CompTorrentParser) CompTorrentParser
has_comp_converged(computation_state state) (defined in CompTorrentParser) CompTorrentParser
increment_num_computed_chunks() (defined in CompTorrentParser) CompTorrentParser
known_files (defined in CompTorrentParser) CompTorrentParser
known_peer_exists(known_peer kp) (defined in CompTorrentParser) CompTorrentParser
known_peers (defined in CompTorrentParser) CompTorrentParser[protected]
load_xml(string) (defined in CompTorrentParser) CompTorrentParser
loaded_ok (defined in CompTorrentParser) CompTorrentParser [protected]
md5 (defined in CompTorrentParser) CompTorrentParser [protected]
my_file_size(const string filepath) (defined in CompTorrentParser) CompTorrentParser [static]
my_peer_record (defined in CompTorrentParser) CompTorrentParser [protected]
name (defined in CompTorrentParser) CompTorrentParser [protected]
num_computed_chunks (defined in CompTorrentParser) CompTorrentParser [protected]
CompTorrent: Member List
file:///C|/Users/stevensc/Desktop/Goldsmith/code/thesis_code/doxygen/html/classCompTorrentParser-members.html[26/11/2014 1:14:22 PM]
orig_data_exists(string filename) (defined in CompTorrentParser) CompTorrentParser
parent (defined in CompTorrentParser) CompTorrentParser[protected]
Processor (defined in CompTorrentParser) CompTorrentParser[friend]
remove_known_peer(known_peer kp) (defined in CompTorrentParser) CompTorrentParser
size (defined in CompTorrentParser) CompTorrentParser[protected]
status_mutex (defined in CompTorrentParser) CompTorrentParser[protected]
strip_directory_from_file(string filepath, string &chunk_name) (defined in
CompTorrentParser) CompTorrentParser
tracker_port (defined in CompTorrentParser) CompTorrentParser[protected]
tracker_url (defined in CompTorrentParser) CompTorrentParser[protected]
update_chunk(unsigned long chunk_num, computation_state state, bool
orig_file_exists, bool comp_file_exists) (defined in CompTorrentParser) CompTorrentParser update_chunk(string chunk_name, computation_state state, bool orig_file_exists,
bool comp_file_exists) (defined in CompTorrentParser) CompTorrentParser
update_comp_chunk(string chunk_name, computation_state state, bool
file_exists) (defined in CompTorrentParser) CompTorrentParser
update_orig_chunk(string chunk_name, computation_state state, bool file_exists)
(defined in CompTorrentParser) CompTorrentParser
uuid (defined in CompTorrentParser) CompTorrentParser[protected]
version (defined in CompTorrentParser) CompTorrentParser[protected]
CompTorrent: CompTorrentPeer Class Reference
file:///C|/Users/stevensc/Desktop/Goldsmith/code/thesis_code/doxygen/html/classCompTorrentPeer.html[26/11/2014 1:14:22 PM] Main Page Classes Files
Class List Class Members
CompTorrentPeer Class Reference
Collaboration diagram for CompTorrentPeer:
[legend]
List of all members.
Public Member Functions
CompTorrentPeer (Controller *s, AbstractPeer *simplep2p_) void push_msg (string msg)
bool has_file_available (string filename, string type) void debug_stats ()
string get_buddy_route () bool is_higher_route ()
Protected Member Functions
bool add_available_file (string, string) void send_welcome_message () void send_noop ()
void run ()
bool process_noop (string intmp) bool process_file_update (string intmp) bool process_welcome_message (string intmp) bool process_connect_message (string intmp) bool process_file_reply (string intmp)
bool process_file_request (string intmp) bool process_overlay_message (string intmp)
bool process_overlay_update_message (string intmp) bool ask_for_next_comp_file ()
CompTorrent: CompTorrentPeer Class Reference
file:///C|/Users/stevensc/Desktop/Goldsmith/code/thesis_code/doxygen/html/classCompTorrentPeer.html[26/11/2014 1:14:22 PM]
void save_file_reply (xmlmap &xml_map) void parse_datachunks (string xml)
Static Protected Member Functions
static bool string_find (const string needle, const string haystack) static string trim_spaces (std::string const &str)
Protected Attributes AbstractPeer * simplep2p
Controller * parent
int num_messages
short peer_type
distributed_state state
string buddy_route
file_chunk_type files_available
The documentation for this class was generated from the following files: comptorrentpeer.h
comptorrentpeer.cpp
Controller
CompTorrentParser parent
Router
parent
Listener parent
Processor parent
TrackerParser parent comp_torrent
known_peer
last_tracker_suggestion
my_peer_record
CompTorrentPeer
AbstractPeer dt Controller
parent
CompTorrentParser parent
Router
parent
Listener parent
Processor parent
TrackerParser parent
parent comp_torrent
known_peer
last_tracker_suggestion
my_peer_record
router listener processor tracker
simplep2p
MessageCollection
CompTorrent: Member List
file:///C|/Users/stevensc/Desktop/Goldsmith/code/thesis_code/doxygen/html/classCompTorrentPeer-members.html[26/11/2014 1:14:27 PM] Main Page Classes Files
Class List Class Members
CompTorrentPeer Member List
This is the complete list of members for CompTorrentPeer, including all inherited members.
add_available_file(string, string) (defined in CompTorrentPeer) CompTorrentPeer[protected]
ask_for_next_comp_file() (defined in CompTorrentPeer) CompTorrentPeer[protected]
ask_for_next_orig_file() (defined in CompTorrentPeer) CompTorrentPeer[protected]
buddy_route (defined in CompTorrentPeer) CompTorrentPeer[protected]
CompTorrentPeer(Controller *s, AbstractPeer *simplep2p_) (defined in
CompTorrentPeer) CompTorrentPeer
debug_stats() (defined in CompTorrentPeer) CompTorrentPeer
files_available (defined in CompTorrentPeer) CompTorrentPeer[protected]
get_buddy_route() (defined in CompTorrentPeer) CompTorrentPeer[inline]
has_file_available(string filename, string type) (defined in CompTorrentPeer) CompTorrentPeer
is_higher_route() (defined in CompTorrentPeer) CompTorrentPeer
num_messages (defined in CompTorrentPeer) CompTorrentPeer[protected]
parent (defined in CompTorrentPeer) CompTorrentPeer[protected]
parse_datachunks(string xml) (defined in CompTorrentPeer) CompTorrentPeer[protected]
peer_type (defined in CompTorrentPeer) CompTorrentPeer[protected]
process_connect_message(string intmp) (defined in CompTorrentPeer) CompTorrentPeer[protected]
process_file_reply(string intmp) (defined in CompTorrentPeer) CompTorrentPeer[protected]
process_file_request(string intmp) (defined in CompTorrentPeer) CompTorrentPeer[protected]
process_file_update(string intmp) (defined in CompTorrentPeer) CompTorrentPeer[protected]
process_noop(string intmp) (defined in CompTorrentPeer) CompTorrentPeer[protected]
process_overlay_message(string intmp) (defined in CompTorrentPeer) CompTorrentPeer[protected]
process_overlay_update_message(string intmp) (defined in
CompTorrentPeer) CompTorrentPeer[protected]
process_welcome_message(string intmp) (defined in CompTorrentPeer) CompTorrentPeer[protected]
push_msg(string msg) (defined in CompTorrentPeer) CompTorrentPeer
run() (defined in CompTorrentPeer) CompTorrentPeer[protected]
save_file_reply(xmlmap &xml_map) (defined in CompTorrentPeer) CompTorrentPeer[protected]
send_noop() (defined in CompTorrentPeer) CompTorrentPeer[protected]
send_welcome_message() (defined in CompTorrentPeer) CompTorrentPeer[protected]
simplep2p (defined in CompTorrentPeer) CompTorrentPeer[protected]
state (defined in CompTorrentPeer) CompTorrentPeer[protected]
string_find(const string needle, const string haystack) (defined in
CompTorrentPeer) CompTorrentPeer[protected,static]
trim_spaces(std::string const &str) (defined in CompTorrentPeer) CompTorrentPeer[protected, static]
~CompTorrentPeer() (defined in CompTorrentPeer) CompTorrentPeer
CompTorrent: Controller Class Reference
file:///C|/Users/stevensc/Desktop/Goldsmith/code/thesis_code/doxygen/html/classController.html[26/11/2014 1:14:27 PM] Main Page Classes Files
Class List Class Members
Controller Class Reference
Collaboration diagram for Controller:
[legend]
List of all members.
Public Member Functions
Controller (bool index, bool is_processing) void debug_stats ()
void start_distributed (string host_ip_, string host_port_) void start_listener (string host_ip_, string host_port_) void make_connection (string host_ip_, string host_port_)
void attempt_outgoing_connection (string host_ip_, string host_port_) void attempt_incoming_connection (string host_ip_, string host_port_) bool parse_torrent (string file_path)
bool create_working () void log (const ostringstream s) void log (const string s)
int get_num_connections ()
int get_num_incoming_connections () int get_num_outgoing_connections ()
void increment_num_incoming_connections () void increment_num_outgoing_connections () void decrement_num_outgoing_connections () void decrement_num_incoming_connections () void set_tracker_url (string tracker_url_)
string get_tracker_url ()
unsigned long bootstrap_from_tracker () void clear_tracker_data ()
void set_routing_id (string routing_id_) string get_routing_id ()
string get_next_routing_id () void set_ip (string ip_) void set_port (string port_) string get_ip ()
string get_port ()
void set_network_device (string my_device) string get_network_device ()
void report_change (bool change_) bool change_occured ()
bool have_comp_chunk (string chunkname)
CompTorrent: Controller Class Reference
file:///C|/Users/stevensc/Desktop/Goldsmith/code/thesis_code/doxygen/html/classController.html[26/11/2014 1:14:27 PM]
void get_known_comp_chunks_xml (ostringstream &xml) int get_num_comp_chunks ()
bool remove_required_comp_chunk (string chunk_name) void add_required_comp_chunk (string filename)
bool get_next_required_comp_chunk (file_chunk &f) int num_required_comp_chunks ()
bool have_file (string chunkname, string filetype) void request_file (string chunkname, string filetype) bool have_orig_chunk (string chunkname)
void add_orig_chunk (string filename, string resulthash) void get_known_orig_chunks_xml (ostringstream &xml)
int get_num_orig_chunks ()
bool remove_required_orig_chunk (string chunk_name) void add_required_orig_chunk (string filename)
void add_required_orig_chunk_front (string filename) bool get_next_required_orig_chunk (file_chunk &f)
int num_required_orig_chunks ()
void add_connected_peer (string ip, string port, void *distorrent) bool connected_peer_exists (string ip, string port)
void out_broadcast (string msg)
bool remove_connected_peer (string ip, string port) void add_peer_under_consideration (string ip, string port) bool peer_under_consideration (string ip, string port) bool remove_considered_peer (string ip, string port)
bool add_backlog_file (string filename, string filetype, CompTorrentPeer *who) void check_backlog (xmlmap &xml_map)
bool is_index ()
Static Public Member Functions
static bool xml_to_map (const string xml, xmlmap &xml_map) static string get_device_ip (string device)
static string trim_spaces (std::string const &str)
Public Attributes
Mutex connect_mutex
CompTorrentParser * comp_torrent
TrackerParser * tracker
Processor * processor [NUM_PROCESSORS] Mutex parser_tracker_mutex
Mutex get_next_comp_chunk_mutex
Mutex get_next_orig_chunk_mutex Mutex comp_chunk_collection Mutex orig_chunk_collection
Protected Attributes
Router * router
peer_type connected_peers
peer_type peers_being_considered Mutex peers_considered_mutex Mutex backlog_mutex
file_chunk_type comp_chunks_we_want file_chunk_type comp_chunks_we_have file_chunk_type orig_chunks_we_have file_chunk_type orig_chunks_we_want file_request_type request_backlog
string network_device string routing_id
bool waiting
CompTorrent: Controller Class Reference
file:///C|/Users/stevensc/Desktop/Goldsmith/code/thesis_code/doxygen/html/classController.html[26/11/2014 1:14:27 PM]
bool is_processing string tracker_url string ip
string port
known_peer last_tracker_suggestion int wait_time
int connection_wait
Listener * listener bool routing_set unsigned long next_route_id
bool change
Friends
class Router
Member Function Documentation
bool Controller::xml_to_map ( const string xml,
xmlmap & xml_map
) [static]
A static method which takes some comptorrent xml and converts it into an associative array to make life a little easier when using it (since most of the work required with the xml is just pulling tags and values out. Only works one level deep! Parameters:
xml The input xml
xml_map The container to fill
Returns:
boolean success or failure
The documentation for this class was generated from the following files:
controller.h
controller.cpp
Controller
CompTorrentParser parent
Router parent
Listener parent
Processor parent
TrackerParser
parent comp_torrent known_peer
last_tracker_suggestion
my_peer_rec
Controller
CompTorrentParser parent
Router parent
Listener parent
Processor parent
TrackerParser
parent comp_torrent known_peer
last_tracker_suggestion
my_peer_record
CompTorrent: Member List
file:///C|/Users/stevensc/Desktop/Goldsmith/code/thesis_code/doxygen/html/classController-members.html[26/11/2014 1:14:32 PM] Main Page Classes Files
Class List Class Members
Controller Member List
This is the complete list of members for Controller, including all inherited members. add_backlog_file(string filename, string filetype, CompTorrentPeer *who) (defined in
Controller) Controller
add_comp_chunk(string filename, string resulthash) (defined in Controller) Controller
add_connected_peer(string ip, string port, void *distorrent) (defined in Controller) Controller
add_orig_chunk(string filename, string resulthash) (defined in Controller) Controller
add_peer_under_consideration(string ip, string port) (defined in Controller) Controller
add_required_comp_chunk(string filename) (defined in Controller) Controller
add_required_orig_chunk(string filename) (defined in Controller) Controller
add_required_orig_chunk_front(string filename) (defined in Controller) Controller
attempt_incoming_connection(string host_ip_, string host_port_) (defined in Controller) Controller
attempt_outgoing_connection(string host_ip_, string host_port_) (defined in Controller) Controller
backlog_mutex (defined in Controller) Controller[protected]
bootstrap_from_tracker() (defined in Controller) Controller
change (defined in Controller) Controller[protected]
change_occured() (defined in Controller) Controller[inline]
check_backlog(xmlmap &xml_map) (defined in Controller) Controller
clear_tracker_data() (defined in Controller) Controller
comp_chunk_collection (defined in Controller) Controller
comp_chunks_we_have (defined in Controller) Controller[protected]
comp_chunks_we_want (defined in Controller) Controller[protected]
comp_torrent (defined in Controller) Controller
connect_mutex (defined in Controller) Controller
connected_peer_exists(string ip, string port) (defined in Controller) Controller
connected_peers (defined in Controller) Controller[protected]
connection_wait (defined in Controller) Controller[protected]
Controller(bool index, bool is_processing) (defined in Controller) Controller
create_working() (defined in Controller) Controller
debug_stats() (defined in Controller) Controller
decrement_num_incoming_connections() (defined in Controller) Controller[inline]
decrement_num_outgoing_connections() (defined in Controller) Controller[inline]
get_device_ip(string device) (defined in Controller) Controller[static]
get_ip() (defined in Controller) Controller[inline]
get_known_comp_chunks_xml(ostringstream &xml) (defined in Controller) Controller
get_known_orig_chunks_xml(ostringstream &xml) (defined in Controller) Controller
get_network_device() (defined in Controller) Controller[inline]
get_next_comp_chunk_mutex (defined in Controller) Controller
get_next_orig_chunk_mutex (defined in Controller) Controller
get_next_required_comp_chunk(file_chunk &f) (defined in Controller) Controller
get_next_required_orig_chunk(file_chunk &f) (defined in Controller) Controller
get_next_routing_id() (defined in Controller) Controller
get_num_comp_chunks() (defined in Controller) Controller[inline]
get_num_connections() (defined in Controller) Controller[inline]
get_num_incoming_connections() (defined in Controller) Controller[inline]
get_num_orig_chunks() (defined in Controller) Controller[inline]
get_num_outgoing_connections() (defined in Controller) Controller[inline]
get_port() (defined in Controller) Controller[inline]
CompTorrent: Member List
file:///C|/Users/stevensc/Desktop/Goldsmith/code/thesis_code/doxygen/html/classController-members.html[26/11/2014 1:14:32 PM]
get_tracker_url() (defined in Controller) Controller
have_comp_chunk(string chunkname) (defined in Controller) Controller
have_file(string chunkname, string filetype) (defined in Controller) Controller
have_orig_chunk(string chunkname) (defined in Controller) Controller
increment_num_incoming_connections() (defined in Controller) Controller[inline]
increment_num_outgoing_connections() (defined in Controller) Controller[inline]
index_node (defined in Controller) Controller[protected]
ip (defined in Controller) Controller[protected]
is_index() (defined in Controller) Controller[inline]
is_processing (defined in Controller) Controller[protected]
last_tracker_suggestion (defined in Controller) Controller[protected]
listener (defined in Controller) Controller[protected]
log(const ostringstream s) (defined in Controller) Controller[inline]
log(const string s) (defined in Controller) Controller[inline]
make_connection(string host_ip_, string host_port_) (defined in Controller) Controller
network_device (defined in Controller) Controller[protected]
next_route_id (defined in Controller) Controller[protected]
num_incoming_connections (defined in Controller) Controller[protected]
num_outgoing_connections (defined in Controller) Controller[protected]
num_required_comp_chunks() (defined in Controller) Controller[inline]
num_required_orig_chunks() (defined in Controller) Controller[inline]
orig_chunk_collection (defined in Controller) Controller
orig_chunks_we_have (defined in Controller) Controller[protected]
orig_chunks_we_want (defined in Controller) Controller[protected]
out_broadcast(string msg) (defined in Controller) Controller
parse_torrent(string file_path) (defined in Controller) Controller
parser_tracker_mutex (defined in Controller) Controller
peer_under_consideration(string ip, string port) (defined in Controller) Controller
peers_being_considered (defined in Controller) Controller[protected]
peers_considered_mutex (defined in Controller) Controller[protected]
port (defined in Controller) Controller[protected]
processor (defined in Controller) Controller
remove_connected_peer(string ip, string port) (defined in Controller) Controller
remove_considered_peer(string ip, string port) (defined in Controller) Controller
remove_required_comp_chunk(string chunk_name) (defined in Controller) Controller
remove_required_orig_chunk(string chunk_name) (defined in Controller) Controller
report_change(bool change_) (defined in Controller) Controller[inline]
request_backlog (defined in Controller) Controller[protected]
request_file(string chunkname, string filetype) (defined in Controller) Controller
router (defined in Controller) Controller[protected]
Router (defined in Controller) Controller[friend]
routing_id (defined in Controller) Controller[protected]
routing_set (defined in Controller) Controller[protected]
set_ip(string ip_) (defined in Controller) Controller[inline]
set_network_device(string my_device) (defined in Controller) Controller
set_port(string port_) (defined in Controller) Controller[inline]
set_routing_id(string routing_id_) (defined in Controller) Controller
set_tracker_url(string tracker_url_) (defined in Controller) Controller
start_distributed(string host_ip_, string host_port_) (defined in Controller) Controller
start_listener(string host_ip_, string host_port_) (defined in Controller) Controller
tracker (defined in Controller) Controller
tracker_url (defined in Controller) Controller[protected]
trim_spaces(std::string const &str) (defined in Controller) Controller[static]
CompTorrent: Member List
file:///C|/Users/stevensc/Desktop/Goldsmith/code/thesis_code/doxygen/html/classController-members.html[26/11/2014 1:14:32 PM]
waiting (defined in Controller) Controller[protected]
xml_to_map(const string xml, xmlmap &xml_map) Controller[static]
~Controller() (defined in Controller) Controller
CompTorrent: Alphabetical List
file:///C|/Users/stevensc/Desktop/Goldsmith/code/thesis_code/doxygen/html/classes.html[26/11/2014 1:14:32 PM] Main Page Classes Files
Class List Class Members
Class Index
A | C | F | K | L | M | N | O | P | R | T | W
A F Listener orig_data_chunk Router
AbstractPeer file_chunk M P T
C file_chunk_request MessageCollection peer TrackerParser
CompTorrentParser K N Processor W
CompTorrentPeer known_peer NetworkSocket R WorkerThread
Controller L O
A | C | F | K | L | M | N | O | P | R | T | W
file:///C|/Users/stevensc/Desktop/Goldsmith/code/thesis_code/doxygen/html/search/classes_63.html[26/11/2014 1:14:32 PM] CompTorrentParser
file:///C|/Users/stevensc/Desktop/Goldsmith/code/thesis_code/doxygen/html/search/classes_66.html[26/11/2014 1:14:33 PM] file_chunk
file:///C|/Users/stevensc/Desktop/Goldsmith/code/thesis_code/doxygen/html/search/classes_70.html[26/11/2014 1:14:33 PM] peer
CompTorrent: file_chunk Class Reference
file:///C|/Users/stevensc/Desktop/Goldsmith/code/thesis_code/doxygen/html/classfile__chunk.html[26/11/2014 1:14:34 PM] Main Page Classes Files
Class List Class Members
file_chunk Class Reference
List of all members.
Public Member Functions
file_chunk (string name_, string type_)
file_chunk & operator= (const file_chunk &rhs)
Public Attributes
string name string type
The documentation for this class was generated from the following file:
known_peer.h
CompTorrent: file_chunk_request Class Reference
file:///C|/Users/stevensc/Desktop/Goldsmith/code/thesis_code/doxygen/html/classfile__chunk__request.html[26/11/2014 1:14:34 PM] Main Page Classes Files
Class List Class Members
file_chunk_request Class Reference
List of all members.
Public Member Functions
file_chunk_request (string name_, string type_, void *who_)
file_chunk_request & operator= (const file_chunk_request &rhs)
Public Attributes
string name string type void * who
The documentation for this class was generated from the following file:
known_peer.h
CompTorrent: Member List
file:///C|/Users/stevensc/Desktop/Goldsmith/code/thesis_code/doxygen/html/classfile__chunk__request-members.html[26/11/2014 1:14:34 PM] Main Page Classes Files
Class List Class Members
file_chunk_request Member List
This is the complete list of members for file_chunk_request, including all inherited members. file_chunk_request(string name_, string type_, void *who_) (defined in
file_chunk_request) file_chunk_request[inline]
file_chunk_request() (defined in file_chunk_request) file_chunk_request[inline]
name (defined in file_chunk_request) file_chunk_request
operator=(const file_chunk_request &rhs) (defined in file_chunk_request) file_chunk_request[inline]
type (defined in file_chunk_request) file_chunk_request
who (defined in file_chunk_request) file_chunk_request
CompTorrent: Member List
file:///C|/Users/stevensc/Desktop/Goldsmith/code/thesis_code/doxygen/html/classfile__chunk-members.html[26/11/2014 1:14:35 PM] Main Page Classes Files
Class List Class Members
file_chunk Member List
This is the complete list of members for file_chunk, including all inherited members. file_chunk(string name_, string type_) (defined in file_chunk) file_chunk[inline]
file_chunk() (defined in file_chunk) file_chunk[inline]
name (defined in file_chunk) file_chunk
operator=(const file_chunk &rhs) (defined in file_chunk) file_chunk[inline]
type (defined in file_chunk) file_chunk
CompTorrent: Listener Class Reference
file:///C|/Users/stevensc/Desktop/Goldsmith/code/thesis_code/doxygen/html/classListener.html[26/11/2014 1:14:35 PM] Main Page Classes Files
Class List Class Members
Listener Class Reference
Collaboration diagram for Listener:
[legend]
List of all members.
Public Member Functions
Listener (Controller *parent_, string host_ip_, string host_port_) void run ()
Protected Attributes
string host_ip string host_port
Controller * parent
The documentation for this class was generated from the following files:
listener.h
listener.cpp
Listener
Controller listenerparent
CompTorrentParser parent
Router parent
Processor parent
TrackerParser
parent comp_torrent known_peer
last_tracker_suggestion
my_peer_record
Listener
Controller listenerparent
CompTorrentParser parent
Router parent
Processor parent
TrackerParser
parent comp_torrent known_peer
last_tracker_suggestion
my_peer_record
CompTorrent: Member List
file:///C|/Users/stevensc/Desktop/Goldsmith/code/thesis_code/doxygen/html/classListener-members.html[26/11/2014 1:14:39 PM] Main Page Classes Files
Class List Class Members
Listener Member List
This is the complete list of members for Listener, including all inherited members.
host_ip (defined in Listener) Listener[protected]
host_port (defined in Listener) Listener[protected]
Listener(Controller *parent_, string host_ip_, string host_port_) (defined in Listener)Listener[inline]
parent (defined in Listener) Listener[protected]
run() (defined in Listener) Listener
CompTorrent: MessageCollection Class Reference
file:///C|/Users/stevensc/Desktop/Goldsmith/code/thesis_code/doxygen/html/classMessageCollection.html[26/11/2014 1:14:39 PM] Main Page Classes Files
Class List Class Members
MessageCollection Class Reference
List of all members.
Public Member Functions
void push_back (const string) void push_front (const string) bool pop (string &)
collection_iter begin () collection_iter end ()
void clear () unsigned long size ()
Private Attributes
collection_type collection
Mutex collection_mutex int num_items
The documentation for this class was generated from the following files:
messagecollection.h
messagecollection.cpp