Community
Participate
Working Groups
Legacy tooling support three macros associated with capsule behaviour in the context of capsule redefinition: SUPER: points to the parent capsule SUPERMETHOD: points to the parent capsule's transition behaviour without parameters CALLSUPPER: points to the parent capsule's transition behaviour, passing in rtddata and rtport as parameters. Although these are potentially seldom used, they should still be provided as part of code generation.
Note: these are only provided for redefined behaviour.
For completeness I guess the SUPERMETHOD macro should be supported as well (even though I think it was never documented). Here is an example of how the code looks like that is produced by the legacy code generator: define SUPERMETHOD Capsule1_Actor::transition2_t1 #define CALLSUPER Capsule1_Actor::transition2_t1( rtdata, rtport ) INLINE_METHODS void Capsule2_Actor::transition2_t1( const void * rtdata, P::Base * rtport ) { //{{{USR platform:/resource/MultipleRedefineTest/MultipleRedefineTest.emx#_H2CBwu1KEeaIHN7A3CdPIA // Redefined effect code first t1 //}}}USR } #undef SUPERMETHOD #undef CALLSUPER #define SUPERMETHOD Capsule1_Actor::transition3_t1 #define CALLSUPER Capsule1_Actor::transition3_t1( rtdata, rtport ) INLINE_METHODS void Capsule2_Actor::transition3_t1( const void * rtdata, P::Base * rtport ) { //{{{USR platform:/resource/MultipleRedefineTest/MultipleRedefineTest.emx#_JCxhsu1KEeaIHN7A3CdPIA // Redefined effect code second t1 //}}}USR } #undef SUPERMETHOD #undef CALLSUPER