发明名称 Construction of object-oriented programming (OOP) patterns by behavior delegation
摘要 Object-oriented programming (OOP) design patterns are constructed at least partially by delegating their behaviors to preconstructed OOP patterns to implement the behaviors. A new OOP pattern having one or more behaviors is defined. Each of at least one of the behaviors is delegated to a preconstructed OOP pattern, the preconstructed OOP pattern therefore implementing the behavior. The new OOP pattern is thus constructed at least partially by delegating at least one of its behaviors to the preconstructed OOP patterns. Delegating a behavior to one of the preconstructed OOP patterns can be accomplished within a graphical user interface (GUI). Graphical representations of the new OOP pattern and of the preconstructed OOP patterns are displayed. Dragging the graphical representation of a selected preconstructed OOP pattern onto the graphical representation of the new OOP pattern causes a behavior of the new OOP pattern to be delegated to the selected preconstructed OOP pattern.
申请公布号 US8990766(B2) 申请公布日期 2015.03.24
申请号 US200511178871 申请日期 2005.07.10
申请人 International Business Machines Corporation 发明人 Schneider Scott E.
分类号 G06F9/44 主分类号 G06F9/44
代理机构 代理人 Josephs Damion
主权项 1. A method comprising: defining, using a computer program executed by a computing device, a new object-oriented programming (OOP) pattern having a first behavior and a second behavior, the new OOP pattern having one or more objects to implement the second behavior, the new OOP pattern not having any object to implement the first behavior; and, delegating, using the computer program executed by the computing device, the first behavior of the new OOP pattern to one of a plurality of preconstructed OOP patterns to implement the first behavior by the one of the preconstructed OOP patterns, wherein each behavior of the new OOP pattern has an expand method to perform the behavior of the pattern and an update method that listens for execution of the expand method and performs additional processing as a result, wherein delegating the first behavior to one of the preconstructed OOP patterns comprises attaching the one of the preconstructed OOP patterns to the update method of the new OOP pattern, such that the new OOP pattern is constructed at least in part by delegating the first behavior of the new OOP pattern to the one of the preconstructed OOP patterns, the one of the preconstructed OOP patterns having one or more objects to implement the first behavior, wherein the preconstructed OOP patterns are not subsidiary in any way to the new OOP pattern, except that the one of the preconstructed OOP patterns is delegated the first behavior of the new OOP pattern, such that the new OOP pattern is of equal hierarchical priority with respect to the preconstructed OOP patterns, wherein delegation of the first behavior of the new OOP pattern to the one of the preconstructed OOP pattern is different than and occurs at a higher hierarchical level than delegating functionality of any object to any other object, wherein the new OOP pattern and the preconstructed OOP patterns are at a higher hierarchical level than any objects that make up the new OOP pattern and the preconstructed OOP patterns, and each OOP pattern is defined as a set of constraint on any objects that make up the OOP pattern.
地址 Armonk NY US