Yate: Capture Class Reference

Yate

Public Member Functions | List of all members
Capture Class Referenceabstract

Packet capture class. More...

`#include <yateclass.h>`

Inheritance diagram for Capture:

## Public Member Functions
| Capture (const char *name)
virtual bool | initialize (const NamedList &params)=0
virtual bool | write (const uint8_t *data, unsigned int len, const CaptureInfo &info)=0
virtual bool | valid () const =0
virtual const String & | name () const
Public Member Functions inherited from RefObject
| RefObject ()
virtual | ~RefObject ()
virtual void * | getObject (const String &name) const
virtual bool | alive () const
bool | ref ()
bool | deref ()
int | refcount () const
virtual void | destruct ()
Public Member Functions inherited from GenObject
| GenObject ()
virtual | ~GenObject ()
virtual const String & | toString () const
virtual const String & | traceId () const
NamedCounter * | getObjCounter () const
NamedCounter * | setObjCounter (NamedCounter *counter)

## Additional Inherited Members
Static Public Member Functions inherited from RefObject
static bool | alive (const RefObject *obj)
static bool | efficientIncDec ()
Static Public Member Functions inherited from GenObject
static void * | getObject (const String &name, const GenObject *obj)
static bool | getObjCounting ()
static void | setObjCounting (bool enable)
static NamedCounter * | getObjCounter (const String &name, bool create=true)
static ObjList & | getObjCounters ()
Protected Member Functions inherited from RefObject
virtual void | zeroRefs ()
bool | resurrect ()
virtual void | destroyed ()

## Detailed Description

Packet capture class.

Capture class allows implementing capturing of packets

## Constructor & Destructor Documentation

## ◆ Capture()

Capture | ( | const char * | name | ) |
| inline

Constructor

Parameters

  name | Name of capture

## Member Function Documentation

## ◆ initialize()

virtual bool initialize | ( | const NamedList & | params | ) |
| pure virtual

Initialize this capture

Parameters

  params | Parameters for initializing this capture

Returns
  True on succesful initialization, false otherwise

## ◆ name()

virtual const String & name | ( |  | ) | const
| inlinevirtual

Get the name of the capture

Returns
  Name of the capture

## ◆ valid()

virtual bool valid | ( |  | ) | const
| pure virtual

Check if capture is still valid

Returns
  True if still valid, false otherwise

## ◆ write()

virtual bool write | ( | const uint8_t * | data,
|  | unsigned int | len,
|  | const CaptureInfo & | info )
| pure virtual

Write to capture a packet

Parameters

  data | Packet data
  len | Length of packet data
  info | Captured packet associated information

Returns
  True if written in capture, false otherwise

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

- yateclass.h