videofeeds/server/IptvScheduledDownload/inc/iptvvodscheduleddownloadscheduler.h
changeset 0 96612d01cf9f
equal deleted inserted replaced
-1:000000000000 0:96612d01cf9f
       
     1 /*
       
     2 * Copyright (c) 2006-2007 Nokia Corporation and/or its subsidiary(-ies).
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of the License "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description:    Scheduled download scheduler.*
       
    15 */
       
    16 
       
    17 
       
    18 
       
    19 
       
    20 #ifndef CIPTVVODSCHEDULEDDOWNLOADSCHEDULER_H
       
    21 #define CIPTVVODSCHEDULEDDOWNLOADSCHEDULER_H
       
    22 
       
    23 //  INCLUDES
       
    24 #include <e32base.h>
       
    25 #include "CIptvUtil.h"
       
    26 #include "iptvvodscheduleddownloaddefinitions.h"
       
    27 #include "CIptvServiceManager.h"
       
    28 #include "MIptvServiceManagerObserver.h"
       
    29 
       
    30 // CONSTANTS
       
    31 
       
    32 // CLASS DECLARATION
       
    33 class CCseScheduledProgram;
       
    34 class CCseSchedulerApi;
       
    35 class CIptvVODScheduledDownloadActiveScheduler;
       
    36 
       
    37 /**
       
    38 *  Scheduled download scheduler. This class handles the calculating new
       
    39 *  schedules to the CSE when settings have been changed.
       
    40 *
       
    41 *  @lib IptvServer.exe
       
    42 *  @since 
       
    43 */
       
    44 NONSHARABLE_CLASS ( CIptvVODScheduledDownloadScheduler ) :
       
    45             public CBase,
       
    46             public MIptvServiceManagerObserver
       
    47     {
       
    48     public:  // Constructors and destructor
       
    49         
       
    50         /**
       
    51         * Two-phased constructor.
       
    52         * @param aAppUid The application uid to use.
       
    53         */
       
    54         static CIptvVODScheduledDownloadScheduler* NewL(
       
    55                     CIptvServiceManager& aServiceManager );
       
    56         
       
    57         /**
       
    58         * Destructor.
       
    59         */
       
    60         virtual ~CIptvVODScheduledDownloadScheduler( );
       
    61 
       
    62     public: // From MIptvServiceManagerObserver
       
    63 
       
    64         void HandleSmEvent( CIptvSmEvent& aEvent );
       
    65 
       
    66     public: // New methods
       
    67 
       
    68         /**
       
    69         * Remove the active from our list,
       
    70         * it has done its work and is going to selfdestruct.
       
    71         *
       
    72         * @param aActive The active to remove.
       
    73         */
       
    74         void RemoveActive( CIptvVODScheduledDownloadActiveScheduler* aActive );
       
    75 
       
    76     private:
       
    77 
       
    78         /**
       
    79         * C++ constructor.
       
    80         *
       
    81         * @param aServiceManager The service manager.
       
    82         */
       
    83         CIptvVODScheduledDownloadScheduler(
       
    84                     CIptvServiceManager& aServiceManager );
       
    85 
       
    86         /**
       
    87         * By default Symbian 2nd phase constructor is private.
       
    88         */
       
    89         void ConstructL();
       
    90 
       
    91         /**
       
    92         * Implementation of the MIptvServiceManagerObserver::HandleSmEvent
       
    93         *
       
    94         * @param aEvent the event to handle.
       
    95         */
       
    96         void HandleSmEventL( CIptvSmEvent& aEvent );
       
    97 
       
    98     private:
       
    99 
       
   100         /**
       
   101         * The service manager.
       
   102         */
       
   103         CIptvServiceManager& iServiceManager;
       
   104 
       
   105         /**
       
   106         * A list containing the scheduling objects. Owned.
       
   107         */
       
   108         RPointerArray<CIptvVODScheduledDownloadActiveScheduler>
       
   109                 iActiveSchedulers;
       
   110     };
       
   111 
       
   112 #endif      // CIPTVVODSCHEDULEDDOWNLOADSCHEDULER_H
       
   113             
       
   114 // End of File