typesciprt command pattern
QT构建报错error: multiple target patterns
# QT构建报错error: multiple target patterns ## 原因 之前一直没有出过问题,但是在我修改了cmd的默认编码后,该问题出现了。原因就是使用`chcp 65001`命令修改cmd编码的方式每次会在命令行中输入`Active code page: 65001`这句话, ......
18) Mediator pattern
类别: Behavioral Pattern 问题: encapsulate [ɪn'kæpsjʊleɪt] enclose in a capsule or other small container define an object that encapsulates how a set of o ......
19) Memento pattern
类别: Behavioral Pattern (备忘录模式) 问题: 方案: 示例: import java.util.ArrayList; import java.util.List; public class MementoPatternDemo { public static void mai ......
20) Observer pattern
类别: Behavioral Pattern 问题: 方案1: 示例1: import java.util.ArrayList; import java.util.List; public class ObserverPatternDemo { public static void main(Str ......
23) Strategy pattern
类别: Behavior Pattern 问题: 方案: 示例: public class StrategyPatternDemo { public static void main(String[] args) { Context context = new Context(new Operati ......
24) Template pattern
类别: Behavior Pattern 问题: 方案: 示例: public class TemplatePatternDemo { public static void main(String[] args) { Game game = new Cricket(); game.play(); S ......
25) Visitor pattern
类别: Behavior Pattern visit ['vizit] the act of going to see some person or place or thing for a short time 问题: 方案: 示例: public class VisitorPatternDemo ......
26) MVC Pattern
类别: 问题: 方案: 示例: public class MVCPatternDemo { public static void main(String[] args) { // fetch student record based on his roll no from the database ......
22) Null Object pattern
类别: 问题: 方案: 示例: public class NullObjectPatternDemo { public static void main(String[] args) { Animal animal; animal = getAnimal("cat"); animal.makeSou ......
27) Business Delegate Pattern
类别: 问题: 方案: public class BusinessDelegatePatternDemo { public static void main(String[] args) { BusinessDelegate businessDelegate = new BusinessDelega ......
15) Command pattern
类别: Behavioral Pattern 问题: 方案: 示例: import java.util.ArrayList; import java.util.List; public class CommandPatternDemo { public static void main(String ......
11) Facade Pattern
类别: Structural Pattern 问题/动机: 系统非常复杂 隐藏复杂细节,提供简单界面 方案: 示例: /* Complex parts */ public class FacadePatternDemo { public static void main(String[] args) ......
12) Flyweight Pattern
类别: Structural Pattern 问题/动机: 假若绿色是相同部分,占用1M内存 ,如果提取出来,众对象共享其内容,只占1M内存 ,否则占10M ,且随着对象增多,占用越来越多内存 ,无疑是浪费资源 A flyweight is an object that minimizes memo ......
13) Proxy Pattern
类别: Structural Pattern 问题: 操纵一个对象时碍手碍脚,与装饰者模式不同之处: 装饰者是接口方法,授权小 代理则是整个类,授权大 方案: 示例: public class ProxyPatternDemo { public static void main(final Stri ......
16) Interpreter pattern
类别: behavioral pattern 问题: Polish notation https://en.wikipedia.org/wiki/Polish_notation Abstract syntax tree https://en.wikipedia.org/wiki/Abstract_s ......
17) Iterator pattern
类别: behavioral pattern 问题: Provide a way to access the elements of an aggregate object sequentially without exposing its underlying representation. 方案 ......
14) chain of responsibility pattern
类别: behavioral pattern 问题: 高耦合,不灵活 if(){ }else if(){ }else if(){ } ... 方案: 示例: public class ChainOfResponsibilityPattern { public static void main(Str ......
cpp: Visitor Pattern
/*****************************************************************//** * \file Gold.h * \brief 访问者模式 Visitor Pattern C++ 14 行为模式 * 2023年6月8日 涂聚文 Geovi ......
Excel DDE Commands
#! https://zhuanlan.zhihu.com/p/635569763 # Excel DDE Commands ## 连接参数 `Application`: `Excel` `Topic`: `System`: 整个应用。 [sheetname] 指定 worksheet。 我使用的是 ......
automake-1.16: 未找到命令 command not found
错误内容: /home/qrry/gine/missing: 行 81: automake-1.16: 未找到命令 WARNING: 'automake-1.16' is missing on your system. You should only need it if you modified ......
cpp: Chain Of Responsibility Pattern
/*****************************************************************//** * \file PayrollProcessing.h * \brief 责任链模式Chain Of Responsibility Pattern 亦称: 职 ......
el-dropdown @command事件传参
``` Dropdown List Action 1 Action 2 Action 3 Action 4 Action 5 ``` ``` ``` ......
【Checkpoint】Command for log's checkpoint - SQLserver, Oracle, PostgreSQL
## 文档引子 最近,SQLserver环境中的SQL always on 因事务爆满 导致磁盘持续告警, 通过这次事件,记载下SQLserver AG的事务日志处理的正确方式,同时也把Oracle以及PG的相关的checkpoint问题一并做个简单的总结,并且只从结果的角度给出过程,至于具体的理论 ......
cpp: Memento Pattern
/*****************************************************************//** * \file ActorMemento.h * \brief 备忘录模式 Memento Pattern亦称:快照、Snapshot、Memento C++ ......
compiler expression pattern match
编译器中经常需要用到pattern match。 那么如何实现呢? 比较直观的方法是使用递归。 以pattern match: y= a * (b + c) 为例。 首先,将其解析成一个抽象语法树:* a + b c 其次,递归match: match(y, pattern) => match(y, ......
解决mac os m1使用pyinstller报错 command not found的问题
## 今天需要在一个m1的机器上使用pyinstaller打包一个python程序,报错command not found - 于是通过```pip3 install pyinstaller```,安装成功后依然无法找到命令,但通过pip3 show pyinstaller 却是有正常输出,说明已经 ......
3) Singleton pattern
类别: creational Pattern 问题/动机: 反复创建对象开销巨大耗时长消耗内存/重复使用 方案: 示例: // 1 class Demo1 { public final static Demo1 INSTANCE = new Demo1(); private Demo1() { if ......
4) Builder Pattern
类别: Creational pattern 问题: 构造函数入参超长易变 方案: 示例: public class BuilderPatternDemo { public static void main(String[] args) { Car.Builder builder = new Car ......
5) Prototype Pattern
类别: Creational Pattern 问题: 不想修改原对象状态,但需要依据当前数据进行计算 方案: 示例: public class PrototypePattern { public static void main(String[] args) { Movie movie = new ......
6) Adapter Pattern
类别: Structural Pattern 问题: 什么是接口?按照标准提供服务,其他想要使用该接口的要按照该标准接入服务 什么是依赖?持有目标对象,拥有使用权(A use B) 数据线?数据线按USB标准接入充电宝,通过lightning 提供充电服务 手机?通过lightning标准接入数据线 ......