for(int i=1; i < index; i++) {
Constant c = constants[i];
if(c instanceof ConstantString) {
ConstantString s = (ConstantString)c;
ConstantUtf8 u8 = (ConstantUtf8)constants[s.getStringIndex()];
string_table.put(u8.getBytes(), new Index(i));
} else if(c instanceof ConstantClass) {
ConstantClass s = (ConstantClass)c;
ConstantUtf8 u8 = (ConstantUtf8)constants[s.getNameIndex()];
class_table.put(u8.getBytes(), new Index(i));
} else if(c instanceof ConstantNameAndType) {
ConstantNameAndType n = (ConstantNameAndType)c;
ConstantUtf8 u8 = (ConstantUtf8)constants[n.getNameIndex()];