private CoderResult controlSequence(short newByte){
  if (newByte >= 0x30 && newByte <= 0x3F) {
    if (state == CONTROL_SEQUENCE_IF) {
      return malformedInput(ERR_CTRLPI);
    }
    queue.write(newByte);
  }
 else   if (newByte >= 0x20 && newByte <= 0x2F) {
    state=CONTROL_SEQUENCE_IF;
    queue.write(newByte);
  }
 else   if (newByte >= 0x40 && newByte <= 0x7E) {
    state=NORMAL_BYTES;
    queue.reset();
  }
 else {
    return malformedInput(ERR_CTRLBYTE);
  }
  return CoderResult.UNDERFLOW;
}

private CoderResult controlSequence ( short newByte ) { if ( newByte >= 0x30 && newByte <= 0x3F ) { if ( state == CONTROL_SEQUENCE_IF ) { return malformedInput ( ERR_CTRLPI ) ; } queue . write ( newByte ) ; } else if ( newByte >= 0x20 && newByte <= 0x2F ) { state = CONTROL_SEQUENCE_IF ; queue . write ( newByte ) ; } else if ( newByte >= 0x40 && newByte <= 0x7E ) { state = NORMAL_BYTES ; queue . reset ( ) ; } else { return malformedInput ( ERR_CTRLBYTE ) ; } return CoderResult . UNDERFLOW ; }
parses directionality , as well as unknown , but valid , control sequences .
