v2.0.0
Loading...
Searching...
No Matches
mna_op_schema.h
Go to the documentation of this file.
1//=============================================================================================================
30
31#ifndef MNA_OP_SCHEMA_H
32#define MNA_OP_SCHEMA_H
33
34//=============================================================================================================
35// INCLUDES
36//=============================================================================================================
37
38#include "mna_global.h"
39#include "mna_types.h"
40
41//=============================================================================================================
42// QT INCLUDES
43//=============================================================================================================
44
45#include <QString>
46#include <QStringList>
47#include <QVariant>
48#include <QMetaType>
49#include <QList>
50
51//=============================================================================================================
52// FORWARD DECLARATIONS
53//=============================================================================================================
54
55namespace MNALIB { struct MnaNode; }
56
57//=============================================================================================================
58// DEFINE NAMESPACE MNALIB
59//=============================================================================================================
60
61namespace MNALIB
62{
63
64//=============================================================================================================
75
76//=============================================================================================================
81{
82 QString name;
83 QMetaType::Type type;
84 bool required = false;
85 QVariant defaultValue;
86 QString description;
87};
88
89//=============================================================================================================
96{
97public:
98 QString opType;
99 QString version;
100 QString binding;
101 QString category;
102 QString description;
103 QString library;
104 QString executable;
105 QString cliTemplate;
106
107 QList<MnaOpSchemaPort> inputPorts;
108 QList<MnaOpSchemaPort> outputPorts;
109 QList<MnaOpSchemaAttr> attributes;
110
118 bool validate(const MnaNode& node, QStringList* errors = nullptr) const;
119};
120
121} // namespace MNALIB
122
123#endif // MNA_OP_SCHEMA_H
Export/import macros, build-info accessors, and MNALIB namespace anchor for the MNE Analysis Containe...
#define MNASHARED_EXPORT
Definition mna_global.h:47
Enums and string-conversion helpers for the MNA container vocabulary (file roles, data kinds,...
MNE Analysis Container Format (mna/mnx).
MnaDataKind
Definition mna_types.h:89
Single executable step in an MNA pipeline graph, with attributes, typed ports, exec mode,...
Definition mna_node.h:75
QString name
Port name.
bool required
Must be connected?
QString description
Human-readable description.
MnaDataKind dataKind
Expected data kind.
QVariant defaultValue
Default when not set.
QMetaType::Type type
Expected value type.
QString description
Human-readable description.
QString name
Attribute key.
bool required
Must be set?
Operation schema for graph validation.
QList< MnaOpSchemaPort > outputPorts
Expected output ports.
QString binding
Binding type: "internal", "cli", or "script".
QList< MnaOpSchemaPort > inputPorts
Expected input ports.
QList< MnaOpSchemaAttr > attributes
Expected attributes.
QString category
Category: "io", "preprocessing", "source_estimation", etc.
bool validate(const MnaNode &node, QStringList *errors=nullptr) const
QString opType
Operation type string.
QString version
Version of the operation (e.g. "2.2.0").
QString executable
For CLI ops: executable name (e.g. "recon-all").
QString library
Which library provides the implementation.
QString description
What the operation does.
QString cliTemplate
For CLI ops: command template with {{placeholder}} tokens.