1.需要读取的文件地址:

2. 本地启动项目读取文件
InputStream instream = Object.class.getResourceAsStream("/cert/apiclient_cert.p12");3.服务器中启动在jar包中读取文件
import org.springframework.core.io.ClassPathResource;
InputStream instream = new ClassPathResource("classpath:/cert/apiclient_cert.p12原创文章,作者:投稿专员,如若转载,请注明出处:https://www.506064.com/n/251125.html
微信扫一扫
支付宝扫一扫