public void throwException() throws BufferUnderflowException,BufferOverflowException, UnmappableCharacterException,MalformedInputException, CharacterCodingException {switch (this.type) {case TYPE_UNDERFLOW:throw new BufferUnderflowException();case TYPE_OVERFLOW:throw new BufferOverflowException();case TYPE_UNMAPPABLE_CHAR:throw new UnmappableCharacterException(this.length);case TYPE_MALFORMED_INPUT:throw new MalformedInputException(this.length);default:throw new CharacterCodingException();}}