public class URLDownload { public static void main(String[] args) throws IOException { URL url=new URL("https://m10.music.126.net/20210204001424/b2ecd ...
分类:
Web程序 时间:
2021-02-04 12:17:48
阅读次数:
0
1 package base; 2 3 public class Demo3 { 4 //类变量 static 5 //修饰符顺序不讲究 6 static double salary =2500; 7 8 // 属性:变量 9 10 // 实例变量:从属于对象;如果不自行初始化,这个类型的默认值 0 ...
分类:
其他好文 时间:
2021-02-04 12:11:16
阅读次数:
0
1 package operation; 2 3 public class Demo1 { 4 public static void main(String[] args) { 5 //二元运算符 6 //Ctrl+D :复制当前行到下一行 7 int a=10; 8 int b=20; 9 int ...
分类:
其他好文 时间:
2021-02-04 12:10:02
阅读次数:
0
FeignClient 默认的解析器: public static FeignException errorStatus(String methodKey, Response response) { // 这里做了处理 String message = format("status %s readi ...
分类:
编程语言 时间:
2021-02-03 11:08:33
阅读次数:
0
{ web,native,any}中我们先学习 react-router-dom。 react-router-dom(官方维护的路由器)的理解 1 react的一个插件库。 { web,native,any} 2 专门用来实现一个SPA应用。 3 基于react的项目都会用到此库。 路由和路由器。 ...
分类:
其他好文 时间:
2021-02-03 10:48:44
阅读次数:
0
static关键字用法 static方法不能调用非static方法 static方法是类加载的时候产生的,所以不能调用随着对象产生而产生的非static方法。 代码块和静态代码块 代码块都是装在类里的 static { }//静态代码块运行最早,只在加载所属类的时候运行一次 { }//匿名代码块,和 ...
分类:
其他好文 时间:
2021-02-02 11:26:56
阅读次数:
0
createWebHistory路由模式路径不带#号(生产环境下不能直接访问项目,需要nginx转发) http://localhost:8080/#/ const router = createRouter({ history: createWebHistory(), routes }); cre ...
分类:
其他好文 时间:
2021-02-02 11:14:24
阅读次数:
0
/** * 判断是否是字符串 * @param target */static isString(target: any) { return target && typeof target == 'string' && target.constructor == String;}/** * 判断是否 ...
分类:
其他好文 时间:
2021-02-02 11:11:35
阅读次数:
0
import javax.servlet.*; import java.io.IOException; public class CharacterEncodingFilter implements Filter { private static String encoding; // 定义变量接收 ...
分类:
其他好文 时间:
2021-02-02 11:03:29
阅读次数:
0
1、模式主要思想: 保证一个类仅有一个实例,并提供一个该实例的全局访问点。 2、以下为各个版本的单例模式及存在的问题 (1)第一版: 1 class Singleton 2 { 3 public: 4 static Singleton * GetInstance() 5 { 6 if (_insta ...
分类:
其他好文 时间:
2021-02-02 10:38:28
阅读次数:
0