KDevelop API Documentation

dbgcommand.h

Go to the documentation of this file.
00001 /***************************************************************************
00002     begin                : Sun Aug 8 1999
00003     copyright            : (C) 1999 by John Birch
00004     email                : jbb@kdevelop.org
00005  ***************************************************************************/
00006 
00007 /***************************************************************************
00008  *                                                                         *
00009  *   This program is free software; you can redistribute it and/or modify  *
00010  *   it under the terms of the GNU General Public License as published by  *
00011  *   the Free Software Foundation; either version 2 of the License, or     *
00012  *   (at your option) any later version.                                   *
00013  *                                                                         *
00014  ***************************************************************************/
00015 
00016 #ifndef DBGCOMMAND_H
00017 #define DBGCOMMAND_H
00018 
00019 #include <qstring.h>
00020 
00025 namespace GDBDebugger
00026 {
00027 
00028 class DbgCommand
00029 {
00030 public:
00031     DbgCommand(const QCString& command, bool isRunCmd, bool isInfoCmd, char prompt);
00032     virtual ~DbgCommand() {};
00033 
00034     virtual QCString& cmdToSend()             { sent_ = true;  return cmdBuffer_; }
00035     virtual int cmdLength()                   { return cmdBuffer_.length(); }
00036 
00037     QCString rawDbgCommand() const            { return command_; }
00038     bool isARunCmd() const                    { return isRunCmd_;}
00039     bool isAnInfoCmd() const                  { return isInfoCmd_; }
00040     bool moreToSend() const                   { return !sent_; }
00041     bool expectReply() const                  { return waitForReply_; }
00042     bool typeMatch(char cmdType) const        { return (prompt_ == cmdType); }
00043 
00044 protected:
00045     QCString cmdBuffer_;
00046     QCString command_;
00047     bool    isRunCmd_;
00048     bool    isInfoCmd_;
00049     bool    sent_;
00050     bool    waitForReply_;
00051     char    prompt_;
00052 };
00053 
00054 }
00055 
00056 /***************************************************************************/
00057 /***************************************************************************/
00058 /***************************************************************************/
00059 
00060 #endif
KDE Logo
This file is part of the documentation for KDevelop Version 3.1.2.
Documentation copyright © 1996-2004 the KDE developers.
Generated on Tue Feb 22 09:22:29 2005 by doxygen 1.3.9.1 written by Dimitri van Heesch, © 1997-2003