Nomenclature/ja: what changed
Revision 0 to 1. Removed lines have a minus sign; added lines have a plus sign.
Title: Nomenclature/ja
| Old | New | Line | |
|---|---|---|---|
| 1 | + | - プロパティに動詞は割り当てられません。名詞が割り当てられます。 | |
| 2 | + | - メソッドには動詞が割り当てられます。 | |
| 3 | + | - "GetFoo"という名前のメソッドはプロパティ"Foo"を取得するためのものです。 | |
| 4 | + | - "SetFoo"という名前のメソッドはプロパティ"Foo"を取得するためのものです | |
| 5 | + | - "DoFoo"という名前のメソッドはイベント"OnFoo"を呼び出すためのものです | |
| 6 | + | - 提案: あるプロパティを更新したり、有効にするためには"DoSetFoo"を使うより"UpdateFoo"を使う方が望ましいと思われます。 | |
| 7 | + | - イベントプロパティはOn〜と命名されるべきです。その後に修飾語や形容詞が続き、最後に述語や主語、名詞がきます。例えば「OnFilterRecord, OnPostError, OnDblClick」といったようにです。 | |
| 8 | + | - TControlから派生したものへの通知は、CNxxxという名前にします。 | |
| 9 | + | ||
| 10 | + | (訳注 user:saeka:多分、ControlへのVCLメッセージに相当するものだと思います。ControlNotificationの略でしょう) | |
| 11 | + | ||
| 12 | + | --- | |
| 13 | + | *From the Free Pascal wiki, page "Nomenclature/ja", as it stood on 2013-12-24 after a change by Yuichiro Takahashi, out of the wiki's dump of 2024-05-26. Copyright stays with the author who wrote it, according to the old wiki's [[Licensing]] page. If you have concerns about this material, [message the admin](/wiki-contact).* | |
| 14 | + | Category: Coding style/ja | |
| 15 | + | Category: FPC/ja | |
| 16 | + | Category: Lazarus/ja |
