APM Entities(Implementation)
ListOfxy_coordinates *outline;
double width , length , total_diagonal ,
total_thickness , coefficient_of_thermal_bending;
// Attribute access functions
ListOfxy_coordinates *outline( void )
ListOfpwb_layer *layup( void )
// Attribute update functions
void outline(ListOfxy_coordinates *anOutline )
void layup( listOfpwb_layer *aListOfpwb_layer )
{ layup = aListOfpwb_layer };
void width( double aWidth )
}; // End of definition of class pwb
Notes:
- These EXPRESS definitions are then compiled to generate C++ code, which can be used by analysis applications to access the values of the attributes (regular and idealized) of the entities defined in the APM.
- As shown in this slide, the pwb entity defined in using EXPRESS becomes the C++ class pwb, and the attributes of this entity become member variables of the class.
- The EXPRESS to C++ compilation automatically generates member functions to access and update the values of the attributes.
- In addition to the access and update member functions, each WHERE rule defines one access function for each possible combination of inputs and outputs.
- For example, from wr1 in we could generate a member function that outputs the width given the outline of the board. Likewise, from the same WHERE rule we could generate another member function to perform the opposite operation; calculate the outline of the board given the width (although, in this case, the problem must be somehow constrained in order to be able to reach a unique solution).