<rt id="bn8ez"></rt>
<label id="bn8ez"></label>

  • <span id="bn8ez"></span>

    <label id="bn8ez"><meter id="bn8ez"></meter></label>

    gembin

    OSGi, Eclipse Equinox, ECF, Virgo, Gemini, Apache Felix, Karaf, Aires, Camel, Eclipse RCP

    HBase, Hadoop, ZooKeeper, Cassandra

    Flex4, AS3, Swiz framework, GraniteDS, BlazeDS etc.

    There is nothing that software can't fix. Unfortunately, there is also nothing that software can't completely fuck up. That gap is called talent.

    About Me

     

    AS3-DI-Metadata

    What a Metamess

    Spring Actionscript, Dawn, SmartyPants, Swiz, Spicelib (used by Parsley) and SwiftSuspenders (used by Robotlegs) perform Dependency Injection.

    Moreover they can all perform automatic DI by parsing class metadata. It would be grand if the common DI related metadata tags could be standardised. That way we really could write code that is decoupled from any particular framework.

    Injection by Type

    Dawn, Swiz, Spicelib, SwiftSuspenders, SmartyPants: [Inject] (above property, setter or method)
    Spring AS: [Autowire] (above property, setter or method)

    Most popular

    [Inject] by 5

    Notes

    [Inject] is clear and simple and used by almost all of the libraries. It also directly correlates to @Inject from the JSR-330 Dependency Injection for Java specification. Let’s use it.

    Injection by Name/Id

    Dawn, SwiftSuspenders, SmartyPants: [Inject(name=“SomeName”)] (above property, setter or method)
    Swiz: [Inject(source=“SomeName”)] (above property, setter or method)
    Spicelib: [Inject(id=“SomeName”)] (above property, setter or method)
    Spring AS: [Autowired(name=“SomeName”)] (above property, setter or method)

    Most popular

    [Inject(name=“SomeName”)] by 3

    Notes

    Since you can define default attributes best practice could be to leave out the attribute: [Inject(“SomeName”)]

    Constructor Injection:

    SwiftSuspenders: [Inject] (above class)
    Spicelib: [InjectConstructor] (above class)
    Swiz, Spring AS, Dawn: ?

    Most popular

    ?

    Notes

    I don’t see the need for an extra tag ([InjectConstructor]) when we could simply use [Inject].

    Object Lifecycle – Post Injection:

    Dawn, SwiftSuspenders, SmartyPants, Swiz: [PostConstruct] (above method)
    Spicelib: [Init] (above method)

    Most popular

    [PostConstruct] by 4

    Notes

    @PostConstruct is used in Java for the same purpose. Let’s use the most popular, established one.

    Object Lifecycle – Teardown:

    SwiftSuspenders, SmartyPants, Dawn: none?
    Swiz: [PreDestroy] (above method)
    Spicelib: [Destroy] (above method)

    Most popular

    Notes

    @PreDestroy is used in Java for the same purpose. Let’s use the most familiar, established one.

    Factory/Provider:

    SwiftSuspenders, SmartyPants, Swiz: none?
    Dawn: [Provider] (above method)
    Spicelib: [Factory] (above method)

    posted on 2010-11-12 14:44 gembin 閱讀(534) 評(píng)論(0)  編輯  收藏 所屬分類: ActionScript3

    導(dǎo)航

    統(tǒng)計(jì)

    常用鏈接

    留言簿(6)

    隨筆分類(440)

    隨筆檔案(378)

    文章檔案(6)

    新聞檔案(1)

    相冊(cè)

    收藏夾(9)

    Adobe

    Android

    AS3

    Blog-Links

    Build

    Design Pattern

    Eclipse

    Favorite Links

    Flickr

    Game Dev

    HBase

    Identity Management

    IT resources

    JEE

    Language

    OpenID

    OSGi

    SOA

    Version Control

    最新隨筆

    搜索

    積分與排名

    最新評(píng)論

    閱讀排行榜

    評(píng)論排行榜

    free counters
    主站蜘蛛池模板: 亚洲乱码一区av春药高潮| 羞羞漫画在线成人漫画阅读免费| 亚洲AV日韩综合一区| a国产成人免费视频| 手机在线看永久av片免费| 中文字幕不卡亚洲| 色偷偷亚洲女人天堂观看欧| 特级毛片A级毛片100免费播放| 中文字幕免费高清视频| 亚洲精品美女久久久久99小说| 亚洲成a人片7777| 久久精品成人免费国产片小草| 好男人www免费高清视频在线| 国产亚洲精午夜久久久久久| 91在线亚洲综合在线| 在线观看肉片AV网站免费| 国产极品美女高潮抽搐免费网站| 亚洲天堂视频在线观看| 免费大片黄在线观看| 性做久久久久久免费观看| 久久精品国产亚洲av四虎| 免费大片av手机看片高清| 99久久这里只精品国产免费| 国产日韩亚洲大尺度高清| 精品久久亚洲一级α| 久久经典免费视频| 亚洲av无码潮喷在线观看| 男女交性无遮挡免费视频| 免费a级毛片无码a∨蜜芽试看| 亚洲va在线va天堂va888www| 添bbb免费观看高清视频| a毛片基地免费全部视频| 亚洲精品自产拍在线观看动漫| 免费人成视频在线播放| 最近中文字幕无吗免费高清 | 亚洲日韩乱码中文字幕| 99热在线免费观看| 国产亚洲无线码一区二区| 黄色免费网站在线看| 日韩在线免费电影| 亚洲色大成网站www|