if(ec == ErrorCode.U_BUFFER_OVERFLOW_ERROR){ return CoderResult.OVERFLOW; }
if (ErrorCode.isFailure(ec)) { if (ec == ErrorCode.U_BUFFER_OVERFLOW_ERROR) { return CoderResult.OVERFLOW; }else if (ec == ErrorCode.U_TRUNCATED_CHAR_FOUND) { return CoderResult.malformedForLength(data[INPUT_OFFSET]); }else { ErrorCode.getException(ec); } }
    protected final CoderResult implFlush(CharBuffer out) {       try{            getArray(out);                        ec=NativeConverter.flushByteToChar(                                            converterHandle,  /* Handle to ICU Converter */                                            output,           /* input array of chars */                                            outEnd,           /* input index+1 to be written */                                            data              /* contains data, inOff,outOff */                                            );                                                              /* if we donot have room for input throw an error*/            if(ec == ErrorCode.U_BUFFER_OVERFLOW_ERROR){		        return CoderResult.OVERFLOW;		    }	        implReset();	        return CoderResult.UNDERFLOW;	   }finally{            /* save the flushed data */            setPosition(out);	   }    }