IToiDlnaRendererManager Interface Reference


Description

Technical Preview:

interface IToiDlnarendererManager is a TECHNICAL PREVIEW, it may change.

This is an interface to the DLNA DMR (Digital Media Renderer) manager, which is running as a platform service. The DMR manager handles the communication between the DMC and DMR, and sends the relevant requests to the application. The application uses this manager to register for DMR events, specifically media render requests and media render closing. The application then may open the required resource, and notify the DMR manager to continue with the rendering, or deny the request and not render.

import "IToiDlnaRendererManager.idl";

List of all members.

Public Member Functions

void UpdateSessionStatus (in TToiRendererSessionId id, in TToiRendererStatus status) raises (TToiInvalidArgumentException)
void GetSessionInfo (in TToiRendererSessionId id, out TToiRendererSessionInfo info) raises (TToiInvalidArgumentException)
void GetRendererSessions (out TToiRendererSessionIdSequence ids)
void ReleaseInstance ()
void RegisterObserver (in IToiApplicationService::TToiApplicationId applicationId, in string address) raises (TToiInvalidArgumentException)
void ReleaseObserver (in string address) raises (TToiInvalidArgumentException)

Classes

struct  TToiRendererSessionInfo

Public Types

enum  TToiRendererState { STATE_SESSION_REQUEST, STATE_SESSION_ACTIVE, STATE_SESSION_CLOSED }
enum  TToiRendererStatus { RENDERER_SUCCESS, RENDERER_UNAVAILABLE, RENDERER_FAILURE }
typedef long TToiRendererSessionId
typedef sequence
< TToiRendererSessionId
TToiRendererSessionIdSequence

Member Typedef Documentation

Type for a renderer session ID.

Type for holding a sequence of renderer session ID's.


Member Enumeration Documentation

State identifier used to identify the renderer session's state.

Enumerator:
STATE_SESSION_REQUEST 

In STATE_SESSION_REQUEST the DMR has issued a request to begin rendering and is waiting for an update to begin or close the rendering session.

STATE_SESSION_ACTIVE 

In STATE_SESSION_ACTIVE the DMR is actively rendering the requested session.

STATE_SESSION_CLOSED 

In STATE_SESSION_CLOSED the DMR has closed the given session. This can occur at the end of media, an error in rendering, or from an update from the application.

Status identifiers for a DMR session.

Enumerator:
RENDERER_SUCCESS 

RENDERER_SUCCESS notifies the DMR the request to render was successful.

RENDERER_UNAVAILABLE 

RENDERER_UNAVAILABLE notifies the DMR the request to render failed, or the currently rendering media must close, because the renderer is unavailable.

RENDERER_FAILURE 

RENDERER_FAILURE notifies the DMR the request to render failed, or the currently rendering media must close, because of an external failure.


Member Function Documentation

void IToiDlnaRendererManager::GetRendererSessions ( out TToiRendererSessionIdSequence  ids  ) 

Retreives all the session id's in REQUEST or ACTIVE states

Return values:
ids The list of active session ids.
void IToiDlnaRendererManager::GetSessionInfo ( in TToiRendererSessionId  id,
out TToiRendererSessionInfo  info 
) raises (TToiInvalidArgumentException)

Retreives all the information associated with the current media being rendered for the session id provided.

Parameters:
id The session ID associated with the media in question.
Return values:
info The information associated with the given session id.
Exceptions:
TToiInvalidArgumentException Raised if the session id is invalid.
void IToiDlnaRendererManager::RegisterObserver ( in IToiApplicationService::TToiApplicationId  applicationId,
in string  address 
) raises (TToiInvalidArgumentException)

Register an observer of type IToiDlnaRendererObserver. The observer will receive events sent by this IToiDlnaRendererManager instance.

Parameters:
applicationId The identifier of the observing application.
address The address where the IToiDlnaRendererManager can find an IToiDlnaRendererObserver 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:
IToiDlnaRendererObserver
void IToiDlnaRendererManager::ReleaseInstance (  ) 

When an application is done using the Renderer Manager it should gracefully release it by calling this function.

void IToiDlnaRendererManager::ReleaseObserver ( in string  address  )  raises (TToiInvalidArgumentException)

Release an observer previously registered with RegisterObserver.

Parameters:
address The address where the IToiDlnaRendererManager can find the registered IToiDlnaRendererObserver interface.
Exceptions:
TToiInvalidArgumentException Raised if the specified address is invalid.
See also:
IToiDlnaRendererObserver
void IToiDlnaRendererManager::UpdateSessionStatus ( in TToiRendererSessionId  id,
in TToiRendererStatus  status 
) raises (TToiInvalidArgumentException)

Notifies the DMR of an update to the session. This typically will occur when 1, we just received a request, so we will activate a session (if successful) or notify a failure to renderer (if unsuccessful); 2, if the rendering resouce becomes unavailable during rendering; or 3, for any other error while rendering. This may cause a change in State, from REQUEST to ACTIVE (on successful REQUEST), from REQUEST to CLOSED (on unsuccessful REQUEST), or from ACTIVE to CLOSED (on error or resource unavailability).

Parameters:
id The session ID being updated.
status The status for this session's action.
Exceptions:
TToiInvalidArgumentException Raised if the session id is invalid, or the status is invalid for the state of the session.