<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>gothedistance</author_name>
  <author_url>https://blog.hatena.ne.jp/gothedistance/</author_url>
  <blog_title>Life is Really Short, Have Your Life!!</blog_title>
  <blog_url>https://aroundthedistance.hatenadiary.jp/</blog_url>
  <categories>
  </categories>
  <description>まぁ昔こんな事を書いた。 切っても切れない状態管理 - Life is Really Short, Have Your Life!! フラグで状態を表してしまうとフラグの数だけ分岐が増えるのでうんこなので、基本的には値を書き換えていく形にしたらいいよね、というもの。プログラムが知っておくべき事は、「次に何をすればいいのか」だけなんだから、状態をオブジェクトにして追い出してコマンドを実行できる状態にすれば吉。新しい状態が増えても既存コードに与える影響は少なくできる。Stateパターンを導入しましょう、というこっちゃ。 ただONとOFFしかないものに限って言えば、0と1でいいんじゃないかしらとも思…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Faroundthedistance.hatenadiary.jp%2Fentry%2F2010%2F12%2F24%2F111000&quot; title=&quot;フラグと状態管理その２ - Life is Really Short, Have Your Life!!&quot; class=&quot;embed-card embed-blogcard&quot; scrolling=&quot;no&quot; frameborder=&quot;0&quot; style=&quot;display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;&quot;&gt;&lt;/iframe&gt;</html>
  <image_url></image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2010-12-24 11:10:00</published>
  <title>フラグと状態管理その２</title>
  <type>rich</type>
  <url>https://aroundthedistance.hatenadiary.jp/entry/2010/12/24/111000</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
