Closed vega0 closed 1 year ago
interface makes me work in frame of class and enum generators. Can it in frame of file ? with import and package directives.
is it possible to determine the type of "if" definition as normal and ternary.
Reflaxe does have the ability to output files manually if you'd prefer that! In my Reflaxe/C++ project, I return null
for the compileClass/Enum functions so they don't generate anything automatically.
Instead, I store the output in an array. Using the BaseCompiler.onCompileEnd
function, I can then output everything manually using the BaseCompiler.appendToExtraFile(filename: String, output: String)
.
In Reflaxe/C++ specifically, I use BaseCompiler.addCompileEndCallback
at the end of generating the class to do this, but you don't have to.
is it possible to recognize 'if' is ternary or not?
is it possible to get import instructions of file ?
Reflaxe does have the ability to output files manually if you'd prefer that! In my Reflaxe/C++ project, I return
null
for the compileClass/Enum functions so they don't generate anything automatically.Instead, I store the output in an array. Using the
BaseCompiler.onCompileEnd
function, I can then output everything manually using theBaseCompiler.appendToExtraFile(filename: String, output: String)
.In Reflaxe/C++ specifically, I use
BaseCompiler.addCompileEndCallback
at the end of generating the class to do this, but you don't have to.
two questing above.
Sorry for missing your two questions. If you have any general questions, I would highly recommend asking in the "Reflaxe" project forum on the Haxe Discord server.
is it possible to recognize 'if' is ternary or not?
I'm afraid not, this is a limitation built into the Haxe compiler.
is it possible to get import instructions of file ?
The Haxe compiler does not provide this information; you have to keep track of which classes are used in a module and create the imports yourself.
By default reflaxe creates separately objects into multiple files. It is possible to get information about imports and packages? It is possible to create file metadata info to assembly anything from one file into one file. ?