IToiDlnaService Interface Reference


Description

This is the main interface which the DLNA service registers with the system's name service. The interface is used by applications to access the DLNA network and create their own DLNA service control point instances.

The typical procedure to set up a control point session and communicate with a service in another DLNA device looks like this:

Interface Procedure
IToiDlnaService
IToiDlnaContentDirectoryService
IToiOperationManager
IToiDlnaContentDirectoryService::TToiCdsObject
  • Read object data and properties.
See also:
IToiDlnaContentDirectoryService
IToiOperationManager
IToiOperationObserver::OnOperationResult()
IToiDlnaContentDirectoryObserver::OnContainerChanged()
IToiDlnaObserver::OnMediaServerAppeared()
IToiDlnaObserver::OnMediaServerDisappeared()

import "IToiDlnaService.idl";

List of all members.

Public Member Functions

void GetMediaServers (out TToiMediaServerUuidSequence uuids)
void GetMediaServerInfo (in TToiMediaServerUuid uuid, out TToiMediaServerInfo info) raises (TToiInvalidArgumentException)
void CreateContentDirectoryInstance (in IToiApplicationService::TToiApplicationId applicationId, in TToiMediaServerUuid uuid, out string address) raises (TToiInvalidArgumentException, TToiNotEnoughResourcesException, TToiOperationNotSupportedException)
void CreateRendererInstance (in IToiApplicationService::TToiApplicationId applicationId, out string address) raises (TToiInvalidArgumentException, TToiNotEnoughResourcesException, TToiOperationNotSupportedException)
void RegisterObserver (in IToiApplicationService::TToiApplicationId applicationId, in string address) raises (TToiInvalidArgumentException)
void ReleaseObserver (in string address) raises (TToiInvalidArgumentException)

Classes

struct  TToiMediaServerIconInfo
struct  TToiMediaServerInfo

Public Types

enum  TToiServiceType { SERVICE_TYPE_CONTENT_DIRECTORY }
enum  TToiMediaFormatProfile { MEDIA_FORMAT_PROFILE_JPEG_LRG_ICO, MEDIA_FORMAT_PROFILE_JPEG_SM_ICO, MEDIA_FORMAT_PROFILE_PNG_LRG_ICO, MEDIA_FORMAT_PROFILE_PNG_SM_ICO }
typedef string TToiMediaServerUuid
typedef sequence
< TToiMediaServerUuid
TToiMediaServerUuidSequence
typedef sequence< TToiServiceTypeTToiServiceTypeSequence
typedef sequence
< TToiMediaServerIconInfo
TToiMediaServerIconInfoSequence

Member Typedef Documentation

A sequence of DLNA icons.

Universally unique identifier of a DLNA media server.

Sequence of unique DLNA media server identifiers.

A sequence of DLNA service types.


Member Enumeration Documentation

The DLNA media format profiles.

Enumerator:
MEDIA_FORMAT_PROFILE_JPEG_LRG_ICO 

Large JPEG icon: size 120x120 pixels, MIME type "image/jpeg".

MEDIA_FORMAT_PROFILE_JPEG_SM_ICO 

Small JPEG icon: size 48x48 pixels, MIME type "image/jpeg".

MEDIA_FORMAT_PROFILE_PNG_LRG_ICO 

Large PNG icon: size 120x120 pixels, MIME type "image/png".

MEDIA_FORMAT_PROFILE_PNG_SM_ICO 

Small PNG icon: size 48x48 pixels, MIME type "image/png".

The different kinds of DLNA services exposed by DLNA media servers.

Enumerator:
SERVICE_TYPE_CONTENT_DIRECTORY 

The Content Directory Service used to browse and search for media files.


Member Function Documentation

void IToiDlnaService::CreateContentDirectoryInstance ( in IToiApplicationService::TToiApplicationId  applicationId,
in TToiMediaServerUuid  uuid,
out string  address 
) raises (TToiInvalidArgumentException, TToiNotEnoughResourcesException, TToiOperationNotSupportedException)

This function creates a new Content Directory Service control point for a specific DLNA media server and associates it with the calling application.

When the application no longer needs the service, it should release it by calling IToiDlnaContentDirectoryService::ReleaseInstance().

Parameters:
applicationId The application identifier of the calling application.
uuid The DLNA media server identifier.
Return values:
address The address to the Content Directory Service interface.
Exceptions:
TToiInvalidArgumentException Raised if the application identifier is invalid.
TToiNotEnoughResourcesException Raised if the system cannot create a new instance of the service.
TToiOperationNotSupportedException Raised if the DLNA server does not support the Content Directory Service.
void IToiDlnaService::CreateRendererInstance ( in IToiApplicationService::TToiApplicationId  applicationId,
out string  address 
) raises (TToiInvalidArgumentException, TToiNotEnoughResourcesException, TToiOperationNotSupportedException)
Technical Preview:
method CreateRendererInstance is a TECHNICAL PREVIEW, it may change. This function creates a new DLNA Media Renderer Manager for control via an external DMC. This also notifies the internal DLNA stack there is a renderer available. When the application no longer needs the service, it should release it by calling IToiDlnaRendererManager::ReleaseInstance()
Parameters:
applicationId The application identifier of the calling application.
Return values:
address The address to the Dlna Renderer Manager interface.
Exceptions:
TToiInvalidArgumentException Raised if the application identifier is invalid.
TToiNotEnoughResourcesException Raised if the system cannot create a new instance of the manager.
TToiOperationNotSupportedException Raised if the platform does not support the Dlna Renderer manager.
void IToiDlnaService::GetMediaServerInfo ( in TToiMediaServerUuid  uuid,
out TToiMediaServerInfo  info 
) raises (TToiInvalidArgumentException)

Returns a list with device identifiers for the DLNA devices present in the network.

Parameters:
uuid The DLNA media server identifier.
Return values:
info The DLNA media server information.
Exceptions:
TToiInvalidArgumentException Raised if the uuid does not match any DLNA server.
void IToiDlnaService::GetMediaServers ( out TToiMediaServerUuidSequence  uuids  ) 

Returns a list with device identifiers for the DLNA devices present in the network.

Return values:
uuids The DLNA media server uuid identifiers.
void IToiDlnaService::RegisterObserver ( in IToiApplicationService::TToiApplicationId  applicationId,
in string  address 
) raises (TToiInvalidArgumentException)

Register an observer of type IToiDlnaObserver. The observer will receive events sent by this IToiDlnaService instance.

Parameters:
applicationId The identifier of the observing application.
address The address where the IToiDlnaService can find an IToiDlnaObserver interface.
Exceptions:
TToiInvalidArgumentException Raised if the specified address is invalid or if the application has already registered itself as an observer with the same address.
See also:
IToiDlnaObserver
void IToiDlnaService::ReleaseObserver ( in string  address  )  raises (TToiInvalidArgumentException)

Release an observer previously registered with RegisterObserver.

Parameters:
address The address where the IToiDlnaService can find the registered IToiDlnaObserver interface.
Exceptions:
TToiInvalidArgumentException Raised if the specified address is invalid.
See also:
IToiDlnaObserver