摘要:
https://cloud.tencent.com/developer/article/2018778 HTML DOM addEventListener() 方法 document.addEventListener(event, function, useCapture) 参数 描述event 必 阅读全文
摘要:
using System; using System.Collections.Generic; using System.Text; using System.Net; using System.Net.Sockets; namespace SmartConstructionSite.Common. 阅读全文
摘要:
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <meta name="viewport" content="wi 阅读全文
摘要:
window.onload = function () { // 数组解构 let [x, y, z] = [true, [1, 2, 3], { id: 1 }]; //等价 // x=true; // y=[1,2,3]; // z={id:1}; let arr = [10, 20]; if 阅读全文
摘要:
<!-- <script> // const 声明一个只读的常量, 只能读取——基本类型 初始化的时候必须给值 (另一种是引用类型) 栈里 const abc = 111; // abc = 222; // 报错 const abcarray = { name: 'kkk', } abcarray. 阅读全文
摘要:
<!-- <script> window.onload = function () { var a = 10; let b = 20; const c = 30; // ES5 预解析 变量提升 var function 结果 undefined console.log(x); var x = 11 阅读全文
摘要:
有 这样一种情况 ,看一个视频 用户分 normal, VIP ,SVIP abstract User { } Normal :User VIP:User SVIP :User 在子类中override User中的一些方法。 现在要求新的业务, 在VIP 中根据用户年龄段分别推送广告。 我 第一反 阅读全文
摘要:
策略模式应对业务处理中,会有多种相似处理方式(算法),然后封装成算法+抽象,此外,调用环节也有扩展要求的,来个context好处:算法封装,有抽象可以扩展; 调用环节转移,可以扩展;缺陷:上端必须知道全部算法,而且知道映射关系最终我们会解决问题,但是这个不属于策略模式 阅读全文