QScxmlCompiler Class | Qt SCXML (original) (raw)

The QScxmlCompiler class is a compiler for SCXML files. More...

Header: #include
CMake: find_package(Qt6 REQUIRED COMPONENTS Scxml) target_link_libraries(mytarget PRIVATE Qt6::Scxml)
qmake: QT += scxml

Public Types

Public Functions

Member Function Documentation

QScxmlCompiler::QScxmlCompiler(QXmlStreamReader *reader)

Creates a new SCXML compiler for the specified reader.

[noexcept] 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 setFileName().

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

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

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 fileName().

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

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

See also loader().

© 2025 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.