All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.diboot.devtools.v2.OOO0O00O00O0OO0O Maven / Gradle / Ivy

The newest version!
/**
 * Copyright (c) dibo.ltd, https://www.dibo.ltd, https://www.diboot.com
 * 

* ---- 版权声明 ---- * Diboot相关商标、软件著作权、专利等全部知识产权隶属于苏州帝博信息技术有限公司。 * Diboot devtools 非开源项目,如您有devtools相关定制化需求,请至官网(https://www.dibo.ltd)联系帝博信息商务。 * * 《中华人民共和国刑法》规定:破坏计算机信息系统罪,处五年以下有期徒刑或者拘役;后果特别严重的,处五年以上有期徒刑。 * 侵犯知识产权罪:处三年以下有期徒刑、拘役或管制,并处罚金;情节特别严重的,处三年以上七年以下有期徒刑,并处罚金。 * * 任何尝试破解、破坏devtools、侵犯diboot知识产权的行为,我们将不惜一切代价追究到底! *

*/ package com.diboot.devtools.v2; import com.baomidou.mybatisplus.core.toolkit.ClassUtils; import com.diboot.core.exception.BusinessException; import com.diboot.core.util.S; import com.diboot.core.util.V; import com.diboot.core.vo.Status; import lombok.extern.slf4j.Slf4j; import java.io.File; import java.net.URL; import java.net.URLDecoder; import java.util.*; @Slf4j @Deprecated() public class OOO0O00O00O0OO0O { private static String llll111lll11l = null; private static Map l1l1l11ll1l1l = new HashMap<>(); public static enum PT_TP { WORKSPACE, UPDATE_SQL, PROJECT_ROOT, PROJECT_SRC, PROJECT_SRC_JAVA, PROJECT_WEB_STATIC, PROJECT_RESOURCES_STATIC, RUNTIME_ROOT, RUNTIME_CLASSES, RUNTIME_WEB_STATIC } @Deprecated() public static boolean ll111l111ll1ll1(String l1l1llllll1l) { if (l1l1llllll1l.startsWith("/") || l1l1llllll1l.indexOf(":") > 0) { return true; } return false; } @Deprecated() public static String llll11l1ll111l1(String ll11l1lll1l1) { if (V.isEmpty(ll11l1lll1l1)) { return null; } if (!ll11l1lll1l1.endsWith("/")) { ll11l1lll1l1 += "/"; } if (ll111l111ll1ll1(ll11l1lll1l1)) { return ll11l1lll1l1; } String l111ll111lll = lll1ll1ll1ll1ll(PT_TP.WORKSPACE) + ll11l1lll1l1; l111ll111lll = ll1l1llll1ll11l(l111ll111lll); return l111ll111lll; } @Deprecated() public static String lll11l1l11l11l1(String l1l11111l1l1) { return lll1ll1ll1ll1ll(PT_TP.UPDATE_SQL) + l1l11111l1l1; } @Deprecated() public static String lll1ll1ll1ll1ll(PT_TP ll11l1ll1111) { if (l1l1l11ll1l1l.containsKey(ll11l1ll1111)) { return l1l1l11ll1l1l.get(ll11l1ll1111); } String l1lll1l1l111 = l1llll111l11l(ll11l1ll1111); l1l1l11ll1l1l.put(ll11l1ll1111, l1lll1l1l111); return l1lll1l1l111; } @Deprecated() private static String l1llll111l11l(PT_TP l1l1111111ll) { if (llll111lll11l == null) { llll111lll11l = ll1l1l1111l1lll(); } switch(l1l1111111ll) { case WORKSPACE: return ll1l1111l11l1(); case UPDATE_SQL: String ll11l1llll11 = OO0O0OOOOO0O0O00.llll11l1ll111l1(O0O0O0000OO0O000.LYR.SQL); if (V.notEmpty(ll11l1llll11)) { return ll11l1llll11; } return ll1l1111l11l1(); case PROJECT_ROOT: return lll11l1l1l1l1(); case PROJECT_SRC: return lll11l1l1l1l1() + "src/"; case PROJECT_SRC_JAVA: return lll11l1l1l1l1() + "src/main/java/"; case PROJECT_WEB_STATIC: return l1l111111l11l(lll11l1l1l1l1() + OOO0OO00O00O00OO.l11llll1ll11ll1("c3JjL21haW4vcmVzb3VyY2VzL3N0YXRpYy8="), lll11l1l1l1l1() + OOO0OO00O00O00OO.l11llll1ll11ll1("c3JjL21haW4vd2ViYXBwL3N0YXRpYy8="), lll11l1l1l1l1() + OOO0OO00O00O00OO.l11llll1ll11ll1("c3JjL21haW4vc3RhdGljLw==")); case PROJECT_RESOURCES_STATIC: return lll11l1l1l1l1() + "src/main/resources/static/"; case RUNTIME_ROOT: if (llll111lll11l.indexOf(OOO0OO00O00O00OO.l11llll1ll11ll1("L3RhcmdldC8=")) > 0) { return lll11l1l1l1l1() + OOO0OO00O00O00OO.l11llll1ll11ll1("dGFyZ2V0Lw=="); } else if (llll111lll11l.indexOf(OOO0OO00O00O00OO.l11llll1ll11ll1("L2J1aWxkLw==")) > 0) { return lll11l1l1l1l1() + OOO0OO00O00O00OO.l11llll1ll11ll1("YnVpbGQv"); } else if (llll111lll11l.indexOf(OOO0OO00O00O00OO.l11llll1ll11ll1("L291dC8=")) > 0) { return lll11l1l1l1l1() + OOO0OO00O00O00OO.l11llll1ll11ll1("b3V0Lw=="); } else if (llll111lll11l.indexOf(OOO0OO00O00O00OO.l11llll1ll11ll1("L2Jpbi8=")) > 0) { return lll11l1l1l1l1() + OOO0OO00O00O00OO.l11llll1ll11ll1("YmluLw=="); } case RUNTIME_CLASSES: return llll111lll11l; case RUNTIME_WEB_STATIC: String ll11l1l1l111 = ll111l111l1ll(llll111lll11l, OOO0OO00O00O00OO.l11llll1ll11ll1("L2NsYXNzZXMv"), OOO0OO00O00O00OO.l11llll1ll11ll1("L3Jlc291cmNlcy9tYWluL3N0YXRpYw==")); if (ll11l1l1l111 == null) { ll11l1l1l111 = ll111l111l1ll(llll111lll11l, OOO0OO00O00O00OO.l11llll1ll11ll1("L2NsYXNzZXMv"), OOO0OO00O00O00OO.l11llll1ll11ll1("L3Jlc291cmNlcy9zdGF0aWM=")); } if (ll11l1l1l111 == null) { ll11l1l1l111 = ll111l111l1ll(llll111lll11l, OOO0OO00O00O00OO.l11llll1ll11ll1("L3RhcmdldC9jbGFzc2VzLw=="), OOO0OO00O00O00OO.l11llll1ll11ll1("L3RhcmdldC9jbGFzc2VzL3N0YXRpYw==")); } if (ll11l1l1l111 == null) { ll11l1l1l111 = ll111l111l1ll(llll111lll11l, OOO0OO00O00O00OO.l11llll1ll11ll1("L1dFQi1JTkYvY2xhc3Nlcw=="), OOO0OO00O00O00OO.l11llll1ll11ll1("L3N0YXRpYw==")); } if (ll11l1l1l111 == null) { ll11l1l1l111 = ll111l111l1ll(llll111lll11l, OOO0OO00O00O00OO.l11llll1ll11ll1("L2Jpbi9tYWlu"), OOO0OO00O00O00OO.l11llll1ll11ll1("L2Jpbi9tYWluL3N0YXRpYw==")); } if (ll11l1l1l111 == null) { log.warn(OOO0OO00O00O00OO.l11llll1ll11ll1("5pyq5qOA5rWL5Yiw6L+Q6KGM5pe2d2Vi6Z2Z5oCB55uu5b2VIQ==")); } return ll11l1l1l111; default: log.warn("没有找到需要获取路径的类型"); } return null; } @Deprecated() private static String ll1l1111l11l1() { String llll11ll1l1l = lll11l1l1l1l1(); if (V.notEmpty(llll11ll1l1l)) { llll11ll1l1l = S.substringBeforeLast(llll11ll1l1l, "/"); return S.substringBeforeLast(llll11ll1l1l, "/") + "/"; } return null; } @Deprecated() private static String lll11l1l1l1l1() { if (llll111lll11l == null) { llll111lll11l = ll1l1l1111l1lll(); } if (llll111lll11l.indexOf(OOO0OO00O00O00OO.l11llll1ll11ll1("L3RhcmdldC8=")) > 0) { return S.substringBefore(llll111lll11l, OOO0OO00O00O00OO.l11llll1ll11ll1("L3RhcmdldC8=")) + "/"; } else if (llll111lll11l.indexOf(OOO0OO00O00O00OO.l11llll1ll11ll1("L2J1aWxkLw==")) > 0) { return S.substringBefore(llll111lll11l, OOO0OO00O00O00OO.l11llll1ll11ll1("L2J1aWxkLw==")) + "/"; } else if (llll111lll11l.indexOf(OOO0OO00O00O00OO.l11llll1ll11ll1("L291dC8=")) > 0) { return S.substringBefore(llll111lll11l, OOO0OO00O00O00OO.l11llll1ll11ll1("L291dC8=")) + "/"; } else if (llll111lll11l.indexOf(OOO0OO00O00O00OO.l11llll1ll11ll1("L2Jpbi9tYWluLw==")) > 0) { return S.substringBefore(llll111lll11l, OOO0OO00O00O00OO.l11llll1ll11ll1("L2Jpbi9tYWluLw==")) + "/"; } else if (llll111lll11l.indexOf(OOO0OO00O00O00OO.l11llll1ll11ll1("L1dFQi1JTkYv")) > 0) { return S.substringBefore(llll111lll11l, OOO0OO00O00O00OO.l11llll1ll11ll1("L1dFQi1JTkYv")) + "/"; } else { log.warn(OOO0OO00O00O00OO.l11llll1ll11ll1("RmFpbGVkIHRvIGRldGVjdCB5b3VyIGJ1aWxkIHBhdGg6IA==") + llll111lll11l); } return null; } @Deprecated() private static String l1l111111l11l(String... lll1l1l111l1) { if (V.isEmpty(lll1l1l111l1)) { return null; } for (String l1l11l1ll11l : lll1l1l111l1) { String ll1l1l1lllll = l1l11l1ll11l; if (ll1l1l1lllll.endsWith("/")) { ll1l1l1lllll = S.substringBeforeLast(ll1l1l1lllll, "/"); } File l1l1l1lll111 = new File(ll1l1l1lllll); if (l1l1l1lll111.exists() && l1l1l1lll111.isDirectory()) { return l1l11l1ll11l; } } return null; } @Deprecated() private static String ll111l111l1ll(String ll11l11l1ll1, String lll1ll11lll1, String l11l1111l11l) { if (V.isEmpty(ll11l11l1ll1) || !ll11l11l1ll1.contains(lll1ll11lll1)) { return null; } String ll111lll1lll = S.substringBeforeLast(ll11l11l1ll1, lll1ll11lll1); String ll11111lllll = ll111lll1lll + l11l1111l11l; File l111l111llll = new File(ll11111lllll); if (l111l111llll.exists()) { return ll11111lllll; } return null; } @Deprecated() public static List l1ll11l11l1l1ll(File l11l11lll1l1) { if (l11l11lll1l1.listFiles() == null) { return Collections.emptyList(); } List lll11l11llll = new ArrayList<>(); for (File ll1l1lll1l1l : l11l11lll1l1.listFiles()) { if (ll1l1lll1l1l.isDirectory()) { lll11l11llll.add(ll1l1lll1l1l); } } return lll11l11llll; } @Deprecated() public static String ll1l1l1111l1lll() { URL lll1111lll1l = ClassUtils.getDefaultClassLoader().getResource(""); try { return URLDecoder.decode(lll1111lll1l.getPath(), OOO0OO00O00O00OO.l11llll1ll11ll1("VVRGLTg=")); } catch (Exception e) { return lll1111lll1l.getPath(); } } @Deprecated() public static String ll1l1llll1ll11l(String l1111ll1l1ll) { if (V.isEmpty(l1111ll1l1ll)) { return l1111ll1l1ll; } if (l1111ll1l1ll.contains(OOO0OO00O00O00OO.l11llll1ll11ll1("Li4vLi4v"))) { return l11lll1111llll1(l1111ll1l1ll, OOO0OO00O00O00OO.l11llll1ll11ll1("Li4vLi4v"), 2); } else if (l1111ll1l1ll.contains(OOO0OO00O00O00OO.l11llll1ll11ll1("Li4v"))) { return l11lll1111llll1(l1111ll1l1ll, OOO0OO00O00O00OO.l11llll1ll11ll1("Li4v"), 1); } else if (l1111ll1l1ll.contains("./")) { return l11lll1111llll1(l1111ll1l1ll, "./", 0); } else { return l1111ll1l1ll; } } @Deprecated() public static String l11lll1111llll1(String l11ll111lll1, String l1ll11l1111l, int l111ll1l1ll1) { if (V.isEmpty(l11ll111lll1)) { return l11ll111lll1; } if (!l11ll111lll1.contains(l1ll11l1111l)) { return l11ll111lll1; } l1ll11l1111l = S.replace(l1ll11l1111l, ".", "\\."); String[] l11111l1l11l = l11ll111lll1.split(l1ll11l1111l); if (l11111l1l11l.length != 2) { log.error(OOO0OO00O00O00OO.l11llll1ll11ll1("6Lev5b6E6YWN572u6ZSZ6K+v77ya"), l11ll111lll1); throw new BusinessException(Status.FAIL_EXCEPTION, OOO0OO00O00O00OO.l11llll1ll11ll1("6Lev5b6E6YWN572u5pyJ6K+v")); } String l11ll111ll11 = l11111l1l11l[0]; if (V.notEmpty(l11ll111ll11)) { String[] l11ll1ll1l1l = l11ll111ll11.split("/"); ArrayList lll1lllll1l1 = new ArrayList<>(Arrays.asList(l11ll1ll1l1l)); if (lll1lllll1l1.size() > l111ll1l1ll1) { for (int lll111111l11 = 0; lll111111l11 < l111ll1l1ll1; lll111111l11++) { lll1lllll1l1.remove(lll1lllll1l1.size() - 1); } l11ll111ll11 = S.join(lll1lllll1l1, "/"); } else if (lll1lllll1l1.size() > 0) { l11ll111ll11 = lll1lllll1l1.get(0); } else { l11ll111ll11 = ""; } } return l11ll111ll11 + "/" + l11111l1l11l[1]; } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy