IToiPlatformService Interface Reference


Description

The Platform Service contains functions for rebooting, standby and factory reset.

import "IToiPlatformService.idl";

List of all members.

Public Member Functions

void RebootNow ()
void RebootAtNextStandby ()
void SetStandby (in boolean mode)
void FactoryReset (in long flags) raises (TToiOperationNotSupportedException)
void RegisterComponentUsage (in IToiApplicationService::TToiApplicationId applicationId, in string componentName, out boolean active) raises (TToiInvalidArgumentException, TToiInvalidPreconditionException)
void ReleaseComponentUsage (in IToiApplicationService::TToiApplicationId applicationId, in string componentName, out boolean active) raises (TToiInvalidArgumentException, TToiInvalidPreconditionException)
void GetComponentsInfo (out TToiComponentInfoSequence infoSequence)
void GetComponentInfo (in string componentName, out TToiComponentInfo info) raises (TToiInvalidArgumentException)
void RegisterObserver (in IToiApplicationService::TToiApplicationId applicationId, in string address) raises (TToiInvalidArgumentException)
void ReleaseObserver (in string address) raises (TToiInvalidArgumentException)

Classes

struct  TToiComponentInfo

Public Types

enum  TToiResetFlag {
  REFORMAT_INTERNAL_HDD, REMOVE_PERSISTENT_COOKIES, REMOVE_PORTAL_DATABASES, REMOVE_PERSISTENT_INFORMATION_OBJECTS,
  RESET_TR069_DATA_MODEL, CUSTOM_POST_PROCEDURE, REMOVE_CHANNELS, FULL_RESET
}
enum  TToiComponentState { COMPONENT_STATE_INACTIVE, COMPONENT_STATE_PENDING_INACTIVE, COMPONENT_STATE_PENDING_ACTIVE, COMPONENT_STATE_ACTIVE }
typedef sequence
< TToiComponentInfo
TToiComponentInfoSequence

Member Typedef Documentation

A sequence of component information.


Member Enumeration Documentation

The state describing a dynamic component.

Enumerator:
COMPONENT_STATE_INACTIVE 

The dynamic component is inactive with no resources allocated.

COMPONENT_STATE_PENDING_INACTIVE 

The dynamic component has been deactivated and is releasing its resources and is not yet ready to be activated again.

COMPONENT_STATE_PENDING_ACTIVE 

The dynamic component has been activated and is allocating its initial resources but is not yet ready for use.

COMPONENT_STATE_ACTIVE 

The dynamic component is active and ready for use.

The reset flag indicates which parts of the STB that shall be reset when a factory reset is performed.

Enumerator:
REFORMAT_INTERNAL_HDD 

Reformat the internal HDD.

REMOVE_PERSISTENT_COOKIES 

Remove all persistent cookies for SVG and HTML browsers.

REMOVE_PORTAL_DATABASES 

Remove all portal databases. Currently only affects the HTML browser for which the HTML5 database is removed.

REMOVE_PERSISTENT_INFORMATION_OBJECTS 

Remove all persistent InformationService variables.

RESET_TR069_DATA_MODEL 

Reset the TR-069 data model.

CUSTOM_POST_PROCEDURE 

Execute custom script/procedures. This is done after any other reset actions.

REMOVE_CHANNELS 
Technical Preview:
The flag REMOVE_CHANNELS is a TECHNICAL PREVIEW, it may change. Remove the channel database.
FULL_RESET 

Perform a full factory reset.


Member Function Documentation

void IToiPlatformService::FactoryReset ( in long  flags  )  raises (TToiOperationNotSupportedException)

Perform factory reset. Which parts of the persistent storage that is reset to factory state is dependent on which flags that are given to the function call. After the reset is perform, the STB will reboot to ensure that it boots up in a factory reset state.

Parameters:
flags Flags indicating which parts to reset.
See also:
TToiResetFlag.
Exceptions:
TToiOperationNotSupportedException Raised if some error occured.
void IToiPlatformService::GetComponentInfo ( in string  componentName,
out TToiComponentInfo  info 
) raises (TToiInvalidArgumentException)
Technical Preview:
This method is a TECHNICAL PREVIEW, it may change.

