public char charAt(int index)
{
return ((index + offset < 0) || (index + offset) >= max
- || annotations[index + offset] == null || (annotations[index
- + offset].secondaryStructure <= ' ') ? ' '
- : annotations[index + offset].displayCharacter.charAt(0));
+ || annotations[index + offset] == null
+ || (annotations[index + offset].secondaryStructure <= ' ') ? ' '
+ : annotations[index + offset].displayCharacter == null
+ || annotations[index + offset].displayCharacter
+ .length() == 0 ? annotations[index + offset].secondaryStructure
+ : annotations[index + offset].displayCharacter
+ .charAt(0));
}
@Override
for (int i = offset; i < mx; i++)
{
string[i] = (annotations[i] == null || (annotations[i].secondaryStructure <= 32)) ? ' '
- : annotations[i].displayCharacter.charAt(0);
+ : (annotations[i].displayCharacter == null
+ || annotations[i].displayCharacter.length() == 0 ? annotations[i].secondaryStructure
+ : annotations[i].displayCharacter.charAt(0));
}
return new String(string);
}