logo 有点笨有点猪
  • 关于
  • Base Knowledge
    • Artificial Intelligence
      • Generative AI
      • Reinforcement Learning
    • Compilation Principle
      • 1 Overview
      • 2 Lexical Analysis
      • 3 Syntax Analysis
      • 4 Syntax-Directed Translation
      • 5 Intermediate Code Generation
    • Computer Graphics
      • Geometry
      • Rendering
        • Games101
        • Games102
        • 实时光线追踪
        • 实时全局光照
        • 实时抗锯齿与超采样
        • 实时渲染中的工业界技术
        • 实时环境光照
        • 实时阴影
        • 实时高质量着色
      • Simulation
        • 刚体
        • 柔体
        • 流体
        • 碰撞检测
        • 质点-弹簧系统
    • Computer Network
      • 1 Overview
      • 2 Application Layer
      • 3 Transport Layer
      • 4 Network Layer
      • 5 Link Layer
    • Computer Organization
    • Data Structures & Algorithm
      • Basic Algorithm
        • Binary Lifting
        • Binary Search
        • Enumerate
        • Greedy
        • Recursion & Divide and Conquer
        • Sort
        • 前缀和 & 差分
      • Dynamic Programming
        • 动态规划
      • Graph
        • Traverse
      • Hash
      • Linear
      • Misc
      • String
      • Tree
        • Traverse
    • Operating system
      • 1 Overview
      • 2 并发
      • 3 虚拟化
      • 4 内核
      • 5 持久化
    • Z Reference Link
  • Programing
    • C&C++
      • C++对象模型
      • 实现双端队列
    • C#
    • Code Style
    • Cuda
    • Design Pattern
      • 1 Creational
        • 1 Factory Method 工厂方法
        • 2 Abstract Factory
        • 3 Builder
        • 4 Prototype
        • 5 Singleton
        • 6 Summary
      • 2 Structural
        • 1 Adapter
        • 2 Bridge
        • 3 Composite
        • 4 Decorator
        • 5 Facade
        • 6 Flyweight
        • 7 Proxy
        • 8 Summary
      • 3 Behavioral
        • 1 Chain of Responsibility
        • 10 Visitor
        • 11 Interpreter
        • 12 Summary
        • 2 Command
        • 3 Iterator
        • 4 Mediator
        • 5 Memento
        • 6 Observer
        • 7 State
        • 8 Strategy
        • 9 Template Method
    • Lua
      • 1 Overview
      • 2 Lua 5.x精要总结
      • 3 Lua GC
      • 4 Lua 虚拟机
      • 5 Lua 面向对象
    • Python
      • 1 Overview
    • Rust
      • 1 基础
    • Shell
      • 1 Overview
    • TypeScript
      • 1 Overview
    • Z Reference Link
  • Unreal Engine
    • AI
      • BehaviorTree
      • EnvironmentQuery
      • NavMesh
    • Animation
      • 动画状态机
    • Asset&Pak&Patch
    • Core
      • UObject
    • Debug
    • Editor Extension
    • GamePlay
      • Framwork
        • AGameModeBase
        • AGameStateBase
      • Game Ability System
        • AGameplayCueNotify_Actor
        • FGameplayTag
        • UAbilitySystemComponent
        • UAbilityTask
        • UAttributeSet
        • UGameplayAbility
        • UGameplayEffect
      • Replication
        • Optimization
        • Replication Graph
        • Significance Manager
    • Physics
    • Platform
      • Java Native Interface
      • Unreal Plugin Language
    • Profile
      • UE性能优化工具
      • Unity性能优化方向
    • Rendering
    • Sounds
    • UI
    • UnLua
      • Unlua指南
      • Unlua源码解析
    • Z Reference Link
  • Work Experience
    • Efficiency
      • UE Project Git Pull&Build
    • Security
      • 哈希函数
    • Serialization
      • Json
      • Protobuf
    • Z Reference Link
  • README

5 Singleton

单例模式: 保证系统中只存在一个实例。 解决对象的性能问题。 class Singleton {public: static Singleton* GetInstance(); static Singleton* m_Instance;private: Singleton(); Singleton( const Singleton& singleton );};// 线 ...
2025-08-10 Programing > Design Pattern > 1 Creational

5 Memento

备忘录模式:对象状态在转换过程中,可能存在 回溯 到之前某个状态的需求。实现对象状态的 保存与恢复,同时不破坏对象的封装性。在 不破坏封装性 的前提下,捕获 一个对象的 内部状态,并在 对象之外 进行 保存 ,且支持恢复。(已经不实用了,目前主流框架/语言,都有成熟的反射、序列化方案,可以更高效的实现备忘录模式) class Memento {private: // 不一定通过 ...
2025-08-10 Programing > Design Pattern > 3 Behavioral

5 Lua 面向对象

源码local recursionsetmetatablerecursionsetmetatable = function(t, index) local mt = getmetatable(t) if not mt then mt = {} end if not mt.__index then mt.__index = index ...
2025-08-10 Programing > Lua

5 Link Layer

...
2025-08-10 Base Knowledge > Computer Network

5 Intermediate Code Generation

...
2025-08-10 Base Knowledge > Compilation Principle

5 Facade

门面模式: 简化系统 内部 和 外部 的耦合。为子系统中的一组接口提供一个一致(稳定)的界面,定义了一个高层接口,使得更容易复用。达到一种 解耦 的效果。解决的是 架构 层面的设计,而不简单是一个类的设计。 ...
2025-08-10 Programing > Design Pattern > 2 Structural

4 内核

...
2025-08-10 Base Knowledge > Operating system

4 Syntax-Directed Translation

...
2025-08-10 Base Knowledge > Compilation Principle

4 Prototype

原型模式: 使用原型实例指定要创建对象的种类,并通过拷贝这些原型创建新的对象。对象的状态变化剧烈/创建复杂,需要记忆对象的状态。(对象池思想) class Abstract { virtual Abstract* Clone() { // 需要用 深拷贝 return new Abstract(*this); }; virtual ~Abstract() ...
2025-08-10 Programing > Design Pattern > 1 Creational

4 Network Layer

...
2025-08-10 Base Knowledge > Computer Network
<1…1112131415…17>
©2024-2026 Davids 总访问量 总访客数
Theme Node-Tree Powered by Hexo