Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
senf
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
wiback
senf
Commits
eae8e345
Commit
eae8e345
authored
17 years ago
by
g0dil
Browse files
Options
Downloads
Patches
Plain Diff
PPI: Small documentation fix
parent
f5682e3f
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
PPI/SocketReader.hh
+17
-13
17 additions, 13 deletions
PPI/SocketReader.hh
PPI/SocketWriter.hh
+9
-1
9 additions, 1 deletion
PPI/SocketWriter.hh
with
26 additions
and
14 deletions
PPI/SocketReader.hh
+
17
−
13
View file @
eae8e345
...
...
@@ -74,22 +74,26 @@ namespace module {
/** \brief Input module reading data from an arbitrary FileHandle
This input module will read data from a FileHandle object and parse the data according to
the \a Reader.
The \a Reader must fulfill the following interface
:
the \a Reader.
The default reader is senf::ppi::PacketReader <> which reads the data into a
senf::DataPacket. To parse the data according to some other packet type, pass that packet
type to senf::ppi::PacketReader
:
\code
class SomeReader
{
public:
typedef unspecified_type Handle; // type of handle requested
SomeReader(); // default constructible
Packet operator()(Handle handle); // extraction function
};
senf::ppi::module::ActiveSocketReader< senf::ppi::PacketReader<senf::EthernetPacket> > reader;
\endcode
declares a \a reader module reading senf::EthrtnetPacket's.
A \a Reader must fulfill the following interface:
\code
class SomeReader
{
public:
typedef unspecified_type Handle; // type of handle requested
SomeReader(); // default constructible
Packet operator()(Handle handle); // extraction function
};
\endcode
Whenever the FileHandle object is ready for reading, the \a Reader's \c operator() is called
to read a packet. The default \a Reader is \c PacketReader<>, which will read packets from a
datagram SocketHandle into DataPacket's. You may
to read a packet.
\ingroup io_modules
*/
...
...
This diff is collapsed.
Click to expand it.
PPI/SocketWriter.hh
+
9
−
1
View file @
eae8e345
...
...
@@ -73,7 +73,10 @@ namespace module {
output module is active. This requires the file handle to be able to signal its readiness to
accept more data via the Scheduler.
The \a Writer must fulfill the following interface:
The default \a Writer is senf::ppi::PacketWriter which will write out the complete packet to
the file handle.
A \a Writer must fulfill the following interface:
\code
class SomeWriter
{
...
...
@@ -83,6 +86,7 @@ namespace module {
void operator()(Handle handle, Packet packet); // insertion function
};
\endcode
Whenever a packet is received for sending, the \a Writer's \c operator() is called.
\ingroup io_modules
*/
...
...
@@ -115,6 +119,9 @@ namespace module {
mechanism. Either this is desired (like for a UDP socket) or some additional bandwidth
shaping needs to be used.
The default \a Writer is senf::ppi::PacketWriter which will write out the complete packet to
the file handle.
The \a Writer must fulfill the following interface:
\code
class SomeWriter
...
...
@@ -125,6 +132,7 @@ namespace module {
void operator()(Handle handle, Packet packet); // insertion function
};
\endcode
Whenever a packet is received for sending, the \a Writer's \c operator() is called.
\ingroup io_modules
*/
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment