The homepage contains the readme and the minitutorial with its output plus a screenshot from a tutorial run.
Back to sourceforge.net project main/download page.
jp scratchpad comes with an
executable jpython jar file jppad.jar, something
jpython -jar jppad.jar
should work to start it.
At the moment it is open for
posting for everyone.
I'm interested in constructive comments or critics (maybe destructive too ;))
otherwise I will never be able to improve it.
I will try to do my best effort also to answer to related problems and questions
trough the mailing list.
is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
-- Mini tutorial
-- One can evaluate simple python
statements. Try pressing Shift+Enter
on the next line.
-- Simple statement boundaries
are recognized. Try Shift+Enter on any
line of the following statement.
for i in range(1,4):
-- '--' starts comment/inactive
Shift+Enter on a statement invoke evaluation.
-- Multiple statements can be put together and executed at once
gathering them in a block starting with a '!' line and using
indentation. Let's do some cleanup. As before Shift-Enter
somewhere on it.
['__doc__', '__name__', 'i']
-- Some more features.
First execute this assignment
-- The output is None but you
still get an '>>ok' feedback.
Then try this block. Do not erase the output.
-- Now try to press Shift-Enter
on one of the output lines ('>>',' 4').
The statement is evaluated again and the output changed accordingly.
-- Error handling.
The next statement is not lexically correct. Try Shift-Enter.
^Lexical error at line 1, column 3. Encountered: "$" (36), after : ""
-- This is not syntactically
-- This statement should continue.
-- y is not defined raising
an exception. Try.
traceback (innermost last)
File "<!>", line 2, in ?
-- Line numbers make sense.
-- One can execute statements
in on-the-fly created modules.
-- Then try:
-- The default module is:
-- Unloading of java classes.
First one should set a path where unloadable classes are
located. This can be a set of directories and/or jar files and
must be disjoint from the usual classpath.
There is an escape command for this.
ex.: +dyn-class-path-append [...]/y [...]/x.jar
For the tutorial we need to reach the directory stuff/xper
of jppad installation. Modify the following as necessary and
execute it as always with Shift+Enter.
-- On Windows you need something like x:/jppad/stuff/xper
-- NOTE: The reloading/unloading
support for java classes is known to work
properly only under jdk/jre 1.3 !!! See the README file.
-- Notice: xper contains X.class, X.clazz and X.java-v0, X.java-v1
that are the source code for the two bytecode compiled classes.
Try the following.
-- With this esc command every
python-object defined in the session
is discarded and the java classes from the dyn-class-path are unloaded
-- Note: The dyn-class-path
remains valid and set.
In order to discard it too one should use
-- Now try the following. Modify
the first line as necessary.
Attached to this window there is a contextual popup with many
For example indent/dedent which operate on the selection.
Ctrl-I, Ctrl-D do the same.
Functions to include/export text from/to files (ev. filtering the
There is also an output window and the popup contains actions
for redirecting the various python or java err or out streams
here, to that window or to the console.
E.g. per default java System.err is redirected to the out-win.
from java.lang import System
traceback (innermost first)
File "<!>", line 2, in ?
Before trying this use the popup to redirect java out here.
xper should still be in the dyn-class-path.
import Y # from xper, the source is also there
import Z # from xper, the source is also there
** Y *
** Y *
-- The semantics of +dyn-reload
is a bit hackward.
It reloads all classes from the dyn-path, but no instances or
derived pyclasses should be around and only names at top-level
in every module can be bound to these classes and then get rebound
to the reloaded versions. If something fails you get a feedback
on the involved classes and you can fix it and issue a +retry.