|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||
java.lang.Objectcdx.ASCIIConverter
public class ASCIIConverter
The purpose of this class is to permit printing of debug messages with callsigns (byte arrays) and floating point data from a no-heap thread. With standard Java ways of doing this, we get MemoryAccessError due to the internal use of ThreadLocal by Sun RTS for character encoders/decoders (and possibly other things). With encoders/decoders, lazy initialisation leads to uncontrolled allocation w.r.t. to scope. Most likely the problem is that the thread locals get allocated on the heap.
| Constructor Summary | |
|---|---|
ASCIIConverter()
|
|
| Method Summary | |
|---|---|
static java.lang.String |
bytesToString(byte[] bytes)
Convert byte[] to a string |
static java.lang.String |
floatToString(float f)
Convert a float to a string |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ASCIIConverter()
| Method Detail |
|---|
public static java.lang.String bytesToString(byte[] bytes)
bytes - The converted object
public static java.lang.String floatToString(float f)
f - The converted object
|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||