首页>
外国专利>
AUGMENTING AN ORIGINAL CLASS WITH AN AUGMENTING CLASS
AUGMENTING AN ORIGINAL CLASS WITH AN AUGMENTING CLASS
展开▼
机译:用增强类增强原始类
展开▼
页面导航
摘要
著录项
相似文献
摘要
An augmenting system for augmenting a program's original class with an augmenting class is provided. In some embodiments, the augmenting system receives a definition of an augmenting class that includes a data member. The augmenting system generates resolution code for the computer program. The resolution code is for accessing a reference to an original instance of the original class and providing a reference to a corresponding augmenting instance of the augmenting class. When processing a statement of the computer program that accesses the data member using the reference to the original instance, the augmenting system generates access code for the computer program. The access code uses the resolution code to retrieve the reference to the augmenting instance for the original instance and accesses the data member based on the retrieved reference to the augmenting instance.
展开▼