摘要:
1、文件加密上传后发现文件已损坏: 原因:使用 read(byte[]) 方法不能够准确的获取到正确的字节数,有可能比 byte[].length 小,所以在解密的时候出现错误。 解决办法: 判断读取到的字节数是否是byte[].length,如果不是继续读取,直到读满byte[].length.( 阅读全文
posted @ 2017-06-16 11:18
coder_ornot
阅读(1737)
评论(0)
推荐(0)
摘要:
1、新建 ApplicationContextUtil 类 ,通过实现 ApplicationContextAware 的 setApplicationContext 方法,得到context上下文: private static ApplicationContext context = null; 阅读全文
posted @ 2017-06-16 10:58
coder_ornot
阅读(750)
评论(0)
推荐(0)
浙公网安备 33010602011771号