2
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

is-a, has-a 関係

Posted at

is-a 関係と has-a 関係というのは、オブジェクト指向に限った話ではないです。
一般的な物事の本質を捉えるための分析のしかた、考え方についてのメタファです。

is-a(分類法)

A is a B.
上の一文をみただけだと「is-a 関係 = 継承」と思うかもしれませんが、ちょっと違います。
分類法とは、物事を分類していくことで、その物事の本質を掴もうとする分析方法です。

has-a(分割法)

A has a B.
こちらも分類法同様に「has-a 関係 = 包含」ではありません。
分割法は、より小さく物事を分割していくことで、その物事の本質を掴もうとする分析方法です。

参考

2
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?