flow  3.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Pages
Public Member Functions | Friends | List of all members
flow::outpin< T > Class Template Reference

Object that represents a node outlet. More...

#include <node.h>

Inheritance diagram for flow::outpin< T >:
Inheritance graph
[legend]
Collaboration diagram for flow::outpin< T >:
Collaboration graph
[legend]

Public Member Functions

 outpin (const std::string &name_r)
 
virtual std::string rename (const std::string &name_r)
 Overrides named::rename.
 
virtual bool push (std::unique_ptr< packet< T >> packet_p)
 Moves a packet to the pipe.
 
- Public Member Functions inherited from flow::pin< T >
 pin (const std::string &name_r)
 
 pin (const pin< T > &o)
 
- Public Member Functions inherited from flow::named
 named (const std::string &name_r)
 Constructor the takes a name.
 
 named (named &&name_rr)
 Move constructor.
 
 named (const named &name_r)
 Copy constructor.
 
virtual const std::string & name () const
 A const reference to this object's name.
 

Friends

class producer< T >
 

Additional Inherited Members

- Protected Attributes inherited from flow::pin< T >
std::shared_ptr< std::pair
< pipe< T >, std::unique_ptr
< std::mutex > > > 
d_pipe_sp
 Shared ownership of a pipe with the pin to which this pin is connected.
 

Detailed Description

template<typename T>
class flow::outpin< T >

Object that represents a node outlet.

Nodes that produce packets, i.e. producers and transformers, have at least one outpin.

Constructor & Destructor Documentation

template<typename T>
flow::outpin< T >::outpin ( const std::string &  name_r)
inline
Parameters
name_rThe name to give this outpin.

Member Function Documentation

template<typename T>
virtual std::string flow::outpin< T >::rename ( const std::string &  name_r)
inlinevirtual

Overrides named::rename.

Ensures pipe is also renamed.

Parameters
name_rNew name to give this outpin.

Reimplemented from flow::named.

template<typename T>
virtual bool flow::outpin< T >::push ( std::unique_ptr< packet< T >>  packet_p)
inlinevirtual

Moves a packet to the pipe.

Attempts to move the packet on the pipe. If the pipe has reached capacity, the call to pipe::push will fail and packet_p will remain valid.

Returns
true if the packet was successfully moved to the pipe, false otherwise.

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