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. scxml dynamic load use case
Forum Updated to NodeBB v4.3 + New Features

scxml dynamic load use case

Scheduled Pinned Locked Moved Solved General and Desktop
7 Posts 3 Posters 779 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.
  • W Offline
    W Offline
    wpmccormick
    wrote on last edited by
    #1

    What is the use case for dynamically loading an scxml?

    After a quick look over the QScxml* classes, I don't see methods for managing changes (new/removed states, transitions, events, etc.) after loading a new statemachine.

    Without such methods, it's not clear how to manage such change.

    Thanks!

    1 Reply Last reply
    0
    • W Offline
      W Offline
      wpmccormick
      wrote on last edited by
      #7

      Sure did, but that I can see, none of those projects make use of dynamically loading some changed Scxml. Sure, they load one up dynamically, but once it's loaded it's done. Some of the examples even load from a resource file; so to me, that makes it even less dynamic.

      I did find a use case however that's fairly straightforward: A generic state machine loader that does nothing more than publish known and active states, and processes events.

      I'd sure appreciate it if you could try to answer some of my outstanding questions here, perhaps with some example.

      Thanks!

      1 Reply Last reply
      0
      • mrjjM Offline
        mrjjM Offline
        mrjj
        Lifetime Qt Champion
        wrote on last edited by
        #2

        Hi
        You mean something like
        https://doc.qt.io/qt-5/qtscxml-trafficlight-widgets-dynamic-example.html
        but without knowing anything about the state it has?

        1 Reply Last reply
        0
        • W Offline
          W Offline
          wpmccormick
          wrote on last edited by wpmccormick
          #3

          Yes, exactly. In fact, that is the example I've been playing with. I can see how that QScxmlStateMachine::stateNames would list all (most?) states. But how to list all transitions? Other things like initial, final, history?

          mrjjM 1 Reply Last reply
          0
          • W wpmccormick

            Yes, exactly. In fact, that is the example I've been playing with. I can see how that QScxmlStateMachine::stateNames would list all (most?) states. But how to list all transitions? Other things like initial, final, history?

            mrjjM Offline
            mrjjM Offline
            mrjj
            Lifetime Qt Champion
            wrote on last edited by
            #4

            @wpmccormick
            Hi
            Sorry, your question floated away.
            Im not sure there is such interface.
            Some of the info might be available via
            https://doc.qt.io/qt-5/qscxmltabledata.html

            1 Reply Last reply
            0
            • W Offline
              W Offline
              wpmccormick
              wrote on last edited by
              #5

              An example of how to use the class would be very helpful.

              jsulmJ 1 Reply Last reply
              0
              • W wpmccormick

                An example of how to use the class would be very helpful.

                jsulmJ Online
                jsulmJ Online
                jsulm
                Lifetime Qt Champion
                wrote on last edited by
                #6

                @wpmccormick Did you check here https://doc.qt.io/qt-5/examples-qtscxml.html ?

                https://forum.qt.io/topic/113070/qt-code-of-conduct

                1 Reply Last reply
                0
                • W Offline
                  W Offline
                  wpmccormick
                  wrote on last edited by
                  #7

                  Sure did, but that I can see, none of those projects make use of dynamically loading some changed Scxml. Sure, they load one up dynamically, but once it's loaded it's done. Some of the examples even load from a resource file; so to me, that makes it even less dynamic.

                  I did find a use case however that's fairly straightforward: A generic state machine loader that does nothing more than publish known and active states, and processes events.

                  I'd sure appreciate it if you could try to answer some of my outstanding questions here, perhaps with some example.

                  Thanks!

                  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