Defining the Application Interface of the Prototype
The application interface is the set of attributes that you can set and retrieve from the application. These attributes determine the external appearance of the prototype. You define these by adding attributes in the Interface page of the Group Inspector panel.
1. Choose Edit > New Attribute. A new attribute “Unnamed” appears.
2. Click Unnamed and then type threshold, thereby renaming the attribute from Unnamed to threshold.
3. In the Type column, click String twice, or press F2. A combo box appears, letting you choose the type of the attribute. Select Value > Float to specify that your attribute will be of type Float.
4. To set a default value of 30 in the Value column, click the 0 in the threshold attribute row and type 30.
Leave the default settings in the last three columns: P is depressed indicating that your attribute will be public; R is depressed indicating that your attribute will be persistent; N is not depressed indicating that your attribute will not notify others of its changes.
5. To create another attribute named temperature, select Edit > New Attribute. Rename Unnamed to temperature.
6. Set its type to Int by opening the combo box in the Type column and selecting Value > Int.
7. Finally, this temperature attribute should notify others of its changes. Therefore, click the N button in the last column to set it.
Note: It is important to define the threshold attribute before the temperature attribute, because the behavior of temperature depends on the value of threshold. |
Version 6.0
Copyright © 2015, Rogue Wave Software, Inc. All Rights Reserved.