huge apologies if this has been asked before, I did search but nothing seemed to cover the problem I have.
I am a complete novice in Java btw.
My problem is this:
So far I have loaded the file as follows:
int element = 0;
for (int count = 0; count < numberOfLines; count++) {
List<String> range = Arrays.asList(lines.get(count));
String splitRange = String.valueOf(range.get(element));
element++;
int myHash = (int) splitRange.get(element);
byte myKey = (byte) range[element];
byte[] ib = (byte[]) range[element];
byte[] myCheck = (byte[]) range[element];
byte[] myCat = (byte[]) range[element];
byte[] myDel = (byte[]) range[element];
if (element > 5){
element = 0;
}
}
I have a generated file that contains lines of in this format:
[-1284234074, 1, [101, 97, 51, 97, 54, 57, 49, 48], [7, 90, 116, -56, 105, -90, -23, 84, 101, 56, 99, -59, 19, 88, -55, -2], [-107, -101, -58, -45, -120, -42, -60, -81, -58, -104, -78, -110, -67, -86, -123, -120], [-126, -119, -119, -128, -120, -114, -111, -128, -123, -126, -120, -94, -125, -121, -128, -126]]
Now, this is supposed to be the following:
int, byte, byte[], byte[], byte[], byte[]
How on earth can I split this line in to these variables?