5.1.5:GetProp Handlers

GetProp(プロパティ取得)ハンドラ

Each getProp handler begins with the
getProp control structure followed by the name of the custom property that this handler corresponds to. The handler ends with the end control structure and the name of the property. getProp handlers look like this:

getProp
ハンドラは必ず「getProp」コントロール構造で始まり、その後ろにこのハンドラが反応すべきカスタム・プロパティ名が続きます。getPropハンドラは必ずプロパティ名が後に続く「end」コントロール構造で終わります。getPropハンドラは以下のようになります:



     getProp myCustomProperty
       return the scroll of me + 20
     end myCustomProperty



A getProp handler is executed whenever the value of the corresponding custom property is requested by a Transcript statement. You can write a getProp handler for any custom property of the object or another object lower in the message hierarchy. For more information, see the section on
Custom Properties.

getProp
ハンドラは、トランスクリプト記述によりこのハンドラが必要とするカスタム・プロパティの値が要求された時にはいつでも実行されます。オブジェクトのどのカスタム・プロパティに対しても、或いはメッセージ階層の下位にある他のオブジェクトのカスタム・プロパティに対しても、getPropハンドラを使うことができます。詳細についてはCustom Propertiesセクションをご覧下さい。