タグ

関連タグで絞り込む (0)

  • 関連タグはありません

タグの絞り込みを解除

object-oriented-programmingとpythonとmetaclassに関するnabinnoのブックマーク (2)

  • Metaclass - Wikipedia

    This article has multiple issues. Please help improve it or discuss these issues on the talk page. (Learn how and when to remove these messages) This article possibly contains original research. Please improve it by verifying the claims made and adding inline citations. Statements consisting only of original research should be removed. (September 2013) (Learn how and when to remove this message) T

  • メタクラス - Wikipedia

    オブジェクト指向プログラミングにおいてメタクラスとは、インスタンスがクラスとなるクラスのことである。通常のクラスがそのインスタンスの振る舞いを定義するように、メタクラスはそのインスタンスであるクラスを、そして更にそのクラスのインスタンスの振る舞いを定義する。全てのオブジェクト指向プログラミング言語でメタクラスが利用できるわけではない。利用できるものの中でもクラスの振る舞いが定義できる範囲は様々である。各言語はそれぞれ独自のメタオブジェクトプロトコル(MOP)を備えている[1]。メタオブジェクトプロトコルとは、クラスそのものの挙動をもオブジェクト指向のルールで記述し、初期化やインスタンス化のルール、実行状態の管理などをカスタマイズする機構である。Smalltalk、Common Lispが代表的である。 class Car(object): __slots__ = ['make', 'mod

  • 1