Returns information for a platform component.

Parameters:
componentName The name of the dynamic component.
Return values:
info Component information.
Exceptions:
TToiInvalidArgumentException Raised if the component name is not valid.
void IToiPlatformService::GetComponentsInfo ( out TToiComponentInfoSequence  infoSequence  ) 
Technical Preview:
This method is a TECHNICAL PREVIEW, it may change.

Returns information of available platform components.

Return values:
infoSequence A sequence of component information.
void IToiPlatformService::RebootAtNextStandby (  ) 

Reboot the platform the next time the system goes from active to standby state. This is used for starting a new boot image in a way that is less disturbing to the end user.

void IToiPlatformService::RebootNow (  ) 

Reboot the platform immediately in a controlled way. This is useful to force the usage of a new boot image after upgrade.

void IToiPlatformService::RegisterComponentUsage ( in IToiApplicationService::TToiApplicationId  applicationId,
in string  componentName,
out boolean  active 
) raises (TToiInvalidArgumentException, TToiInvalidPreconditionException)
Technical Preview:
This method is a TECHNICAL PREVIEW, it may change.

Registers interest in a dynamic component. If not already active this method activates the dynamic component with the given identifier. The calling application should register itself as an IToiPlatformObserver and listen to IToiPlatformObserver::OnComponentInfoChanged() to know when the component is activated. If the component has already been activated by another user (indicated by the active flag) no event will be sent.

See also:
IToiPlatformObserver
Parameters:
applicationId The identifier of the calling application.
componentName The name of the dynamic component.
Return values:
active A flag indicating if the component is already active, i.e. no need to wait for an active state event.
Exceptions:
TToiInvalidArgumentException Raised if the component name is not valid.
TToiInvalidPreconditionException Raised if the component is in state COMPONENT_STATE_PENDING_INACTIVE.
void IToiPlatformService::RegisterObserver ( in IToiApplicationService::TToiApplicationId  applicationId,
in string  address 
) raises (TToiInvalidArgumentException)

Register an observer of type IToiPlatformObserver. The observer will receive events sent by this IToiPlatformService instance.

Parameters:
applicationId The identifier of the observing application.
address The address where the IToiPlatformService can find an IToiPlatformObserver 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:
IToiPlatformObserver
void IToiPlatformService::ReleaseComponentUsage ( in IToiApplicationService::TToiApplicationId  applicationId,
in string  componentName,
out boolean  active 
) raises (TToiInvalidArgumentException, TToiInvalidPreconditionException)
Technical Preview:
This method is a TECHNICAL PREVIEW, it may change.

Releases interest in a dynamic component with the given identifier. All resources allocated by the dynamic component will be released when it becomes inactive. If another user still has interest in the component it will not be deactivated (indicated by the active flag).

See also:
IToiPlatformObserver
Parameters:
applicationId The identifier of the calling application.
componentName The name of the dynamic component.
Return values:
active A flag indicating if the component is still active after release due to another user, i.e. the component will be inactivated only when all users have released the component.
Exceptions:
TToiInvalidArgumentException Raised if the component name is not valid.
TToiInvalidPreconditionException Raised if the user has not called IToiPlatformService::RegisterComponentUsage().
void IToiPlatformService::ReleaseObserver ( in string  address  )  raises (TToiInvalidArgumentException)

Release an observer previously registered with RegisterObserver.

Parameters:
address The address where the IToiPlatformService can find the registered IToiPlatformObserver interface.
Exceptions:
TToiInvalidArgumentException Raised if the specified address is invalid.
See also:
IToiPlatformObserver
void IToiPlatformService::SetStandby ( in boolean  mode  ) 

Enter or leave standby. In standby all video and audio outputs are disabled. Applications are stopped or left running depending on the system configuration. If the system is already in the requested mode the call will have no effect.

Parameters:
mode The requested mode. True corresponds to standby, while false corresponds to normal operation.