This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package com.exapmle | |
| import java.util.ArrayList; | |
| import java.util.HashMap; | |
| /** | |
| * 强转泛型集合防止警告 | |
| * | |
| * @author chengyiqun | |
| * @version V1.0 | |
| * @date 2021/7/22 17:10 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import org.apache.commons.codec.binary.Hex; | |
| import java.io.*; | |
| import java.security.MessageDigest; | |
| import java.util.*; | |
| public class FilesUtil { | |
| /** | |
| * |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /** | |
| * | |
| * 全局加载jvm黑体字体 | |
| * | |
| * @author chengyq | |
| * | |
| */ | |
| @Component | |
| @Order(1) | |
| public class FontLoaderRunner implements CommandLineRunner { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public class Main { | |
| public static void main(String[] args) { | |
| User axin = new User(); | |
| User.School school = new User.School(); | |
| axin.setName("hello"); | |
| // 1. 基本调用 | |
| String value1 = OptionalBean.ofNullable(axin) | |
| .getBean(User::getSchool) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ##### hostapd configuration file ############################################## | |
| # Empty lines and lines starting with # are ignored | |
| # AP netdevice name (without 'ap' postfix, i.e., wlan0 uses wlan0ap for | |
| # management frames with the Host AP driver); wlan0 with many nl80211 drivers | |
| interface=wlan0 | |
| # In case of atheros and nl80211 driver interfaces, an additional | |
| # configuration parameter, bridge, may be used to notify hostapd if the | |
| # interface is included in a bridge. This parameter is not used with Host AP |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # !/usr/bin/python3 | |
| # encoding: utf-8 | |
| import RPi.GPIO | |
| import time | |
| RPi.GPIO.setwarnings(False) | |
| RPi.GPIO.setmode(RPi.GPIO.BCM) | |
| RPi.GPIO.setup(14, RPi.GPIO.OUT) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package com.example.demo; | |
| import java.io.BufferedOutputStream; | |
| import java.io.BufferedReader; | |
| import java.io.FileNotFoundException; | |
| import java.io.FileOutputStream; | |
| import java.io.FileReader; | |
| import java.io.IOException; | |
| import java.text.ParseException; | |
| import java.text.SimpleDateFormat; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public class ConfigUtils { | |
| public static String getGroupId() { | |
| String property = SystemProperties.getProperty("dep.bss.cloud.groupId"); | |
| if (ObjectIsNull.check(property)) { | |
| throw new RuntimeException("groupId 未在tomcat配置文件中配置"); | |
| } | |
| return property; | |
| } | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /** | |
| * 对象转Map | |
| * | |
| * @param object | |
| * @return | |
| * @throws IllegalAccessException | |
| */ | |
| public static Map<String, Object> objectToMap(Object object) { | |
| Map<String, Object> map = new HashMap<>(); | |
| Field[] fields = object.getClass().getDeclaredFields(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # 2026年4月1日 | |
| # port: 7890 # HTTP(S) 代理服务器端口 | |
| # socks-port: 7891 # SOCKS5 代理端口 | |
| mixed-port: 10801 # HTTP(S) 和 SOCKS 代理混合端口 | |
| redir-port: 7891 # 透明代理端口,用于 Linux 和 MacOS | |
| # Transparent proxy server port for Linux (TProxy TCP and TProxy UDP) | |
| tproxy-port: 1536 |