add dox doc for header and trailer PrintTo and DoGetName

This commit is contained in:
Mathieu Lacage
2007-06-29 08:18:16 +02:00
parent 2756732458
commit bedbfd18d7
2 changed files with 26 additions and 0 deletions

View File

@@ -43,11 +43,24 @@ public:
private:
/**
* \returns a user-readable name to identify this type of header.
*
* The string returned is expected to be a single word with
* all capital letters
*/
virtual std::string DoGetName (void) const = 0;
/**
* \param os the std output stream in which this
* protocol header must print itself.
*
* Although the header is free to format its output as it
* wishes, it is recommended to follow a few rules to integrate
* with the packet pretty printer:
* - start with flags, small field values located between a
* pair of parens. Values should be separated by whitespace.
* - follow the parens with the important fields, separated by
* whitespace.
* i.e.:
* (field1 val1 field2 val2 field3 val3) field4 val4 field5 val5
*/
virtual void PrintTo (std::ostream &os) const = 0;

View File

@@ -69,11 +69,24 @@ public:
private:
/**
* \returns a user-readable name to identify this type of header.
*
* The string returned is expected to be a single word with
* all capital letters
*/
virtual std::string DoGetName (void) const = 0;
/**
* \param os the std output stream in which this
* protocol trailer must print itself.
*
* Although the header is free to format its output as it
* wishes, it is recommended to follow a few rules to integrate
* with the packet pretty printer:
* - start with flags, small field values located between a
* pair of parens. Values should be separated by whitespace.
* - follow the parens with the important fields, separated by
* whitespace.
* i.e.:
* (field1 val1 field2 val2 field3 val3) field4 val4 field5 val5
*/
virtual void PrintTo (std::ostream &os) const = 0;