-
Notifications
You must be signed in to change notification settings - Fork 16
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to load and manipulate ThingML models #95
Comments
If I understannd correctly you need to process ThingML models to transform them to a timed automata. Instead of going through a serialization in XML of the ThingML program you can use our parser and directly process the model in JAVA to transform it to whatever representation you need. I have create a sample JAVA project which gives an example of how you can load a ThingML model and then traverse it to generate "something". You can find it at: Let us know if it works for you Cheers! |
Thanks for your prompt response and kindness for writing an example to show me how to load a ThingML model and transform it to some kind of new formalism I need. It's too late here(almost 11:00 pm) in China. I will let you know if it works me as soon as I can. Thanks again! Cheers! |
Hello, |
It seems you cannot access our Maven repository (maybe because of some firewall). Try accessing this address in a web browser first to see if you can indeed access it. |
Sure. I can open "http://maven.thingml.org/" |
Can you try to clone the whole ThingML repository first and |
Ok, for some reason your maven process was not able to access the server when you tried compiling, that is why you got the message "Connection to http://maven.thingml.org refused: Connection refused". You should try again now that you have access to the server and if you get the same message it means that something on your machine is presenting the maven process from reaching the server. The easiest may be try re-install maven or try on another machine. |
Brice's solution of cloning and building ThingML locally may also work but I believe that it will still require to have access to our repository so you really have to make sure that the maven process can acess the internet and our server. If you can get access to our server with your web browser, it means that it is a problem on your side and not with the server. |
I'd better turn off on the firewall and get myself a VPN to see if it works. |
Hey, I am also interested in doing something work on ThingML. Could any of you send me a new site on how to do that? https://github.com/HEADS-project/training/tree/master/1.ThingML_Basics/7.%20ReadThingMLModel doesn't work any more... |
Hi Brice,
When I was running the project provided at https://github.com/HEADS-
project/training/tree/79d92e02eaee41a548dd7ee3448ccc
6b9642cc6e/1.ThingML_Basics/7.ReadThingMLModel, I encountered the following
problem.
Loading input file:
C:\GenerateThingML\models\Basics\Timer\PingPong.thingml...
org/antlr/runtime3_4_0/Lexer
java.lang.NoClassDefFoundError: org/antlr/runtime3_4_0/Lexer
at
org.sintef.thingml.resource.thingml.mopp.ThingmlResource.<init>(ThingmlResource.java:166)
at
org.sintef.thingml.resource.thingml.mopp.ThingmlResourceFactory.createResource(ThingmlResourceFactory.java:25)
at
org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.createResource(ResourceSetImpl.java:425)
at
org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.createResource(ResourceSetImpl.java:414)
at ReadThingML.main(ReadThingML.java:33)
Caused by: java.lang.ClassNotFoundException: org.antlr.runtime3_4_0.Lexer
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
... 5 more
I didn't use maven here, but I have included all the jar file needed
(including org.sintef.thingml.resource.thingml_0.7.0.201612211920.jar and
org.sintef.thingml.model_0.7.0.201612211920 .jar in my project).
Do you have any idea how to fix that problem?
Simon
…On Tue, Jun 14, 2016 at 1:13 PM, Brice Morin ***@***.***> wrote:
https://github.com/HEADS-project/training/tree/
79d92e0/1.ThingML_Basics/7.
ReadThingMLModel
—
You are receiving this because you modified the open/close state.
Reply to this email directly, view it on GitHub
<#95 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe/AONZJX3orx6JauWqvkwzwR08JWC8N-4Yks5qLjiBgaJpZM4Gp1es>
.
|
I'm writing this post to ask you something about ThingML.
My current work is trying to translate ThingML project to the input of some timed automata tool for some academic purpose, so it's necessary for me to know how to save ThingML as a systematic form(LIKE XML) to extract all the information in an ordered way. Is that possible? IF possible, what should I do?
I'm looking forward to your reply and any detailed information will be great help.
The text was updated successfully, but these errors were encountered: