Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. How to access SCXML parse results?
Forum Updated to NodeBB v4.3 + New Features

How to access SCXML parse results?

Scheduled Pinned Locked Moved Unsolved General and Desktop
6 Posts 4 Posters 815 Views 2 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • C Offline
    C Offline
    ColonelPanic
    wrote on last edited by
    #1

    Hello,
    I would like to use the SCXML Modeling editor to create state charts and then later on parse those and then work with the results, I don't need a running state machine.

    I guess, I could still use something like XMLStreamReader to parse the file,
    but was wondering if somehow QScxmlParser could be used to parse the file and return all states or all transitions or all attributes for a state or the defined events for a transition, and so on.

    What I see is all you can do is instantiate a state machine, the parse method description of QScxmlParser could use some more details as well "parses an SCXML file", well where to,
    where are the results, is there a sytax tree somewhere?
    Thank you for your time and trouble.

    All the best

    Philip.

    JonBJ 1 Reply Last reply
    0
    • C ColonelPanic

      Hello,
      I would like to use the SCXML Modeling editor to create state charts and then later on parse those and then work with the results, I don't need a running state machine.

      I guess, I could still use something like XMLStreamReader to parse the file,
      but was wondering if somehow QScxmlParser could be used to parse the file and return all states or all transitions or all attributes for a state or the defined events for a transition, and so on.

      What I see is all you can do is instantiate a state machine, the parse method description of QScxmlParser could use some more details as well "parses an SCXML file", well where to,
      where are the results, is there a sytax tree somewhere?
      Thank you for your time and trouble.

      All the best

      Philip.

      JonBJ Offline
      JonBJ Offline
      JonB
      wrote on last edited by
      #2

      @ColonelPanic
      I presume the answer is: it's not documented because they don't intend you to use it, else they would document it. It does whatever it needs to do internally, and you get to instantiate a machine..

      1 Reply Last reply
      0
      • SGaistS Offline
        SGaistS Offline
        SGaist
        Lifetime Qt Champion
        wrote on last edited by
        #3

        Hi and welcome to devnet,

        Do you mean like Qt Creator's state machine editor ?

        Interested in AI ? www.idiap.ch
        Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

        C 1 Reply Last reply
        0
        • SGaistS SGaist

          Hi and welcome to devnet,

          Do you mean like Qt Creator's state machine editor ?

          C Offline
          C Offline
          ColonelPanic
          wrote on last edited by
          #4

          @SGaist No, that is what I used to create the state machine; I want methods to parse the file, like getAllStates(), getEvents(transition) and so on. I am looking for Qt C++ methods, not for an editor.

          Pablo J. RoginaP 1 Reply Last reply
          0
          • C ColonelPanic

            @SGaist No, that is what I used to create the state machine; I want methods to parse the file, like getAllStates(), getEvents(transition) and so on. I am looking for Qt C++ methods, not for an editor.

            Pablo J. RoginaP Offline
            Pablo J. RoginaP Offline
            Pablo J. Rogina
            wrote on last edited by
            #5

            @ColonelPanic maybe you're looking for the qscxmlc tool?

            Upvote the answer(s) that helped you solve the issue
            Use "Topic Tools" button to mark your post as Solved
            Add screenshots via postimage.org
            Don't ask support requests via chat/PM. Please use the forum so others can benefit from the solution in the future

            1 Reply Last reply
            0
            • SGaistS Offline
              SGaistS Offline
              SGaist
              Lifetime Qt Champion
              wrote on last edited by
              #6

              Since it's the editor, you can take a look at its sources to see how it accesses the data you are interested in.

              Interested in AI ? www.idiap.ch
              Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

              1 Reply Last reply
              0

              • Login

              • Login or register to search.
              • First post
                Last post
              0
              • Categories
              • Recent
              • Tags
              • Popular
              • Users
              • Groups
              • Search
              • Get Qt Extensions
              • Unsolved