First public contribution.
2 * Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies).
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".
9 * Initial Contributors:
10 * Nokia Corporation - initial contribution.
15 * Name : serialstream.h
16 * Part of : stdio server
17 * To handle the read and write on serial(comm)
24 #ifndef _SERIALSTREAM_H_
25 #define _SERIALSTREAM_H_
27 #include "StdioServer.h"
28 #include "streambase.h" //CStreamBase2
29 #include "ReadRequestHandler.h" //CReadRequestHandler
31 //-----------------------------------------------------------------------
32 //Class name: CSerialStream
33 //Description: This class represents the serial stream.
34 //-----------------------------------------------------------------------
36 class CSerialStream : public CStreamBase
39 static CSerialStream* NewL(TInt aBaudRate,TDesC& aPortName);
40 virtual void WriteL(TDes8& aDes);
41 virtual void Read(TRequestStatus& aStatus, const TInt aLength);
43 virtual void ReadCancel();
44 TStreamType Type() { return ESerial;}
47 CSerialStream(TInt aBaudRate,TDesC& aPortName);
52 TSerialInfo iPortInfo;
57 #endif //_SERIALSTREAM_H_