So, I have all these bytes [], and their encoding can be one of many different formats, depending on where I am debugging now. I would like to be able to combine a prediction list for an array of bytes. I use the IntelliJ Data Type Renderers view, applying the renderer to the byte type [], and I'm primarily interested in the Expression List field.
So, I saw how you can display a node with a new String(this) expression, however this does not work in the list of expressions below. In the end, I want to do expressions like new String(this, "UTF16") (or do conversions to hex or base64 or w / e), but this does not appear byte [] in the list of expressions - actually, when I try typecast like (byte[])this result says Inconvertible types; cannot cast '_Dummy_.__Array__≤T≥' to 'byte[]' Inconvertible types; cannot cast '_Dummy_.__Array__≤T≥' to 'byte[]' (same behavior for java.lang.Byte []). This is a really strange behavior, that in one place it is a byte [], and in another it is some opaque internal type.
What the job does is by simply displaying the fields, i.e. an expression like this.length works as expected. In addition, an expression like this simply reloads the node, claiming that its type iste [], and its object identifier matches the original identifier.
java intellij-idea intellij-13
Kenny
source share