ED2KPacket::FileDesc Class Reference

FileDesc packet contains the rating and the comment of the file. More...

#include <packets.h>

Inheritance diagram for ED2KPacket::FileDesc:

ED2KPacket::Packet List of all members.

Public Member Functions

 FileDesc (ED2KFile::Rating rating, const std::string &comment)
 FileDesc (std::istream &i)
 operator std::string ()
std::string getComment () const
ED2KFile::Rating getRating () const

Private Attributes

ED2KFile::Rating m_rating
 Rating.
std::string m_comment
 Comment.

Detailed Description

FileDesc packet contains the rating and the comment of the file.

It is used as reply to ReqFile packet, along with FileName packet, and only sent if the file does have a rating/comment set, thus it is optional. Note that this packet does not contain the hash of the file.

Definition at line 603 of file packets.h.


Constructor & Destructor Documentation

ED2KPacket::FileDesc::FileDesc ED2KFile::Rating  rating,
const std::string &  comment
 

Definition at line 824 of file packets.cpp.

ED2KPacket::FileDesc::FileDesc std::istream &  i  ) 
 

Definition at line 826 of file packets.cpp.

References m_comment, and m_rating.


Member Function Documentation

ED2KPacket::FileDesc::operator std::string  ) 
 

Definition at line 831 of file packets.cpp.

References m_comment, m_rating, ED2KPacket::Packet::makePacket(), and OP_FILEDESC.

std::string ED2KPacket::FileDesc::getComment  )  const [inline]
 

Definition at line 609 of file packets.h.

References m_comment.

ED2KFile::Rating ED2KPacket::FileDesc::getRating  )  const [inline]
 

Definition at line 610 of file packets.h.

References m_rating.


Member Data Documentation

ED2KFile::Rating ED2KPacket::FileDesc::m_rating [private]
 

Rating.

Definition at line 612 of file packets.h.

Referenced by FileDesc(), getRating(), and operator std::string().

std::string ED2KPacket::FileDesc::m_comment [private]
 

Comment.

Definition at line 613 of file packets.h.

Referenced by FileDesc(), getComment(), and operator std::string().


The documentation for this class was generated from the following files: