Progress
ADM 2 Guide
Design Rules
This section summarizes the design rules for constructing a new SmartObject that inherits from the new class that you created. These rules are fairly simple; follow them to assure the right application structure.
The design rules are:
- Each SmartObject type (template) includes a primary include file that, by convention, has the same name as the template but with a .i extension. For example,
viewer.w
includes$DLC\src\adm2\viewer.i
.- Each primary include file such as
viewer.i
includes its parent’s support include file, plus its own property include file. For example,viewer.i
includesdatavis.i
, because a SmartDataViewer is a visual object that displays data, and alsoviewprop.i
, where the properties specific to SmartDataViewers are defined. It also starts the associated super procedure.- Each super procedure file includes its own property include file. These nest in such a way as to define all of the object properties in the proper order.
In addition, the presence of super procedures means that it is possible to run many internal procedures and user-defined functions in SmartObjects that are not actually present in those objects, but only in their super procedures.
- Each prototype file should include a prototype definition for each internal procedure and function that is implemented in a SmartObject’s super procedures. The contents of the prototype file are implementation dependent, so it is initially empty. Use the AppBuilder’s Pro*Tool ProtoGen to generate the prototype file based on your super procedure. For more information on the ProtoGen utility, see the online help.
Follow these rules when building a new SmartObject type, to ensure that all the relationships are established.
Copyright © 2004 Progress Software Corporation www.progress.com Voice: (781) 280-4000 Fax: (781) 280-4095 |