Poco::Zeroconf

class EventLoop

Library: Zeroconf
Package: ZeroCore
Header: Poco/Zeroconf/EventLoop.h

Description

The EventLoop class monitors all sockets created by Zeroconf, if new data is available on them. It is automatically started with the DNSServiceDiscovery singleton and is stopped when DNSServiceDiscovery::shutdown() is called.

Inheritance

Direct Base Classes: Poco::Runnable

All Base Classes: Poco::Runnable

Member Summary

Member Functions: add, remove, run, shutdown, stop

Inherited Functions: run

Constructors

EventLoop

EventLoop();

Creates the EventLoop.

Destructor

~EventLoop virtual

~EventLoop();

Destroys the EventLoop.

Member Functions

add

void add(
    DNSServiceRef ref
);

Adds the reference to the eventloop, monitoring it for data.

remove

void remove(
    DNSServiceRef ref
);

Removes and destroys the DNSServiceRef.

run virtual

void run();

Implements Poco::Runnable: here the monitoring of the socket happens

See also: Poco::Runnable::run()

shutdown

void shutdown();

Clears all members, frees all DNSServiceRefs

stop inline

void stop();

Tells the object to stop monitoring. Once stopped the EvenLoop cannot be restarted.