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 <<
72 "] serviceId [" << serviceId <<
73 "] SCPDURL [" << SCPDURL <<
74 "] controlURL [" << controlURL <<
75 "] eventSubURL [" << eventSubURL <<
85 std::string relatedVariable;
89 relatedVariable.clear();
96 std::vector<Argument> argList;
107 std::string dataType;
116 hasValueRange =
false;
123 std::unordered_map<std::string, Action> actionList;
124 std::unordered_map<std::string, StateVariable> stateTable;
132 bool fetchAndParseDesc(
const std::string& urlbase,
Parsed& parsed,
133 std::string *XMLText = 0)
const;
151 UPnPDeviceDesc(
const std::string& url,
const std::string& description);
185 std::string dump()
const {
186 std::ostringstream os;
187 os <<
"DEVICE " <<
" {deviceType [" << deviceType <<
188 "] friendlyName [" << friendlyName <<
190 "] URLBase [" << URLBase <<
"] Services:" << std::endl;
191 for (std::vector<UPnPServiceDesc>::const_iterator it = services.begin();
192 it != services.end(); it++) {
193 os <<
" " << it->dump();
195 for (
const auto& it: embedded) {
198 os <<
"}" << std::endl;
Service description as parsed from the service XML document: actions and state variables.
Definition: description.hxx:122
std::vector< UPnPServiceDesc > services
Services provided by this device.
Definition: description.hxx:175
std::string UDN
Unique Device Number.
Definition: description.hxx:163
std::string controlURL
Service control URL.
Definition: description.hxx:55
std::vector< UPnPDeviceDesc > embedded
Embedded devices.
Definition: description.hxx:180
std::string dump() const
Debug: return the basic parsed data as a string.
Definition: description.hxx:69
void clear()
Reset all data.
Definition: description.hxx:60
std::string serviceType
Service Type e.g. urn:schemas-upnp-org:service:ConnectionManager:1.
Definition: description.hxx:49
std::string manufacturer
Manufacturer: e.g. D-Link, PacketVideo.
Definition: description.hxx:167
std::string modelName
Model name: e.g. MediaTomb, DNS-327L.
Definition: description.hxx:169
std::string eventSubURL
Service event URL.
Definition: description.hxx:57
std::string friendlyName
User-configurable name (usually), e.g. Lounge-streamer.
Definition: description.hxx:160
std::string XMLText
Raw downloaded document.
Definition: description.hxx:172
std::string serviceId
Service Id inside device: e.g. urn:upnp-org:serviceId:ConnectionManager.
Definition: description.hxx:51
Description of an action argument: name, direction, state variable it relates to (which will yield th...
Definition: description.hxx:82
Holder for all the attributes of an UPnP service state variable.
Definition: description.hxx:104
Data holder for a UPnP service, parsed from the device XML description.
Definition: description.hxx:46
std::string SCPDURL
Service description URL.
Definition: description.hxx:53
Data holder for a UPnP device, parsed from the XML description obtained during discovery.
Definition: description.hxx:142
UPnP Description phase: interpreting the device description which we downloaded from the URL obtained...
Definition: avlastchg.cxx:27
std::string deviceType
Device Type: e.g. urn:schemas-upnp-org:device:MediaServer:1.
Definition: description.hxx:158
UPnP service action descriptor, from the service description document.
Definition: description.hxx:94
std::string URLBase
Base for all relative URLs. e.g. http://192.168.4.4:49152/.
Definition: description.hxx:165