photosgallery/collectionframework/thumbnailcreator/inc/glxtntask.inl
changeset 0 4e91876724a2
equal deleted inserted replaced
-1:000000000000 0:4e91876724a2
       
     1 /*
       
     2 * Copyright (c) 2008-2009 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 "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:    Base classes for multi-purpose tasks.
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 
       
    20 
       
    21 /**
       
    22  * @internal reviewed 30/07/2007 by Simon Brooks
       
    23  */
       
    24 
       
    25 // -----------------------------------------------------------------------------
       
    26 // SetPriority
       
    27 // Gets the current task specific state
       
    28 // -----------------------------------------------------------------------------
       
    29 //
       
    30 inline CGlxtnTask::TState CGlxtnTask::State() const
       
    31     {
       
    32     return iState;
       
    33     }
       
    34 
       
    35 // -----------------------------------------------------------------------------
       
    36 // SetPriority
       
    37 // Gets the type of task this is.
       
    38 // -----------------------------------------------------------------------------
       
    39 //
       
    40 inline TGlxtnTaskId CGlxtnTask::Id() const
       
    41     {
       
    42     return iId;
       
    43     }
       
    44 
       
    45 // -----------------------------------------------------------------------------
       
    46 // SetPriority
       
    47 // Gets the media ID of the item to which this task relates.
       
    48 // -----------------------------------------------------------------------------
       
    49 //
       
    50 inline TGlxMediaId CGlxtnTask::ItemId() const
       
    51     {
       
    52     return iItemId;
       
    53     }
       
    54 
       
    55 // -----------------------------------------------------------------------------
       
    56 // SetPriority
       
    57 // Sets the priority of the task. By default it is set to EPriorityStandard.
       
    58 // -----------------------------------------------------------------------------
       
    59 //
       
    60 inline void CGlxtnTask::SetPriority(TInt aPriority)
       
    61     {
       
    62     iPriority = aPriority;
       
    63     }
       
    64 
       
    65 // -----------------------------------------------------------------------------
       
    66 // Priority
       
    67 // Gets the task priority.
       
    68 // -----------------------------------------------------------------------------
       
    69 //
       
    70 inline TInt CGlxtnTask::Priority() const
       
    71     {
       
    72     return iPriority;
       
    73     }
       
    74 
       
    75 // -----------------------------------------------------------------------------
       
    76 // Storage
       
    77 // Get the thumbnail storage for this task to use, if any.
       
    78 // -----------------------------------------------------------------------------
       
    79 //
       
    80 inline MGlxtnThumbnailStorage* CGlxtnTask::Storage() const
       
    81     {
       
    82     return iStorage;
       
    83     }
       
    84 
       
    85 // -----------------------------------------------------------------------------
       
    86 // Client
       
    87 // Get the client for this task.
       
    88 // -----------------------------------------------------------------------------
       
    89 //
       
    90 inline MGlxtnThumbnailCreatorClient& CGlxtnClientTask::Client()
       
    91     {
       
    92     return iClient;
       
    93     }