[antlr-interest] ANTLR for Adobe Flash CS3? It is possible?

Heritiana Ravaka RAMASIMPANIRY rvkone at free.fr
Sat Apr 4 20:14:14 PDT 2009


Hello Dennis,
Yes, it is my first name.
The script is composed of simple command like the example (no conditional
'if' nor 'switch case');
I never consider the use of regular expression (mostly in php) but I'm gonna
check this way.
Thanks again.


-----Message d'origine-----
De : Dennis Benzinger [mailto:Dennis.Benzinger at gmx.net] 
Envoyé : samedi 4 avril 2009 23:11
À : Heritiana Ravaka RAMASIMPANIRY
Cc : antlr-interest at antlr.org
Objet : Re: [antlr-interest] ANTLR for Adobe Flash CS3? It is possible?

Hello Heritiana!

(Hope this is your first name :-)

Am 04.04.2009 20:16, Heritiana Ravaka RAMASIMPANIRY schrieb:
> Thanks for your answer.
> 
> I I did not understand the meaning of this framework.
> In fact, I want to use some sort of language recognition framework
> (grammar,scanner,parser) that can understand a script I would define
myself
> inside a fila as input.
> 
> Like for examples: 
> 
> // will add a button type 1 labeled 'str'
> BUTTON1 | {str:string}
> 
> // will add a button type 2 labeled 'str'
> BUTTON2 | {str:string}
> 
> //Will show a message 'str'in a defined zone
> MESSAGE | {str:string}
> 
> //will loop the animation to the top
> LOOP
> 
> I've found a framework which can do this at flashlr
> (code.google.com/p/flashlr/) but it is not ready yet to be used.
> 
> Can it be used for this kind of work?
> [...]

As it is not ready yet it's hard to tell. Probably yes, but if your
script is as simple as the examples you gave you won't need a real
parser. Perhaps some regular expression or simple string splitting are
sufficient. Looking at your examples it seems like everything up to the
pipe symbol is a command and the parameters for this command appear
after the pipe and are surrounded by braces. So you could first split
the string at the pipe, get the command, remove the braces from the
second part and get the parameters.


HTH,
Dennis Benzinger

No virus found in this incoming message.
Checked by AVG - www.avg.com 
Version: 8.0.238 / Virus Database: 270.11.41/2040 - Release Date: 04/03/09
17:54:00



More information about the antlr-interest mailing list