public void validate() throws FtpWorkflowException, FtpIOException {
    	if (this.getLines().size() <= 0)
    		throw new FtpIOException("000", "Did not receive any reply!");
    		
        if (ReplyCode.isPermanentNegativeCompletionReply(this)) {
            if (getReplyCode().intern() == ReplyCode.REPLY_530.intern())
                throw new NotConnectedException(getReplyMessage());
            if (getReplyCode().intern() == ReplyCode.REPLY_550.intern())
                throw new FtpFileNotFoundException(getReplyMessage());
            throw new FtpWorkflowException(this.getReplyCode(), this
                    .getReplyMessage());
        } else if (ReplyCode.isTransientNegativeCompletionReply(this)) {
            throw new FtpIOException(this.getReplyCode(), this
                    .getReplyMessage());
        }
    }