os/persistentdata/traceservices/tracefw/ulogger/src/outfrwkchans/serial/uloggerserialplugin.h
author sl
Tue, 10 Jun 2014 14:32:02 +0200
changeset 1 260cb5ec6c19
permissions -rw-r--r--
Update contrib.
     1 // Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
     2 // All rights reserved.
     3 // This component and the accompanying materials are made available
     4 // under the terms of "Eclipse Public License v1.0"
     5 // which accompanies this distribution, and is available
     6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
     7 //
     8 // Initial Contributors:
     9 // Nokia Corporation - initial contribution.
    10 //
    11 // Contributors:
    12 //
    13 // Description:
    14 // ULogger serial plugin header file
    15 // 
    16 //
    17 
    18 /**
    19  @file
    20  @internalTechnology
    21  @prototype
    22 */
    23 
    24 #ifndef ULOGGERSERIALPLUGIN_H
    25 #define ULOGGERSERIALPLUGIN_H
    26 
    27 #include "uloggeroutputplugin.h"
    28 #include <d32comm.h> // RBusDevComm
    29 #include <c32comm.h>
    30 
    31 namespace Ulogger
    32 {
    33 class CSerialWriter : public CPlugin, public MOutputPlugin
    34 	{
    35 public:
    36 	static CSerialWriter* NewL();
    37 	~CSerialWriter();
    38 public://from MOutputPlugin
    39 	TInt ConfigureOutputPlugin(const RPointerArray<TPluginConfiguration>& aSettings);
    40 	TInt Write(const TDesC8& aData);
    41 	void CloseOutputPlugin();
    42 public: //from CPlugin
    43 	TAny* GetInterfaceL(TPluginInterface aInterfaceId);
    44 private:
    45 	CSerialWriter();
    46 	void ConstructL();
    47 	TInt Connect();
    48     TInt Config();
    49 	TInt Disconnect();
    50 private:
    51 	RBusDevComm iComm;
    52     TBool 		iReady;
    53 	TInt 		iPortNum;
    54 	};
    55 } // namespace
    56 
    57 #endif // ULOGGERSERIALPLUGIN_H