文档下载 文档下载导航
设为首页 | 加入收藏
搜索 请输入内容:  
 导航当前位置: 文档下载 > 所有分类 > 1 Malaj A Multi Aspect LAnguage for Java
侵权投诉

1 Malaj A Multi Aspect LAnguage for Java

Aspect-oriented programming [1] (AOP) tries to provide linguistic mechanisms to factor out design concerns, which can be defined, understood, and evolved separately from the functional core of the application. A first approach to AOP can be the definition

Ad-hocConstructsforNonFunctional

Aspects

MattiaMonga

PolitecnicodiMilano–DipartimentodiElettronicaeInformazione

PiazzaLeonardodaVinci,32I20133Milano–Italy

monga@elet.polimi.it

June2000

1

Malaj:AMultiAspectLAnguageforJava

tem,againhinderingcomprehensionandevolution.

Weclaimthatsuchlimitationsarein-trinsictoallgeneralsolutionstotheprob-lemandwesuggesttoprede nethesetofaspectsanAOLshoulddealwith,pro-vidingad-hocAOLs(oneforeachaspect)withconstructssupportinglimitedvisibil-ityofcertainfeaturesofthefunctionalmoduletowhichthedi erentaspectsap-ply.InourMalaj(MultiAspectLAn-guageforJava)wede neanAOLspe-ci cforsynchronisationandonespeci cfordistributionandmobility.

Aspect-orientedprogramming[1](AOP)triestoprovidelinguisticmechanismstofactoroutdesignconcerns,whichcanbede ned,understood,andevolvedsepa-ratelyfromthefunctionalcoreoftheap-plication.A rstapproachtoAOPcanbethede nitionofageneral-purposeAspect-OrientedLanguage(AOL)withfullvisi-bilityoftheinternaldetailsofitsassoci-atedfunctionalmodule.Inourpreviouswork[2,3]weanalysedAspectJ[4]–anAOPfollowingthisapproach–andcametotheconclusionthatitviolatesobject-orientedprinciplesofprotectionanden-capsulation,thushinderingreuse.An-otherapproach,followedbyHyper/J[5],isbasedontheideaofpartitioningasoft-waresysteminsmallatomicunits,thatcanbeaggregatedaccordingtodi erentdimensionsofconcern.Wefoundthatthenumberofconnectionsamongunitsincreasestheoverallintricacyofthesys-

1.1

TheSynchronisationAspect

Functionalunitsshouldbeprogrammedwithoutfocusingontheirsynchronisation:asecondstepcouldclearlystatewhathap-penswhenafunctionalunitisinvoked.Threecasesmayarise:

1.thecallviolatessomepreconditionandanexceptionisreturnedtothe

1

第1页

你可能喜欢

热门文档

相关文档

站点地图 | 文档上传 | 侵权投诉 | 手机版
本站所有资源均来自互联网,本站只负责收集和整理,均不承担任何法律责任,如有侵权等其它行为请联系我们.
文档下载 Copyright 2013 doc.guandang.net All Rights Reserved.  -  email