// -----------------------------------------------------------------------------
// CHWRMExtendedLightStatusObserver::RunL
// Handle notification from pubsub session.
// -----------------------------------------------------------------------------
//
void CHWRMExtendedLightStatusObserver::RunL()
    {
    COMPONENT_TRACE1(_L( "HWRM ExtendedLightClient - CHWRMExtendedLightStatusObserver::RunL()" ));

    // Reorder notification
    OrderNotification();

    // get value from pubsub
    RLightStatusArray statusArray( KHWRMLightMaxTargets );
    CleanupClosePushL( statusArray );
    TInt err = InitializeStatusArray( statusArray );
    if( err == KErrNone )
        {
        TInt arraySize = sizeof( THWRMStatusInfo ) * KHWRMLightMaxTargets;
        TPtr8 arrayPtr( ( TUint8* )&statusArray[0], arraySize, arraySize );
        err = iProperty.Get( arrayPtr );
    if ( err == KErrNotFound || err == KErrNone )
        {
            NotifyCallback( statusArray );
            }
        }
    
    else
        {
        COMPONENT_TRACE2(_L( "HWRM ExtendedLightClient - CHWRMExtendedLightStatusObserver::RunL. Error (%d) in iProperty.Get()" ), err);
        NotifyCallback(iStatusUnknownList );
        }
        
    CleanupStack::PopAndDestroy( &statusArray );
    User::LeaveIfError( err );

    COMPONENT_TRACE1(_L( "HWRM ExtendedLightClient - CHWRMExtendedLightStatusObserver::RunL - return" ) );
    }
/**
 * Processes incoming OST messages
 */
void DTraceCoreOstLddIf::ReceiveDfc()
    {
    // Determine the message we received
    if ( iReceiveBuffer.Length() > OstHeader::OstBaseProtocol::KOstHeaderLengthOffset )
        {
        DebugPrintMsg ( iReceiveBuffer );
        if ( iCallback != NULL )
            {
            NotifyCallback();
            }
        }
    }