hi,

i think i've found a small bug in the Implement Interface Wizard.
If the implemented Interface methods contain Array Params the generated Parameternames contain a ';'.

running the wizard on this interface:

public interface TestI {
public void example(String[] fst, String[] snd);
}// TestI

generates the following code:

public class TestImpl implements TestI {
public TestImpl() {
} // TestImpl constructor

// Implementation of TestI
/**
* Describe <code>action</code> method here.
*
* @param string a <code>String[]</code> value
* @param string a <code>String[]</code> value
*/
public void example(String[] string;, String[] string;1) {
}
} // TestImpl

a small change to the Method getParameterName(Signature, int) in DefaultNameFactory.java fixes the problem
for Example:

[...]
// To handle inner-class .class files
String className = type.getName().replace('$', '.');

int j = className.lastIndexOf(';');
if (j >= 0) {
className = className.substring(0, j);
}
[...]

Emacs : GNU Emacs 21.2.1 (i386-msvc-nt5.0.2195) of 2002-03-19 on buffy
Package: JDE version 2.3.1
Required packages: semantic-1.4 eieio-0.17 speedbar-0.14beta4
Java Version: JDK 1.4.0

Alphonse Bendt

Reply via email to