<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/"><channel><title>面向对象 on Jeanphilo Blog</title><link>https://shio-chan-dev.github.io/jeanblog/zh/tags/%E9%9D%A2%E5%90%91%E5%AF%B9%E8%B1%A1/</link><description>Recent content in 面向对象 on Jeanphilo Blog</description><generator>Hugo -- 0.159.2</generator><language>zh-cn</language><lastBuildDate>Sat, 24 Jan 2026 15:42:47 +0800</lastBuildDate><atom:link href="https://shio-chan-dev.github.io/jeanblog/zh/tags/%E9%9D%A2%E5%90%91%E5%AF%B9%E8%B1%A1/index.xml" rel="self" type="application/rss+xml"/><item><title>闭包和类的共同点：为什么它们都能“携带状态”</title><link>https://shio-chan-dev.github.io/jeanblog/zh/dev/language/closures-vs-classes/</link><pubDate>Sat, 24 Jan 2026 15:42:47 +0800</pubDate><guid>https://shio-chan-dev.github.io/jeanblog/zh/dev/language/closures-vs-classes/</guid><description>对比闭包与类的共同点与差异，解释它们如何封装状态。</description></item><item><title>用多态替换 if：把流程判断变成对象职责</title><link>https://shio-chan-dev.github.io/jeanblog/zh/dev/design/replace-if-with-polymorphism/</link><pubDate>Sat, 24 Jan 2026 15:42:47 +0800</pubDate><guid>https://shio-chan-dev.github.io/jeanblog/zh/dev/design/replace-if-with-polymorphism/</guid><description>通过对象职责拆分，消除重复 if 判断。</description></item><item><title>用多态替换 switch：让代码更符合开闭原则</title><link>https://shio-chan-dev.github.io/jeanblog/zh/dev/design-patterns/replace-switch-with-polymorphism/</link><pubDate>Sat, 24 Jan 2026 15:42:47 +0800</pubDate><guid>https://shio-chan-dev.github.io/jeanblog/zh/dev/design-patterns/replace-switch-with-polymorphism/</guid><description>通过策略模式消除 switch 语句，降低分支扩展成本。</description></item><item><title>多继承 vs 多接口：对“正交性”的影响</title><link>https://shio-chan-dev.github.io/jeanblog/zh/dev/language/multiple-inheritance-vs-interfaces-orthogonality/</link><pubDate>Sat, 24 Jan 2026 13:08:42 +0800</pubDate><guid>https://shio-chan-dev.github.io/jeanblog/zh/dev/language/multiple-inheritance-vs-interfaces-orthogonality/</guid><description>对比多继承与多接口对正交性与复杂度的影响，并给出实践建议。</description></item><item><title>为什么组合优于继承：灵活性、可测试性与演进成本</title><link>https://shio-chan-dev.github.io/jeanblog/zh/dev/design-patterns/composition-over-inheritance/</link><pubDate>Sat, 24 Jan 2026 12:40:32 +0800</pubDate><guid>https://shio-chan-dev.github.io/jeanblog/zh/dev/design-patterns/composition-over-inheritance/</guid><description>解释“组合优于继承”的工程原因，并给出可运行示例与落地步骤。</description></item></channel></rss>