That makes good sense. I think the references of objects in the decoder class is somehow messed up, not working like the algorithm supposed to do. Wait a second, help me to clear up something:
Say, in the ...DecoderTest class, firstly the CodeWordVector received was created, let's assume at address 0x0004. Then this object was then made to store a bunch of references to EFElement objects like the setUp() method did. But it still lies at 0x0004. Then a new object "sent" was created at 0x0008 (egal wo). Then the address 0x0004 was passed to "sent" so now both sent and receive point to the same address. The address 0x0008 is available to other objects (egal was). Then this happened:
another object called result was created at 0x000c. But then after the bmd.decode(received), the "result" may well be then pointing to another address say 0x0010. (The object which lies at 0x0010 was created during the decoder class was executed.). Now, both sent and received are still pointing to 0x0004, result is pointing to 0x0010...
Am I thinking right? And is there any way in the
java language to verify the address of an object? In another word, how to get the physical address of an object in java? :roll: Thank you very much in advance!
Regards,
Ellen
[ February 20, 2005: Message edited by: Ellen Zhao ]