<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>设计模式 on 欢迎来到我的个人博客</title>
    <link>https://hugo-blog-1ij.pages.dev/tags/%E8%AE%BE%E8%AE%A1%E6%A8%A1%E5%BC%8F/</link>
    <description>Recent content from 欢迎来到我的个人博客</description>
    <generator>Hugo</generator>
    <language>zh-CN</language>
    
    <managingEditor>19398561589@163.com (胡宇琛)</managingEditor>
    <webMaster>19398561589@163.com (胡宇琛)</webMaster>
    
    <copyright>All articles on this blog are licensed under the BY-NC-SA license agreement unless otherwise stated. Please indicate the source when reprinting!</copyright>
    
    <lastBuildDate>Thu, 16 Apr 2026 00:00:00 +0000</lastBuildDate>
    
    
    <atom:link href="https://hugo-blog-1ij.pages.dev/tags/%E8%AE%BE%E8%AE%A1%E6%A8%A1%E5%BC%8F/index.xml" rel="self" type="application/rss&#43;xml" />
    

    
    

    <item>
      <title>摇摇晃晃的设计模式</title>
      <link>https://hugo-blog-1ij.pages.dev/post/design-pattern/</link>
      <pubDate>Thu, 16 Apr 2026 00:00:00 &#43;0000</pubDate>
      <author>19398561589@163.com (胡宇琛)</author>
      <guid>https://hugo-blog-1ij.pages.dev/post/design-pattern/</guid>
      <description>
        <![CDATA[<h1>摇摇晃晃的设计模式</h1><p>Author: 胡宇琛(19398561589@163.com)</p>
        
          <h1 id="摇摇晃晃的设计模式">
<a class="header-anchor" href="#%e6%91%87%e6%91%87%e6%99%83%e6%99%83%e7%9a%84%e8%ae%be%e8%ae%a1%e6%a8%a1%e5%bc%8f"></a>
摇摇晃晃的设计模式
</h1><h2 id="uml-基础">
<a class="header-anchor" href="#uml-%e5%9f%ba%e7%a1%80"></a>
UML 基础
</h2><p>UML 是统一建模语言，一种为面向对象系统的产品进行说明、可视化和编制文档的标准语言。</p>
<h3 id="事物">
<a class="header-anchor" href="#%e4%ba%8b%e7%89%a9"></a>
事物
</h3><p>事物是抽象化的最终结果，分为：</p>
        
        <hr><p>Published on 2026-04-16 at <a href='https://hugo-blog-1ij.pages.dev/'>欢迎来到我的个人博客</a>, last modified on 2026-04-16</p>]]>
      </description>
      
        <category>学习笔记</category>
      
    </item>
    
    

    <item>
      <title>一言难尽的重构学习笔记</title>
      <link>https://hugo-blog-1ij.pages.dev/post/%E4%B8%80%E8%A8%80%E9%9A%BE%E5%B0%BD%E7%9A%84%E9%87%8D%E6%9E%84%E5%AD%A6%E4%B9%A0%E7%AC%94%E8%AE%B0/</link>
      <pubDate>Thu, 16 Apr 2026 00:00:00 &#43;0000</pubDate>
      <author>19398561589@163.com (胡宇琛)</author>
      <guid>https://hugo-blog-1ij.pages.dev/post/%E4%B8%80%E8%A8%80%E9%9A%BE%E5%B0%BD%E7%9A%84%E9%87%8D%E6%9E%84%E5%AD%A6%E4%B9%A0%E7%AC%94%E8%AE%B0/</guid>
      <description>
        <![CDATA[<h1>一言难尽的重构学习笔记</h1><p>Author: 胡宇琛(19398561589@163.com)</p>
        
          <h1 id="一言难尽的重构学习笔记">
<a class="header-anchor" href="#%e4%b8%80%e8%a8%80%e9%9a%be%e5%b0%bd%e7%9a%84%e9%87%8d%e6%9e%84%e5%ad%a6%e4%b9%a0%e7%ac%94%e8%ae%b0"></a>
一言难尽的重构学习笔记
</h1><h2 id="1-什么是重构">
<a class="header-anchor" href="#1-%e4%bb%80%e4%b9%88%e6%98%af%e9%87%8d%e6%9e%84"></a>
1. 什么是重构
</h2><p>具体来说就是在不改变代码功能行为的情况下，对其内部结构的一种调整。需要注意的是，重构不是代码优化：</p>
<ul>
<li><strong>重构</strong>：注重的是提高代码的可理解性与可扩展性，对性能的影响可好可坏</li>
<li><strong>性能优化</strong>：让程序运行的更快，但最终的代码可能更难理解和维护</li>
</ul>
<h2 id="2-为什么要重构">
<a class="header-anchor" href="#2-%e4%b8%ba%e4%bb%80%e4%b9%88%e8%a6%81%e9%87%8d%e6%9e%84"></a>
2. 为什么要重构
</h2><h3 id="改善程序的内部设计">
<a class="header-anchor" href="#%e6%94%b9%e5%96%84%e7%a8%8b%e5%ba%8f%e7%9a%84%e5%86%85%e9%83%a8%e8%ae%be%e8%ae%a1"></a>
改善程序的内部设计
</h3><p>如果没有重构，在软件不停的版本迭代中，代码的设计只会越来越腐败，导致软件开发寸步难行。人们只为了短期目的而修改代码时，往往没有完全理解整体的架构设计（在大项目中常有这种情况，比如在不同的地方，使用完全相同的语句做着同样的事情），代码就会失去自己的结构。代码结构的流失具有累积效应，越难看出代码所代表的设计意图，就越难保护其设计。</p>
        
        <hr><p>Published on 2026-04-16 at <a href='https://hugo-blog-1ij.pages.dev/'>欢迎来到我的个人博客</a>, last modified on 2026-04-16</p>]]>
      </description>
      
        <category>学习笔记</category>
      
    </item>
    
  </channel>
</rss>
