• Skip to content
  • Skip to link menu
  • KDE API Reference
  • kdelibs-4.14.38 API Reference
  • KDE Home
  • Contact Us
 

KHTML

  • khtml
  • java
kjavaprocess.h
Go to the documentation of this file.
1// -*- c++ -*-
2
3/* This file is part of the KDE project
4 *
5 * Copyright (C) 2000 Richard Moore <rich@kde.org>
6 * 2000 Wynn Wilkes <wynnw@caldera.com>
7 *
8 * This library is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU Library General Public
10 * License as published by the Free Software Foundation; either
11 * version 2 of the License, or (at your option) any later version.
12 *
13 * This library is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16 * Library General Public License for more details.
17 *
18 * You should have received a copy of the GNU Library General Public License
19 * along with this library; see the file COPYING.LIB. If not, write to
20 * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
21 * Boston, MA 02110-1301, USA.
22 */
23
24#ifndef KJAVAPROCESS_H
25#define KJAVAPROCESS_H
26
27#include <kprocess.h>
28
40class KJavaProcessPrivate;
41class KJavaProcess : public KProcess //QObject
42{
43Q_OBJECT
44
45public:
50 KJavaProcess( QObject *parent = 0 );
51 virtual ~KJavaProcess();
52
57 bool startJava();
58
62 void stopJava();
63
68 bool isRunning();
69
73 void setJVMPath( const QString& path );
74
82 void setClasspath( const QString& classpath );
83
88 void setSystemProperty( const QString& name, const QString& value );
89
93 void setMainClass( const QString& clazzName );
94
98 void setExtraArgs( const QString& args );
99
104 void setClassArgs( const QString& classArgs );
105
110 void send( char cmd_code, const QStringList& args );
111
117 void send( char cmd_code, const QStringList& args, const QByteArray& data );
118
122 void flushBuffers();
123
124protected Q_SLOTS:
130 void slotReceivedData();
134 void slotExited();
135
136protected:
137 virtual bool invokeJVM();
138 virtual void killJVM();
139
140 QByteArray addArgs( char cmd_code, const QStringList& args );
141 void storeSize( QByteArray* buff );
142
143Q_SIGNALS:
144 void received( const QByteArray& );
145 void exited( int status );
146
147private:
148 KJavaProcessPrivate* const d;
149
150};
151
152#endif // KJAVAPROCESS_H
KJavaProcess
Definition: kjavaprocess.h:42
KJavaProcess::slotExited
void slotExited()
This slot is called when the Java Process exited.
Definition: kjavaprocess.cpp:283
KJavaProcess::exited
void exited(int status)
KJavaProcess::setClasspath
void setClasspath(const QString &classpath)
This will set the classpath the Java process will use.
Definition: kjavaprocess.cpp:91
KJavaProcess::killJVM
virtual void killJVM()
Definition: kjavaprocess.cpp:239
KJavaProcess::setJVMPath
void setJVMPath(const QString &path)
Used to specify the path to the Java executable to be run.
Definition: kjavaprocess.cpp:86
KJavaProcess::setClassArgs
void setClassArgs(const QString &classArgs)
Arguments passed to the main class.
Definition: kjavaprocess.cpp:112
KJavaProcess::slotReceivedData
void slotReceivedData()
This slot is called when the Java Process writes to standard out.
Definition: kjavaprocess.cpp:248
KJavaProcess::received
void received(const QByteArray &)
KJavaProcess::stopJava
void stopJava()
Stop the JVM (if it's running).
Definition: kjavaprocess.cpp:81
KJavaProcess::send
void send(char cmd_code, const QStringList &args)
Sends a command to the KJAS Applet Server by building a QByteArray out of the data,...
Definition: kjavaprocess.cpp:164
KJavaProcess::~KJavaProcess
virtual ~KJavaProcess()
Definition: kjavaprocess.cpp:61
KJavaProcess::setMainClass
void setMainClass(const QString &clazzName)
The class to be called when startJava() is called.
Definition: kjavaprocess.cpp:102
KJavaProcess::setSystemProperty
void setSystemProperty(const QString &name, const QString &value)
Set a property on the java command line as -Dname=value, or -Dname if value is QString().
Definition: kjavaprocess.cpp:96
KJavaProcess::invokeJVM
virtual bool invokeJVM()
Definition: kjavaprocess.cpp:190
KJavaProcess::isRunning
bool isRunning()
Returns the status of the java Process- true if it's ok, false if it has died.
Definition: kjavaprocess.cpp:71
KJavaProcess::flushBuffers
void flushBuffers()
Writes all pending data to JVM.
KJavaProcess::startJava
bool startJava()
Invoke the JVM with the parameters that have been set.
Definition: kjavaprocess.cpp:76
KJavaProcess::storeSize
void storeSize(QByteArray *buff)
Definition: kjavaprocess.cpp:154
KJavaProcess::setExtraArgs
void setExtraArgs(const QString &args)
Extra flags passed to the JVM.
Definition: kjavaprocess.cpp:107
KJavaProcess::addArgs
QByteArray addArgs(char cmd_code, const QStringList &args)
Definition: kjavaprocess.cpp:118
KProcess
QObject
kprocess.h
name
const char * name(StandardAction id)
This file is part of the KDE documentation.
Documentation copyright © 1996-2023 The KDE developers.
Generated on Mon Feb 20 2023 00:00:00 by doxygen 1.9.6 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

KHTML

Skip menu "KHTML"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • File Members
  • Related Pages

kdelibs-4.14.38 API Reference

Skip menu "kdelibs-4.14.38 API Reference"
  • DNSSD
  • Interfaces
  •   KHexEdit
  •   KMediaPlayer
  •   KSpeech
  •   KTextEditor
  • kconf_update
  • KDE3Support
  •   KUnitTest
  • KDECore
  • KDED
  • KDEsu
  • KDEUI
  • KDEWebKit
  • KDocTools
  • KFile
  • KHTML
  • KImgIO
  • KInit
  • kio
  • KIOSlave
  • KJS
  •   KJS-API
  •   WTF
  • kjsembed
  • KNewStuff
  • KParts
  • KPty
  • Kross
  • KUnitConversion
  • KUtils
  • Nepomuk
  • Plasma
  • Solid
  • Sonnet
  • ThreadWeaver
Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal