1/***************************************************************************
2 * Copyright (C) 2009 by Rahman Duran <rahman.duran@gmail.com> *
3 * *
4 * This program is free software; you can redistribute it and/or modify *
5 * it under the terms of the GNU General Public License as published by *
6 * the Free Software Foundation; either version 2 of the License, or *
7 * (at your option) any later version. *
8 * *
9 * This program is distributed in the hope that it will be useful, *
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of *
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
12 * GNU General Public License for more details. *
13 * *
14 * You should have received a copy of the GNU General Public License *
15 * along with this program; if not, write to the *
16 * Free Software Foundation, Inc., *
17 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA *
18 ***************************************************************************/
19
20#ifndef KDE_TERMINAL_INTERFACE_V2_H
21#define KDE_TERMINAL_INTERFACE_V2_H
22
23/**
24 * TerminalInterfaceV2 is an extension to TerminalInterface that implemented
25 * by KonsolePart to allow developers access to the KonsolePart in ways that are not
26 * possible through the normal KPart interface.
27 *
28 * @author Rahman Duran <rahman.duran@gmail.com>
29 */
30#include <kde_terminal_interface.h>
31
32class TerminalInterfaceV2: public TerminalInterface
33{
34public:
35 virtual ~TerminalInterfaceV2(){}
36
37 /**
38 * Return terminal PID
39 */
40 virtual int terminalProcessId() = 0;
41
42 /**
43 * Return foregound PID, If there is no foreground process running, returns -1
44 */
45 virtual int foregroundProcessId() = 0;
46
47 /**
48 * Returns sub process name. If there is no sub process running, returns empty QString
49 */
50 virtual QString foregroundProcessName() = 0;
51
52
53};
54
55Q_DECLARE_INTERFACE(TerminalInterfaceV2, "org.kde.TerminalInterfaceV2")
56#endif
57