// 全局路由导航拦截 router.beforeEach((to, from, next) ? { // ... if (to.path '/login') { // 如果是登录页面路径,就直接next() next() } else { // 其他页面路径 let token = session ...
分类:
其他好文 时间:
2021-05-24 02:26:50
阅读次数:
0
public class ThreadDemo { //1.定义一个静态变量,因为静态变量是线程共享的 public static int count = 0; //2.定义一个自增的方法 public static void add() { try { Thread.sleep(1);//让程序睡 ...
分类:
编程语言 时间:
2021-05-24 02:11:00
阅读次数:
0
原文:C++ static_cast、dynamic_cast、const_cast和reinterpret_cast(四种类型转换运算符) < C/C++类型转换的本质(经典之作)输入输出流 > 上节讲到,隐式类型转换是安全的,显式类型转换是有风险的,C语言之所以增加强制类型转换的语法,就是为了强 ...
分类:
编程语言 时间:
2021-05-24 01:51:13
阅读次数:
0
HelloWorld 随便新建一个文件夹,存放代码 新建一个Java文件 文件后缀名为.java Hello.java 【注意点】系统可能没有显示文件后缀名,需要手动打开 编写代码 public class Hello{ public static void main(String[]args){ ...
分类:
其他好文 时间:
2021-05-24 01:16:13
阅读次数:
0
static void Main(string[] args) { List<Man> list = new List<Man>(); for (int i = 0; i < 10; i++) { Man d = new Man(); d.Age = i ; d.Name = i.ToString( ...
分类:
其他好文 时间:
2021-05-24 01:06:23
阅读次数:
0
多态 多态注意事项: 多态是方法的多态,属性没有多态 父类和子类,有联系,类型转换异常! ClassCastException 3. 存在条件:继承关系,方法需要重写,父类引用指向子类对象! Father f1 -->Son(); 不能重写的方法: 1.static方法,属于类,它不属于实例 2.f ...
分类:
其他好文 时间:
2021-05-24 01:02:58
阅读次数:
0
当程序中有复合赋值运算符时,不同类型的数据会进行强制转换,比如下面例子:byte b += 2,是把int类型数据强制转换成byte,然后在进行赋值操作的! public class AssignOperator { public static void main(String[] args) { ...
分类:
编程语言 时间:
2021-05-24 00:59:35
阅读次数:
0
桌面新建一个文本文档(新建文本文档.txt)将文件名修改为 Demo01.java,内容如下: public class Demo01 { public static void main(String[] args) { int a = 10; System.out.println(a); } } ...
分类:
编程语言 时间:
2021-05-24 00:55:02
阅读次数:
0
模板文件及静态文件的使用 一、模板文件 默认路径:项目根目录下的views文件夹 修改路径:两种方式 1.在main.go中加 beego.SetViewsPath("newViewPath") 2.在配置文件conf/app.conf 下加入 viewspath= newViewPath, 这类方 ...
分类:
其他好文 时间:
2021-05-24 00:36:13
阅读次数:
0
1 Java 静态对象 static 2 lombok——@EqualsAndHashCode(callSuper = true)注解的使用 ...
分类:
其他好文 时间:
2021-05-24 00:22:24
阅读次数:
0