| Author |
Message |
|
brainy
Member
Joined: Fri Mar 16, 2007 6:37 am Posts: 46
|
 Flex Intrinsic Classes [Flex2 & Flex3/AIR]
Hey,
I recently wrote a small utility to reverse engineer the actionscript reference documentation into intrinsic classes, complete with javadoc comments.
Here's the result:
[update]You should get the FD3 compatible intrinsics provided at this thread[/update]
I welcome any comments.
Last edited by brainy on Sun Jan 20, 2008 2:13 am, edited 4 times in total.
|
| Thu May 03, 2007 11:38 pm |
|
 |
|
twalling
Member
Joined: Fri Feb 17, 2006 3:39 pm Posts: 49 Location: Boston
|
That's great. Your utility will make it easy to keep up to date with any changes/additions to the API. How difficult is it to generate the XML definitions file needed for MXML completion? I tried my best to look at the release notes in 2.01 to update the current completion file, but it's possible I missed a few things.
Here's the current one:
http://flashdevelop.org/downloads/releases/Flex201_MXML_definition.zip
_________________ Tim
http://timwalling.com
|
| Fri May 04, 2007 12:34 am |
|
 |
|
Philippe
Admin
Joined: Wed Aug 31, 2005 7:27 am Posts: 7470 Location: Paris, France
|
Good job -- but that's exactly how Ben Clinkinbeard created the AS3 intrinsic classes:
http://www.returnundefined.com/fdas3/
He also extracted the comments but the problem is that we are not sure about the legal issues: are we just allowed to redistribute parts of the documentation? We think that Macromedia's (website) EULA doesn't allow it, and I'm not sure Adobe is more friendly.
One idea we had would be to not distribute intrinsics with the javadoc comments but a tool which will read the online documentation and update the intrinsics accordingly. However I'm not sure if it's totally ok.
|
| Fri May 04, 2007 7:55 am |
|
 |
|
brainy
Member
Joined: Fri Mar 16, 2007 6:37 am Posts: 46
|
I never thought my trick was something new, the point here are the Apollo instrinsic classes, which to the best of my knowledge have never yet been completely extracted.
Ben's tool is, apparently, missing in action: http://tech.groups.yahoo.com/group/apol ... essage/900
Also, it seems that besides having javadoc comments, my flex instrinsic coverage is a bit more complete.
Finally, if distribution of the docs ever becomes an issue, I can distribute the utility instead. Because the docs are available for anyone to download, anyone could produce their own classes complete with javadoc comments.
|
| Fri May 04, 2007 12:18 pm |
|
 |
|
Philippe
Admin
Joined: Wed Aug 31, 2005 7:27 am Posts: 7470 Location: Paris, France
|
You did an awesome job Brainy, the generated code is great -- I didn't mean to offend you. I just was wondering if you had seen Ben's posts about his work (and our legal discussions).
But anyway I didn't know he lost the sources so that's cool
We will include the AS3 intrinsics in FD3 so it may be usefull to use your updated files. Or maybe it should be a version without comments + your tool.
|
| Fri May 04, 2007 12:35 pm |
|
 |
|
brainy
Member
Joined: Fri Mar 16, 2007 6:37 am Posts: 46
|
Oh no worries, no offense taken at all 
|
| Fri May 04, 2007 4:02 pm |
|
 |
|
zeus
Member
Joined: Tue Nov 08, 2005 5:49 pm Posts: 190 Location: Silicon Valley
|
Philippe wrote: We will include the AS3 intrinsics in FD3
Have you given up on understanding the bytecode from the SWCs in the SDK?
_________________ Josh
zeuslabs.us
|
| Fri May 04, 2007 5:46 pm |
|
 |
|
Philippe
Admin
Joined: Wed Aug 31, 2005 7:27 am Posts: 7470 Location: Paris, France
|
zeus wrote: Philippe wrote: We will include the AS3 intrinsics in FD3 Have you given up on understanding the bytecode from the SWCs in the SDK?
Of course not - but for the moment my SWC parser doesn't work (it's a port of abcdump.as, included in the swfOp sub-project in the SVN).
Also there are no way to include javadoc comments in SWCs 
|
| Fri May 04, 2007 7:20 pm |
|
 |
|
Philippe
Admin
Joined: Wed Aug 31, 2005 7:27 am Posts: 7470 Location: Paris, France
|
Hey brainy, you included the mx classes intrinsics while their source is included in the Flex 2 SDK. I suppose you can omit them.
Ah, it is very tempting to include them in FD3...
|
| Sun May 06, 2007 2:59 pm |
|
 |
|
twalling
Member
Joined: Fri Feb 17, 2006 3:39 pm Posts: 49 Location: Boston
|
So is there an easy solution to generating the XML completion file or not?
_________________ Tim
http://timwalling.com
|
| Mon May 07, 2007 1:18 am |
|
 |
|
brainy
Member
Joined: Fri Mar 16, 2007 6:37 am Posts: 46
|
I'll look into it.
|
| Mon May 07, 2007 9:27 am |
|
 |
|
mpetty
Member
Joined: Tue Apr 03, 2007 6:30 pm Posts: 5
|
Depending on what you wrote the utility in (plus your feelings of generosity at the moment) are you able to let loose the utility?
Various flex libraries have source code, but don't have intrinsic files to go along with it (one being darron, doug, and mike's flexlib on google). Would be nice to make it complete so to speak, with auto-completion for IDE's.
MTASC seems to be able to do it, but only for as2.
|
| Mon May 07, 2007 5:31 pm |
|
 |
|
brainy
Member
Joined: Fri Mar 16, 2007 6:37 am Posts: 46
|
I'll be releasing the tool as soon as I get a chance. In the meanwhile, you could browse through the ones I've released to look for any glitches that could be fixed prior to that 
|
| Mon May 07, 2007 6:54 pm |
|
 |
|
brainy
Member
Joined: Fri Mar 16, 2007 6:37 am Posts: 46
|
The intrinsic classes for Flex 3/AIR are available at this thread
Last edited by brainy on Sun Jan 20, 2008 2:14 am, edited 1 time in total.
|
| Thu Jul 05, 2007 12:58 pm |
|
 |
|
Philippe
Admin
Joined: Wed Aug 31, 2005 7:27 am Posts: 7470 Location: Paris, France
|
brainy, for technical reasons the root package.as should be renamed to toplevel.as or it may be missed by the completion.
|
| Thu Jul 05, 2007 1:24 pm |
|
|