On 4/17/16, 11:00 PM, "Harbs" <harbs.li...@gmail.com> wrote:
>OK. That helps. Thanks. > >If I would want to add a SWC to an FDT project as an extrern, do you know >what I should try to do? No idea. I would hope they have a place to put additional compiler arguments and you could add -external-library-path+=CSInterface.swc Or, there may be a "linkage" option like in FB where you set the library/swc to be external linkage. -Alex > >On Apr 18, 2016, at 7:12 AM, Alex Harui <aha...@adobe.com> wrote: > >> Any SWC can be an externs SWC. For the FalconJX compiler, it is just a >> SWC that goes on the external-library-path so that the compiler doesn't >> try to look for actual .JS implementation files. Anything on the >> external-library-path is assumed to have its implementation loaded some >> other way (or because it is built into the browser). >> >> But since no actual running code is needed in the SWC itself, the >>externs >> SWCs are full of definitions that have no implementation, but the API >> signature. >> >> We've create extern swcs in many different ways. Google gives us a >>bunch >> of .JS files for es3, es5, svg, etc. There are also .JS files for >>jquery >> and jasmine and google_maps. Michael Schmalle wrote the externC compile >> that converts .JS files to AS. For GCL, we hand-wrote the AS that >>matches >> the JS signatures. For CreateJS, we take CreateJS sources, run sed on >> them, then run them through externC. >> >> For CSInterface, you could: >> 1) just try running externC on it. >> 2) empty all of the function bodies and then run externC >> 3) just hand-port the signature to AS. >> >> HTH, >> -Alex >> >> >> On 4/17/16, 4:38 AM, "Harbs" <harbs.li...@gmail.com> wrote: >> >>> I’m still kind of fuzzy on how externs work. >>> >>> I decided to try to create a CC Extension using FlexJS as an >>>educational >>> exercise (and possibly as a prototype for others). >>> >>> I would like to add compiler checking for CSInterface[1], but I’m not >>> sure how to go about it. I tried looking for how Create.js was setup to >>> use as a guide, but I could not find/figure that out. >>> >>> Could someone give me some pointers? >>> >>> Thanks, >>> Harbs >>> >>> >>>[1]https://github.com/Adobe-CEP/CEP-Resources/blob/master/CEP_6.x/CSInte >>>rf >>> ace.js >> >