Hey Max, I really appreciate your time and help on this. I apologize in advance if I'm asking too much. Feel free to tell me that I need to go figure it out on my own. But let me address your comments...
Quote:
hmm...you can always install your own tool and call out to it to get what you want/need.
This is basically what I'm trying to do. I would like to write a class that will do the things that $pojo is doing that are specific to Java and don't quite have the same syntax for ActionScript. I understand from the documentation how to load my class, I just don't know where to start on writing it. That's why I was asking about extending the POJO classes. I don't really know what libraries, imports, etc I need to write this helper class.
Quote:
getJavaTypeName - what is needed here ?
This function returns Java types that are mapped from the hibernate type. I need to define a map for ActionScript types, and return the ActionScript type (so the function would be getActionScriptTypeName) For example, my IDs are put as 'java.math.BigDecimal', where I would want the ActionScript primitive type 'Number'
Quote:
generateImports - you do know that if you do $pojo.importType('blablah') will generate an import for you ?
I did not know that... that definitely helps. What I don't understand is how $pojo (or the ImportContext) knows all the types used in the class. I saw from the code that it is somehow filling the 'imports' TreeSet, but doesn't the imports section happen before the 'Fields' or 'PropertyAccessors' ? How do I generate or keep track of the list of imports necessary? Using generateImports() I get java imports like:
import java.math.BigDecimal;
import java.util.HashSet;
import java.util.Set;
where I would want
import mx.collections.ArrayCollection
Quote:
getExtendsDeclaration - here you could add extra imports in hbm.xml; but i guess you don't want those into your java code...
Yeah, I think this one will solve itself, as I think all my hibernate classes will inherit from a common custom class of my own. In this way, I'll only have to correct the 'java.io.Serializable' extends on one class (the base class).
I think I could solve a lot of my problems with a "search and replace" task after the code generation, but if I could do this the "right" way, I think I'd be 99% there on generating ActionScript classes.
Thanks in advance,
Thunder[/quote]