EMain.java 648 B

123456789101112131415161718192021222324252627
  1. package com.hotent.im.encrypt;
  2. /******************************
  3. * Created by yanhongliang
  4. * 2019-06-04 11:00
  5. ******************************/
  6. public class EMain {
  7. public static void main(String[] args) {
  8. // String privateKey = "privateKey";
  9. //
  10. // Encrypt encrypt = new Encrypt();
  11. //
  12. // String str = "yhliang";
  13. //
  14. // String encodeJSON = encrypt.encodeJSON(str, privateKey);
  15. //
  16. // System.out.println("------加密------"+encodeJSON);
  17. // System.out.println("===============================");
  18. // System.out.println("------解密------"+encrypt.decodeJSON(encodeJSON, privateKey));
  19. }
  20. }