harvester/harvesterserver/inc/charvesterserversession.h
changeset 0 671dee74050a
equal deleted inserted replaced
-1:000000000000 0:671dee74050a
       
     1 /*
       
     2 * Copyright (c) 2010 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: 
       
    15 *
       
    16 */
       
    17 
       
    18 #ifndef CHARVESTERSERVERSESSION_H
       
    19 #define CHARVESTERSERVERSESSION_H
       
    20 
       
    21 // INCLUDE FILES
       
    22 #include <e32base.h>
       
    23 
       
    24 // CLASS DECLARATION
       
    25 /**
       
    26  * CHarvesterServerSession.
       
    27  *  An instance of class CHarvesterServerSession is created for each client.
       
    28  */
       
    29 class CHarvesterServerSession : public CSession2
       
    30 	{
       
    31 	public: // Constructors and destructors		
       
    32 	
       
    33 		/**
       
    34 		 * NewL.
       
    35 		 * Two-phased constructor.
       
    36 		 * @return Pointer to created CHarvesterServerSession object.
       
    37 		 */
       
    38 		static CHarvesterServerSession* NewL();
       
    39 	
       
    40 		/**
       
    41 		 * NewLC.
       
    42 		 * Two-phased constructor.
       
    43 		 * @return Pointer to created CHarvesterServerSession object.
       
    44 		 */
       
    45 		static CHarvesterServerSession* NewLC();
       
    46 	
       
    47 		/**
       
    48 		 * ~CHarvesterServerSession.
       
    49 		 * Destructor.
       
    50 		 */
       
    51 		virtual ~CHarvesterServerSession();
       
    52 
       
    53 	public: // Functions from base classes
       
    54 	
       
    55 
       
    56 		/**
       
    57 		 * From CSession, ServiceL.
       
    58 		 * Service request from client.
       
    59 		 * @param aMessage Message from client
       
    60 		 *                 (containing requested operation and any data).
       
    61 		 */
       
    62 		void ServiceL(const RMessage2& aMessage);
       
    63 
       
    64 	private: // Constructors and destructors
       
    65 		
       
    66 	
       
    67 		/**
       
    68 		 * CHarvesterServerSession.
       
    69 		 * C++ default constructor.
       
    70 		 * @param aServer The server.
       
    71 		 */
       
    72 		CHarvesterServerSession();
       
    73 	
       
    74 		/**
       
    75 		 * ConstructL.
       
    76 		 * 2nd phase constructor.
       
    77 		 */
       
    78 		void ConstructL();
       
    79 
       
    80 	private: // New methods
       
    81 				
       
    82 		/**
       
    83 		 * PanicClient.
       
    84 		 * Causes the client thread to panic.
       
    85 		 * @param aMessage Message from client.
       
    86 		 * @param aPanic Panic code.
       
    87 		 */
       
    88 		void PanicClient(const RMessage2& aMessage, TInt aPanic) const;
       
    89 
       
    90 	private: // Data
       
    91 		
       
    92 		// No data
       
    93 	};
       
    94 
       
    95 #endif // CHARVESTERSERVERSESSION_H
       
    96 
       
    97 // End of File