资源描述:
《一种动态角色模型及其实现机制》由会员上传分享,免费在线阅读,更多相关内容在教育资源-天天文库。
1、ISSN1000-9825,CODENRUXUEWE-mail:jos@iscas.ac.cnJournalofSoftwarehttp://www.jos.org.cndoi:10.3724/SP.J.1001.2010.03846Tel/Fax:+86-10-62562563©byInstituteofSoftware,theChineseAcademyofSciences.Allrightsreserved.∗一种动态角色模型及其实现机制1,32+1,41唐祖锴,彭智勇,任毅,崔晓军1(武汉大学
2、软件工程国家重点实验室,湖北武汉430072)2(武汉大学计算机学院,湖北武汉430072)3(武汉理工大学计算机科学与技术学院,湖北武汉430063)4(通信指挥学院网络管理中心,湖北武汉430010)DynamicRoleModelanditsImplementation1,32+1,41TANGZu-Kai,PENGZhi-Yong,RENYi,CUIXiao-Jun1(StateKeyLaboratoryofSoftwareEngineering,WuhanUniversity,Wuhan43
3、0072,China)2(ComputerSchool,WuhanUniversity,Wuhan430072,China)3(SchoolofComputerScienceandTechnology,WuhanUniversityofTechnology,Wuhan430063,China)4(NetworkManagementCenter,CommunicationandCommandingAcademy,Wuhan430010,China)+Correspondingauthor:E-mail:
4、peng@whu.edu.cnTangZK,PengZY,RenY,CuiXJ.Dynamicrolemodelanditsimplementation.JournalofSoftware,2010.http://www.jos.org.cn/1000-9825/3846.htmAbstract:Therearelimitationswithmostofthecurrentrolemodels.Forexample,theissuesofrolecreationandattachmenthavetob
5、ehandledexplicitlyinthesourcecode:thenavigationbetweenroleobjectsandsourceobjectsisunidirectional,andmessagescannotbetransferredbi-directionally,etc.Suchlimitationsalwaysresultinthecorebusinessbecomingtangledwiththecontrollogicforroleobjects.Adynamicrol
6、emodel,namedDR,canprovidetheautomaticcreatinganddestroyingmechanismsofroleobjectsandcanalsoprovidethebi-directionalnavigationbetweenroleobjectsandsourceobjects.Thesefunctionalitiesmakeupthecoreoftheuseoftherolemodel,andthecontrollogicforroleobjectsisals
7、otransparenttousers.TheimplementationofDRiscenteredaroundprepositveobjectsanddelegationmechanismsnotonlyresolvesthecomplexhierarchyofrolesproblem,butthedynamicrolemodelalsosolvesthecompatibilityproblemwithtraditionalobject-orientedsystems.Keywords:role;
8、dynamicrolemodel;delegation;prepositveobject;objectdeputymodel摘要:很多角色模型的设计和使用存在着一些限制,例如:角色对象的创建及其与源对象的绑定需要通过编码显式完成;角色对象与源对象之间的单向链接使得消息不能在它们之间互相转发等.这些限制使得角色模型的使用较为繁琐,在程序设计中往往会将系统的业务逻辑和对角色对象的控制逻辑混杂在一起.被称为DR的动态角色模型除了相关工作的基本功能外还提供了角色