1 // Copyright (C) 2014-2019 CEA/DEN, EDF R&D
3 // This library is free software; you can redistribute it and/or
4 // modify it under the terms of the GNU Lesser General Public
5 // License as published by the Free Software Foundation; either
6 // version 2.1 of the License, or (at your option) any later version.
8 // This library is distributed in the hope that it will be useful,
9 // but WITHOUT ANY WARRANTY; without even the implied warranty of
10 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11 // Lesser General Public License for more details.
13 // You should have received a copy of the GNU Lesser General Public
14 // License along with this library; if not, write to the Free Software
15 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
20 #ifndef MODULEBASE_OPERATIONDESCRIPTION_H
21 #define MODULEBASE_OPERATIONDESCRIPTION_H
23 #include <ModuleBase.h>
24 #include <ModuleBase_Operation.h>
32 //class ModuleBase_ModelWidget;
35 * \class ModuleBase_OperationDescription
37 * Description of operation from XML
39 class MODULEBASE_EXPORT ModuleBase_OperationDescription
43 /// \param theId - the operation identifier
44 ModuleBase_OperationDescription(const QString& theId = "");
46 virtual ~ModuleBase_OperationDescription();
48 /// Unique name of the operation
49 /// \return string name of the operation.
50 const QString& operationId() const;
52 /// Returns a short description of operation (will be
53 /// inserted in title of property panel)
54 const QString& description() const;
56 /// Sets a short description of operation (will be
57 /// inserted in title of property panel)
58 void setDescription(const QString& theDescription);
60 /// Returns XML representation of the operation's widget.
61 /// \return XML QString
62 const QString& xmlRepresentation() const;
64 /// Sets XML representation of the operation's widget.
65 /// \param theXMLRepresentation - XML QString
66 void setXmlRepresentation(const QString& theXMLRepresentation);
68 /// Returns true if there are no model widgets
69 /// \return the boolean value
70 bool hasXmlRepresentation() const;
73 //!< Next fields could be extracted into a subclass;
74 /// the operation identifier
75 QString myOperationId;
77 /// the short description of the opertaion
78 QString myDescription;
80 /// the xml definition
81 QString myXmlRepresentation;
84 #endif //ModuleBase_OperationDescription_H