File: Changes.html

package info (click to toggle)
bsh 1.1alpha5-1
  • links: PTS
  • area: contrib
  • in suites: woody
  • size: 2,336 kB
  • ctags: 2,083
  • sloc: java: 16,095; makefile: 134; sh: 51
file content (211 lines) | stat: -rw-r--r-- 8,920 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
<html>
<pre>

<h2>Changes in 1.1alpha5</h2>
<pre>
	- License change only...  Added SPL Sun Public License agreement with
	dual licensing under the LGPL
</pre>

<h2>Changes in bsh1.1alpha3</h2>
<pre>
	- Added .field style properties access in addition to the {} style
	- Added anonymous inner class style allocation for interfaces
	- Class browser now reflects changes in class path
</pre>

<h2>Changes in bsh1.1alpha2</h2>
<pre>
	- Added namespace based name completion for console and classbrowser
		completes variables, classes, (coming... bsh methods)

	- Added import * capability to read full classpath.
	- Added overloading of bsh scripted methods
	- Added classpath extension and class reloading
		reloadClasses() reloadClasses(item)

	- improved the class browser - now has tree for packages and reflects
	the extended classpath , other improvements

	- Loose arguments in catch clauses now work.
	- deprecated getVariable/setVariable api.  Moving to get()/set()/eval();
	- internally removed BshVariable - it wasn't doing what it was historically
	intended for.  Replaced with a new bsh.system object which is shared
	across all interpreter instances
	- Added bsh.system.shutdownOnExit variable... set to false to prevent
	exit() command and desktop close from exiting the VM.
	- Loosened grammar to allow import statments in any block scope.
	e.g. you can now import within a bsh method and the import will be local
	to that method
	-Added javap() command...  accepts object, class, or string name and
	prints public fields, methods

	-Added -Doutfile=foo capture output to file (for Windows nightmare)
	- Cleaned up a lot of internal structure in NameSpace, etc.
	-Interpreter now implements ConsoleInterface
</pre>

<h2>Changes in bsh-1.01</h2>
<pre>
	- Modified parse exceptions to print more tersely...   
	Removed the "Was expecting one of..." text *except* when debug is on.
	- Fixed the for statement forinit scope bug.
	- Got rid of remaining deprecation (using Readers vs. InputStreams)
	- Fixed top level expression bug #111342
	- Fixed problems with compiling bsh under limited JDK verions (1.1, 1.2).
	  We now have factories insulating the core from all extended version
	  capabilities (e.g. proxy mechanism stuff, accessibility TBD)
	- Modified browseClass() command to accept string class name, 
		class instance, or arbitrary object 
	- Modified search for constructors to accomodate package and private
		access.
	- Added close button to class browser.
</pre>

<h2>Changes in bsh-1.0</h2>
<em>Not necessarily in order of importance</em>
<p>
<ul>

<li>Added generalized support for scripts implementing interfaces (e.g.
arbitrary event listeners).
This uses the important new JDK1.3 reflection proxy mechanism to manufacture
a proxy interface at run time.  No code generation is necessary!
<ul>
	<li>Added support to the cast operation to use the new mechanism.
	<li>Added support for automatic conversion to interface on method selection.
	e.g. if you attempt to pass a bsh scripted object as a method argument
	where the method signature calls for an interface an automatic cast to
	the appropriate interface type will be attempted.
	<li>Added a magic method invoke(method,args) which can be used to 
	handle method invocations on undefined interface methods in bsh objects.  
	This takes the place of "dummy" adapters; allowing a script to ignore one 
	or more methods of an interface that it is implementing. 
	<em>Note: one special case - direct invocations within scope 
	(e.g. command invocations) are not currently sent to invoke.</em>
</ul>

