package com.chushang.gateway.service;

import com.chushang.common.core.exception.ResultException;
import com.chushang.common.core.web.AjaxResult;

import java.io.IOException;
import java.util.concurrent.ExecutionException;

/**
 * 验证码处理
 *
 * @author ruoyi
 */
public interface ValidateCodeService
{
    /**
     * 生成验证码
     */
    AjaxResult createCaptcha() throws IOException, ResultException;

    /**
     * 校验验证码
     */
    void checkCaptcha(String key, String value) throws ResultException, ExecutionException, InterruptedException;
}
