1 // Copyright (c) 1997-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".
8 // Initial Contributors:
9 // Nokia Corporation - initial contribution.
14 // This file contains the header file of the Sms socket Buffers.
23 #if !defined (__SMSUSTRM_H__)
24 #define __SMSUSTRM_H__
26 #if !defined(__E32STD_H__)
30 #if !defined(__S32BUF_H__)
34 #if !defined(__S32STRM_H__)
45 const TInt KSmsMaxSegmentLength=0x100;
49 * An SMS stream buffer to read and write over a socket.
53 class RSmsSocketBuf : public TStreamBuf
56 RSmsSocketBuf(RSocket& aSocket);
59 TInt UnderflowL(TInt aMaxLength);
65 inline TInt Lag(TRead) const;
66 inline TInt Lag(TWrite) const;
69 TUint8 iBuffer[KSmsMaxSegmentLength];
74 * Stream that reads a CSmsMessage object across a socket.
78 class RSmsSocketReadStream : public RReadStream
81 IMPORT_C RSmsSocketReadStream(RSocket& aSocket);
87 * Stream that writes a CSmsMessage object across a socket.
91 class RSmsSocketWriteStream : public RWriteStream
94 IMPORT_C RSmsSocketWriteStream(RSocket& aSocket);
99 #include "smsustrm.inl"
101 #endif // !defined __SMSUSTRM_H__