The authors describe a form of method-call interception (MCI) that allows the programmer to superimpose extra functionality onto method calls at run-time. They provide a reference semantics and a reference implementation for corresponding language constructs. The setup applies to class-based, statically typed, compiled languages such as Java. The semantics of MCI is used to direct a language implementation with a number of valuable properties: simplicity of the implementational model, run-time adaptation capabilities, static type safety, separate compilation and reasonable performance. The authors' implementational development employs source-code instrumentation. They start from a naive implementational model, which is subsequently refined to optimise program execution. The implementation is assessed via benchmarks.
Published in:
Software, IEE Proceedings -
(Volume:151
,
Issue:
2
)
Date of Publication: 5 April 2004