<li> Added startup file (.rc file) support.
Bsh will source the file "user.home"/.bshrc upon startup.
This defaults to C:\Windows under win98 and $HOME under Unix.
(can the home be set with an env var under Win?  "home" doesn't seem to do it).

<li>Added arguments to file invocation on command line.  
e.g.
<pre>
	java bsh.Interpreter MyClass foo bar
</pre>
Args are accessible through the root bsh object:  String [] bsh.args

<li>Enhancements to JConsole submitted by Daniel Leuck;
Added color and image support, fixed several bugs.

<li>Added support for inner classes.  This should all work as expected, but
it's new so let me know if you find weirdness.
<ul>
	<li>Added support for inner classes to import statement.
</ul>

<li>Changed the way eval()/source() handle script errors.  Instead of 
returning the error object as a value it is now wrapped up with some context 
and rethrown as an EvalError.  So you can simply catch the error with a normal 
try/catch block if you want to.  Previously errors in sourced/eval'd files 
were being squelched.  This was bad.  Note: exceptions generated by the
script or through code called by the script are thrown as TargetErrors (a
subclass of EvalError) which can also be caught and examined.


<li>Improved error reporting in many areas.  
Fixed really annoying error reporting bug that squelched target error 
info in sourced files (and commands).

<li>Improved bsh cast operation so that it throws standard ClassCastException 
for invalid cast.  You can now guard against them with the ordinary try/catch
in a bsh script.

<li>Modified the command line portion of the grammar to accept arbitrary 
expressions. e.g. you can type ``5*2;'' or ``foo instanceof Foo;'' on the 
command line now without any enclosing parens.
(Of course you won't see anything unless you're using the show() option).

<li>Removed the old AWT version of the GUI console.  If you need it you can 
get it on the web site separately.  I may reconsider this.

<li>Removed the console() command which was primarily for the old AWT console.

<li>Modified the browseClass() command to take an object instead of a string
class name.  Now you can simple say browseClass( someObject ) and pop up
the class browser to the correct place.  Special hack: If the specified object 
is a Class it will use the class.  This will all probably be replaced by
a general browse() method for the upcoming object inspector.

<li>Changed the return type of the frame() command to allow it to return an
internal frame when desktop is active.  Frame will now do the correct thing
whether the desktop is up or not.

<li>Rebuilt the distribution with JavaCC / JJTree version 1.1.  
Haven't notice any difference yet.

<li>Fixed the 'for' scoping bug - See docs on for scoping for clarification.
Previously variables declared within the for-init section were leaking out
into the outer namespace. 

<li>Fixed a bug in which tokenizer errors would cause the interpreter to hang
or exit.  They are now handled like other parsing errors.  In the future we
may want to break them out so that they can be handled separately from
EvalError.

<li>Added missing += form of string concatenation.

<li>Incorporated a patch and test suite case from Roger Bolsius that corrects 
some of the package / hidden reflected class access.  Previously the code did 
not handle the more difficult cases.

<li>Incorporated a patch from Mike Woolley which works around JDK bug 4071281
(EOF problem) under Windows JDK v1.1.

<li>Fixed most of the bugs in server mode.  Run the server pair (httpd / 
sessiond) using the server( port ) command.  Then you can telnet to port+1
or attach your web browser to port.  Note that the web browser must support
swing to run the remote JConsole.  We could supply the AWTConsole back for
compatability with old browsers...  but I'd like to move on.

<li>Internall trivia - changed the prefix of the names of all of the parser 
node classes from AST to BSH.

<li>Fixed a bug which caused ClassCastException during (ironically) a bsh 
cast operation.

<li>Improved the test harness slightly and added a number of new files to the
test suite for all of the new features.  Please send more test cases for
the test suite!

<li>Internal change: Simplified the code that determines array base types.

<li> Fixed bug where special characters on input (e.g. control charcters ^D) 
would cause the tokenizer to loop on errors.  Non printable chars are now
skipped as white space.

<li>Added the missing do-while statement

<li>Internal: Tightened up the code a bit by combining the BSH node conditional 
evaluation into one place.

<li>Fixed some race conditions in the JConsole.
Fixed multi-writer console problems.

<li>Fixed order of evaluation bugs: classes now always first, then bsh vars.
Note: this may not always be desireable.  e.g. if you have a class named
"x" in your path (violating the common naming conventions) then you can't
use a variable of name 'x' in your scripts.  Conversely though, it prevents
one from doing "Integer = 5;" and shadowing the java.lang.Integer class
with a variable name.  Any thoughts on this?

<li>Corrected handling of the bsh root object.

<li>Added a menu item to console to redirect stdin/stdout/stderr.
If you close the console they are restored to the original System.in,out,err.

</ul>

<hr>