Kodi Documentation 22.0
Kodi is an open source media player and entertainment hub.
Loading...
Searching...
No Matches
PVR::UTILS Namespace Reference

Functions

bool HasClientAndProvider (const std::string &path)
 Check whether the given path contains a client id and a provider id.
 
bool GetClientAndProviderFromPath (const CURL &url, int &clientId, int &providerId)
 Get client id and provider id from the given URL.
 
std::string GetProviderNameFromPath (const std::string &path)
 Get the name of a provider from the given path.
 

Function Documentation

◆ GetClientAndProviderFromPath()

bool PVR::UTILS::GetClientAndProviderFromPath ( const CURL & url,
int & clientId,
int & providerId )

Get client id and provider id from the given URL.

Parameters
urlThe URL.
clientIdFilled with the client id on success, PVR_CLIENT_INVALID_UID otherwise
providerIdFilled with the provider id on success, PVR_PROVIDER_INVALID_UID otherwise
Returns
True on success, false otherwise.

◆ GetProviderNameFromPath()

std::string PVR::UTILS::GetProviderNameFromPath ( const std::string & path)

Get the name of a provider from the given path.

Parameters
pathThe path.
Returns
the name on success, an empty string otherwise.

◆ HasClientAndProvider()

bool PVR::UTILS::HasClientAndProvider ( const std::string & path)

Check whether the given path contains a client id and a provider id.

Parameters
pathThe path.
Returns
True if both client id and provider id are present, false otherwise.