IdentifiantMot de passe
Loading...
Mot de passe oublié ?Je m'inscris ! (gratuit)

QScxmlCompiler Class

The QScxmlCompiler class is a compiler for SCXML files.

Article lu   fois.

L'auteur

Liens sociaux

Viadeo Twitter Facebook Share on Google+   

QScxmlCompiler Class▲

  • Header: QScxmlCompiler

  • CMake:

    find_package(Qt6 REQUIRED COMPONENTS Scxml)

    target_link_libraries(mytarget PRIVATE Qt6::Scxml)

  • qmake: QT += scxml

Detailed Description▲

Parses an SCXML file and dynamically instantiates a state machine for a successfully parsed SCXML file. If parsing fails, the new state machine cannot start. All errors are returned by QScxmlStateMachine::parseErrors().

To load an SCXML file, QScxmlStateMachine::fromFile or QScxmlStateMachine::fromData should be used. Using QScxmlCompiler directly is only needed when the compiler needs to use a custom QScxmlCompiler::Loader.

Member Function Documentation▲

 

QScxmlCompiler::QScxmlCompiler(QXmlStreamReader *reader)▲

Creates a new SCXML compiler for the specified reader.

QScxmlCompiler::~QScxmlCompiler()▲

Destroys the SCXML compiler.

QScxmlStateMachine *QScxmlCompiler::compile()▲

Parses an SCXML file and creates a new state machine from it.

If parsing is successful, the returned state machine can be initialized and started. If parsing fails, QScxmlStateMachine::parseErrors() can be used to retrieve a list of errors.

QList<QScxmlError> QScxmlCompiler::errors() const▲

Returns the list of parse errors.

QString QScxmlCompiler::fileName() const▲

Returns the file name associated with the current input.

See Also▲

See also setFileName()

QScxmlCompiler::Loader *QScxmlCompiler::loader() const▲

Returns the loader that is currently used to resolve and load URIs for the SCXML compiler.

See Also▲

See also setLoader()

void QScxmlCompiler::setFileName(const QString &fileName)▲

Sets the file name for the current input to fileName.

The file name is used for error reporting and for resolving relative path URIs.

See Also▲

See also fileName()

void QScxmlCompiler::setLoader(QScxmlCompiler::Loader *newLoader)▲

Sets newLoader to be used for resolving and loading URIs for the SCXML compiler.

See Also▲

See also loader()

Vous avez aimé ce tutoriel ? Alors partagez-le en cliquant sur les boutons suivants : Viadeo Twitter Facebook Share on Google+