18#ifndef _UPNPDEV_HXX_INCLUDED_
19#define _UPNPDEV_HXX_INCLUDED_
26#include <unordered_map>
31#include "libupnpp/upnppexports.hxx"
70 std::ostringstream os;
71 os <<
"SERVICE {serviceType [" << serviceType <<
"] serviceId [" << serviceId <<
72 "] SCPDURL [" << SCPDURL <<
"] controlURL [" << controlURL <<
"] eventSubURL [" <<
73 eventSubURL <<
"] }" <<
'\n';
82 std::string relatedVariable;
86 relatedVariable.clear();
93 std::vector<Argument> argList;
104 std::string dataType;
113 hasValueRange =
false;
120 std::unordered_map<std::string, Action> actionList;
121 std::unordered_map<std::string, StateVariable> stateTable;
129 bool fetchAndParseDesc(
const std::string& urlbase,
Parsed& parsed,
130 std::string *XMLText = 0)
const;
188 std::string dump()
const {
189 std::ostringstream os;
190 os <<
"DEVICE " <<
" {deviceType [" << deviceType <<
"] friendlyName [" << friendlyName <<
191 "] UDN [" << UDN <<
"] URLBase [" << URLBase <<
"] Services:" <<
'\n';
192 for (
const auto& service : services) {
193 os <<
" " << service.dump();
195 for (
const auto& it: embedded) {
Data holder for a UPnP device, parsed from the XML description obtained during discovery.
Definition description.hxx:139
std::string descURL
URL the device description XML was downloaded from.
Definition description.hxx:162
UPnPDeviceDesc(const std::string &url, const std::string &description)
Build device from the XML description downloaded during discovery.
std::string XMLText
Raw downloaded document.
Definition description.hxx:175
std::string URLBase
scheme:authority/ part of the descURL above, e.g.
Definition description.hxx:168
std::string UDN
Unique Device Number.
Definition description.hxx:160
std::vector< UPnPServiceDesc > services
Services provided by this device.
Definition description.hxx:178
std::string friendlyName
User-configurable name (usually), e.g. Lounge-streamer.
Definition description.hxx:157
std::string manufacturer
Manufacturer: e.g. D-Link, PacketVideo.
Definition description.hxx:170
std::vector< UPnPDeviceDesc > embedded
Embedded devices.
Definition description.hxx:183
std::string deviceType
Device Type: e.g. urn:schemas-upnp-org:device:MediaServer:1.
Definition description.hxx:155
std::string modelName
Model name: e.g. MediaTomb, DNS-327L.
Definition description.hxx:172
Data holder for a UPnP service, parsed from the device XML description.
Definition description.hxx:46
std::string serviceType
Service Type e.g. urn:schemas-upnp-org:service:ConnectionManager:1.
Definition description.hxx:49
std::string SCPDURL
Service description URL.
Definition description.hxx:53
std::string controlURL
Service control URL.
Definition description.hxx:55
std::string dump() const
Debug: return the basic parsed data as a string.
Definition description.hxx:69
std::string eventSubURL
Service event URL.
Definition description.hxx:57
void clear()
Reset all data.
Definition description.hxx:60
std::string serviceId
Service Id inside device: e.g. urn:upnp-org:serviceId:ConnectionManager.
Definition description.hxx:51
UPnP Description phase: interpreting the device description which we downloaded from the URL obtained...
Definition avlastchg.cxx:28
UPnP service action descriptor, from the service description document.
Definition description.hxx:91
Description of an action argument: name, direction, state variable it relates to (which will yield th...
Definition description.hxx:79
Service description as parsed from the service XML document: actions and state variables.
Definition description.hxx:119
Holder for all the attributes of an UPnP service state variable.
Definition description.hxx:101