diff -r 64b3172ba347 -r 3b92f7acdc91 localconnectivityservice/dun/atext/inc/DunAtSpecialCmdHandler.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/localconnectivityservice/dun/atext/inc/DunAtSpecialCmdHandler.h Sat Apr 24 00:43:26 2010 +0300 @@ -0,0 +1,76 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Special AT command handler +* +*/ + +#ifndef C_CDUNATSPECIALCMDHANDLER_H +#define C_CDUNATSPECIALCMDHANDLER_H + +#include +#include + +const TInt KInputBufLength = (512 + 1); // 512 chars for command + + +/** + * Class for special AT command handler + * + * @lib dunatext.lib + * @since S60 v5.0 + */ +NONSHARABLE_CLASS( CDunAtSpecialCmdHandler ) : public CBase + { + +public: + + /** + * Two-phased constructor. + * @param None + * @return Instance of self + */ + static CDunAtSpecialCmdHandler* NewL(); + + /** + * Destructor. + */ + ~CDunAtSpecialCmdHandler(); + +public: + + TBool IsCompleteSubCommand(TChar aCharacter); + TBool IsCompleteSubCommand(TDesC8& aDes, TInt aStartIndex, TInt& aEndIndex); + +private: + + CDunAtSpecialCmdHandler(); + + void ConstructL(); + + TBool IsDataReadyForComparison(TInt aLength); + TInt MinimumLength(); + + +private: // data + /** + * Buffer for temporary AT command input + */ + TBuf8 iBuffer; + + /** + * Special commands for parsing + */ + CDesC8Array *iSpecialCmds; + }; + +#endif // C_CDUNATSPECIALCMDHANDLER_H