Implementation of content loader that connects to Content Manager in Kanzi Connect server. More...
#include <default_content_loader.hpp>
Public Member Functions | |
bool | connectUsingUnreliableBearer () |
Determines whether this content loader will (eventually) connect using unreliable bearer. | |
DefaultContentLoader (ClientSharedPtr client) | |
Constructor. | |
InterfaceDomain * | getDomain () const |
Return access to server interfaces. | |
shared_ptr< p2p::RoutingRules::Endpoint > | getP2PEndpoint () |
Retrieve associated P2P endpoint. | |
string | getUri () const |
const string & | runtimeSubscribedToService () const |
const string & | runtimeSubscriptionWaitsService () const |
void | setP2PEndpoint (shared_ptr< p2p::RoutingRules::Endpoint > endpoint) |
void | stopBecauseServiceVanished () |
Stop because the bound service vanished. | |
virtual | ~DefaultContentLoader () override |
Destructor. | |
virtual void | start (ContentQueryArgumentsSharedPtr args) override |
virtual void | startRuntime (const string uri, int credits, int creditReturnInterval) override |
Starts runtime loading of data from a specific address. | |
virtual void | stop () override |
Function to stop / cancel the tracking process. | |
![]() | |
void | addObserver (Observer *observer) |
Subscribe to content notification callbacks. | |
ContentLoader () | |
Constructor. | |
void | removeObserver (Observer *observer) |
Unsubscribe from content notification callbacks. | |
virtual | ~ContentLoader ()=default |
dtor | |
Protected Member Functions | |
void | startRuntimeSubscription (const string &uri) |
void | startSubscription (ContentQueryArgumentsSharedPtr args) |
void | stopSubscription () |
![]() | |
void | notifyContentInvalidated () |
Invoke observer callback when previously loaded content is invalidated. | |
void | notifyContentLoaded (ContentResult *result) |
Invoke observer callback when new content result is received. | |
void | notifyRuntimeDataUpdateReceived (const string &uri, const string &stream) |
Implementation of content loader that connects to Content Manager in Kanzi Connect server.
kanzi::connect::DefaultContentLoader::DefaultContentLoader | ( | ClientSharedPtr | client | ) |
Constructor.
client | Access to server, message dispatcher and task queue |
|
overridevirtual |
Destructor.
bool kanzi::connect::DefaultContentLoader::connectUsingUnreliableBearer | ( | ) |
Determines whether this content loader will (eventually) connect using unreliable bearer.
InterfaceDomain * kanzi::connect::DefaultContentLoader::getDomain | ( | ) | const |
Return access to server interfaces.
|
inline |
Retrieve associated P2P endpoint.
|
inline |
|
inline |
|
inline |
|
inline |
|
overridevirtual |
Implements kanzi::connect::ContentLoader.
|
overridevirtual |
Starts runtime loading of data from a specific address.
uri | the uri where from to load. |
credits | total amount of transfer credits. |
creditReturnInterval | after how many received packets credits are returned to sender. |
Implements kanzi::connect::ContentLoader.
|
protected |
|
protected |
|
overridevirtual |
Function to stop / cancel the tracking process.
Implements kanzi::connect::ContentLoader.
void kanzi::connect::DefaultContentLoader::stopBecauseServiceVanished | ( | ) |
Stop because the bound service vanished.
|
protected |