CUpnpDispatcher Class Reference
class CUpnpDispatcher : public CBase
|
This class represents a logical unit between UPnP devices / control points and Message Handler. Message Handler is a Symbian Server - thus, dispatcher follows the same client/server framework and is a client that opens a session to Message Handler. This is not done by class
CUpnpDispatcher
; the class RUpnpDispatcherSession represents the client interface.
Using AddCustomer/RemoveCustomer functions it is possible to set the active services. Dispatcher is able to forward messages to its customers.
Also SendMessage function is very essential part of the dispatcher.
Public Member Functions
|
|
~CUpnpDispatcher
()
|
IMPORT_C void
|
AddCustomer
(const
MUpnpDispatcherCustomer
&)
|
IMPORT_C void
|
AddCustomerL
(const
MUpnpDispatcherCustomer
&,
TBool
)
|
IMPORT_C void
|
AddLocalDeviceL
(const
TDesC8
&, const
TDesC8
&, const
TDesC8
&, const
CDesC8Array
&, const
TBool
)
|
void
|
DeviceListReceivedL
(
TInt
)
|
IMPORT_C
TInetAddr
|
HttpServerAddress
()
|
const
HBufC8
*
|
MacAddressL
()
|
IMPORT_C
CUpnpDispatcher
*
|
NewL
(
MUpnpDiscoveryObserver
*)
|
IMPORT_C
CUpnpDispatcher
*
|
NewLC
(
MUpnpDiscoveryObserver
*)
|
IMPORT_C void
|
RemoveCustomer
(const
MUpnpDispatcherCustomer
&)
|
IMPORT_C void
|
RemoveCustomer
(const
MUpnpDispatcherCustomer
&,
TBool
)
|
void
|
RemoveLocalDeviceL
(const
TDesC8
&,
TBool
)
|
IMPORT_C void
|
SearchL
(const
TDesC8
&)
|
IMPORT_C void
|
SearchL
(const
TDesC16
&)
|
IMPORT_C void
|
SendMessageL
(CUpnpHttpMessage *,
MUpnpDispatcherCustomer
&,
TBool
)
|
void
|
SetTransactionCreator
(MUpnpHttpServerTransactionCreator *)
|
IMPORT_C void
|
StartHttpServerL
(
TBool
, const
TInt
)
|
IMPORT_C void
|
StartIPFilteringL
()
|
IMPORT_C void
|
StopFilteringL
(const
TDesC8
&)
|
IMPORT_C void
|
StopHttpServer
()
|
IMPORT_C void
|
StopIPFiltering
()
|
IMPORT_C void
|
UpdateDevicesL
(
TInt
)
|
Constructor & Destructor Documentation
CUpnpDispatcher(MUpnpDiscoveryObserver *)
~CUpnpDispatcher()
IMPORT_C
|
~CUpnpDispatcher
|
(
|
)
|
[virtual]
|
Destroy the object and release all memory objects
Member Functions Documentation
AddCustomer(const MUpnpDispatcherCustomer &)
Add a customer to the customer list of this dispatcher. In practice, means that messages start being forwarded to that customer.
AddCustomerL(const MUpnpDispatcherCustomer &, TBool)
Add a customer to the customer list of this dispatcher. In practice, means that messages start being forwarded to that customer.
AddLocalDeviceL(const TDesC8 &, const TDesC8 &, const TDesC8 &, const CDesC8Array &, const TBool)
IMPORT_C void
|
AddLocalDeviceL
|
(
|
const
TDesC8
&
|
aUuid,
|
|
const
TDesC8
&
|
aDeviceType,
|
|
const
TDesC8
&
|
aDescriptionPath,
|
|
const
CDesC8Array
&
|
aServices,
|
|
const
TBool
|
aIsRootDevice
|
|
)
|
|
Adds a local device to Message Handler's device library.
Parameters
const
TDesC8
& aUuid
|
UUID of the device.
|
const
TDesC8
& aDeviceType
|
Device type of the device (e.g MediaServer:1)
|
const
TDesC8
& aDescriptionPath
|
URL to device description.
|
const
CDesC8Array
& aServices
|
List of services this device provides.
|
const
TBool
aIsRootDevice
|
ETrue, if this device is UPnP root device, \ EFalse otherwise.
|
ConstructL()
void
|
ConstructL
|
(
|
)
|
[private]
|
ConstructL
Perform the second phase construction of a
CUpnpDispatcher
object
DeviceListReceivedL(TInt)
void
|
DeviceListReceivedL
|
(
|
TInt
|
aUpdateId
|
)
|
[virtual]
|
HttpServerAddress()
IMPORT_C
TInetAddr
|
HttpServerAddress
|
(
|
)
|
|
Returns HTTP server address.
MacAddressL()
const
HBufC8
*
|
MacAddressL
|
(
|
)
|
|
Returns an active interface's Hardware (MAC) address.
NewL(MUpnpDiscoveryObserver *)
Create a
CUpnpDispatcher
object using two phase construction, and return a pointer to the created object.
A session with Message Handler is initiated during the construction.
NewLC(MUpnpDiscoveryObserver *)
Create a
CUpnpDispatcher
object using two phase construction, and return a pointer to the created object
A session with Message Handler is initiated during the construction.
RemoveCustomer(const MUpnpDispatcherCustomer &)
Remove a customer from the customer list of this dispatcher. In practice, means that messages stop being forwarded to that customer.
RemoveCustomer(const MUpnpDispatcherCustomer &, TBool)
Remove a customer from the customer list of this dispatcher. In practice, means that messages stop being forwarded to that customer.
RemoveLocalDeviceL(const TDesC8 &, TBool)
void
|
RemoveLocalDeviceL
|
(
|
const
TDesC8
&
|
aUuid,
|
|
TBool
|
aSilent
|
|
)
|
|
Removes a local device from Message Handler's device library.
Parameters
const
TDesC8
& aUuid
|
UUID of the device that is to be removed.
|
TBool
aSilent
|
|
SearchL(const TDesC8 &)
IMPORT_C void
|
SearchL
|
(
|
const
TDesC8
&
|
aSearchString
|
)
|
|
Sends a SSDP Search with 8-bit searchString.
Parameters
const
TDesC8
& aSearchString
|
String to use in SSDP ST -header.
|
SearchL(const TDesC16 &)
IMPORT_C void
|
SearchL
|
(
|
const
TDesC16
&
|
aSearchString
|
)
|
|
Sends a SSDP Search with 16-bit searchString. This method makes a conversion to 8-bit and then makes the search
Parameters
const
TDesC16
& aSearchString
|
Stfing to use in SSDP ST -header.
|
SendMessageL(CUpnpHttpMessage *, MUpnpDispatcherCustomer &, TBool)
Send a message. This function pushes the message to the Message Handler.
Parameters
CUpnpHttpMessage * aMessage
|
The message to be sent.
|
MUpnpDispatcherCustomer
& aCustomer
|
|
TBool
aIsLocal = EFalse
|
ETrue if is local device, else EFalse if device is local, then action will be send without network layeraMessage has to be EAction type.
|
SetTransactionCreator(MUpnpHttpServerTransactionCreator *)
void
|
SetTransactionCreator
|
(
|
MUpnpHttpServerTransactionCreator *
|
aTransactionCreator
|
)
|
|
Sets handle to transaction creator interface.
-
Since
-
Series60 5.0
Parameters
MUpnpHttpServerTransactionCreator * aTransactionCreator
|
pointer to object implementing MUpnpHttpServerTransactionCreator interface.
|
StartHttpServerL(TBool, const TInt)
IMPORT_C void
|
StartHttpServerL
|
(
|
TBool
|
aRegister,
|
|
const
TInt
|
aPort
|
|
)
|
|
Parameters
TBool
aRegister
|
determines if starting error in message handler process will be checked
|
const
TInt
aPort
|
starts server on fixed port
|
StartIPFilteringL()
IMPORT_C void
|
StartIPFilteringL
|
(
|
)
|
|
StopFilteringL(const TDesC8 &)
IMPORT_C void
|
StopFilteringL
|
(
|
const
TDesC8
&
|
aUuids
|
)
|
|
Sends a stop filtering request. Device notification will not be stoped in ssdp.
StopHttpServer()
IMPORT_C void
|
StopHttpServer
|
(
|
)
|
|
StopIPFiltering()
IMPORT_C void
|
StopIPFiltering
|
(
|
)
|
|
UpdateDevicesL(TInt)
IMPORT_C void
|
UpdateDevicesL
|
(
|
TInt
|
aNewId
|
)
|
|
Informs upper layers about newly found devices.
Parameters
TInt
aNewId
|
New update id that needs to be stored.
|
Member Enumerations Documentation
Member Data Documentation
CUpnpDispatcherEngine * iEngine
CUpnpDispatcherEngine *
|
iEngine
|
[private]
|
MUpnpDiscoveryObserver * iParent
Copyright ©2010 Nokia Corporation and/or its subsidiary(-ies).
All rights
reserved. Unless otherwise stated, these materials are provided under the terms of the Eclipse Public License
v1.0.