Salome HOME
fix coding style
[modules/shaper.git] / src / ModelAPI / ModelAPI_Events.h
index 68af75b1b4acf3bff1ec651e78b4f172531ac338..fccf6e24002965de8378e7c4553460eb6808d3b3 100644 (file)
@@ -121,7 +121,7 @@ MAYBE_UNUSED static const char * EVENT_VISUAL_ATTRIBUTES = "UpdateVisualAttribut
 
 
 /// Event ID that 1D-fillet failed (comes with ModelAPI_ShapesFailedMessage)
-static const char * EVENT_OPERATION_SHAPES_FAILED = "OperationShapesFailed";
+MAYBE_UNUSED static const char * EVENT_OPERATION_SHAPES_FAILED = "OperationShapesFailed";
 
 /// Message that feature was changed (used for Object Browser update): moved, updated and deleted
 class MODELAPI_EXPORT ModelAPI_ObjectUpdatedMessage : public Events_MessageGroup
@@ -356,8 +356,8 @@ class ModelAPI_ParameterEvalMessage : public Events_Message
 /// Message to ask compute the positions of parameters in the expression
 class ModelAPI_ComputePositionsMessage : public Events_Message
 {
-  std::string myExpression; ///< the expression string
-  std::string myParamName; ///< name of the parameter to be searched
+  std::wstring myExpression; ///< the expression string
+  std::wstring myParamName; ///< name of the parameter to be searched
   std::list<std::pair<int, int> > myPositions; ///< computation result: start-end position indices
 
 public:
@@ -372,7 +372,7 @@ public:
   /// Useful method that creates and sends the AttributeEvalMessage event
   /// Returns the message, processed, with the resulting fields filled
   MODELAPI_EXPORT static std::shared_ptr<ModelAPI_ComputePositionsMessage>
-    send(const std::string& theExpression, const std::string& theParameter, const void* theSender)
+    send(const std::wstring& theExpression, const std::wstring& theParameter, const void* theSender)
   {
     std::shared_ptr<ModelAPI_ComputePositionsMessage> aMessage =
       std::shared_ptr<ModelAPI_ComputePositionsMessage>(
@@ -389,11 +389,11 @@ public:
   MODELAPI_EXPORT virtual ~ModelAPI_ComputePositionsMessage();
 
   /// Returns an expression stored in the message
-  MODELAPI_EXPORT const std::string& expression() const;
+  MODELAPI_EXPORT const std::wstring& expression() const;
   /// Returns a parameter name stored in the message
-  MODELAPI_EXPORT const std::string& parameter() const;
+  MODELAPI_EXPORT const std::wstring& parameter() const;
   /// Sets an expression and parameter needed for computation
-  MODELAPI_EXPORT void set(const std::string& theExpression, const std::string& theParameter);
+  MODELAPI_EXPORT void set(const std::wstring& theExpression, const std::wstring& theParameter);
   /// Sets the results of processing
   MODELAPI_EXPORT void setPositions(const std::list<std::pair<int, int> >& thePositions);
   /// Returns the results of processing: position start and end indices
@@ -404,8 +404,8 @@ public:
 class ModelAPI_ObjectRenamedMessage : public Events_Message
 {
   ObjectPtr myObject;
-  std::string myOldName;
-  std::string myNewName;
+  std::wstring myOldName;
+  std::wstring myNewName;
 
  public:
   /// Static. Returns EventID of the message.
@@ -418,8 +418,8 @@ class ModelAPI_ObjectRenamedMessage : public Events_Message
 
   /// Useful method that creates and sends the AttributeEvalMessage event
   MODELAPI_EXPORT static void send(ObjectPtr theObject,
-                                   const std::string& theOldName,
-                                   const std::string& theNewName,
+                                   const std::wstring& theOldName,
+                                   const std::wstring& theNewName,
                                    const void* theSender);
 
   /// Creates an empty message
@@ -432,13 +432,13 @@ class ModelAPI_ObjectRenamedMessage : public Events_Message
   /// Sets an object
   MODELAPI_EXPORT void setObject(ObjectPtr theObject);
   /// Returns an old name
-  MODELAPI_EXPORT std::string oldName() const;
+  MODELAPI_EXPORT std::wstring oldName() const;
   /// Sets an old name
-  MODELAPI_EXPORT void setOldName(const std::string& theOldName);
+  MODELAPI_EXPORT void setOldName(const std::wstring& theOldName);
   /// Returns a new name
-  MODELAPI_EXPORT std::string newName() const;
+  MODELAPI_EXPORT std::wstring newName() const;
   /// Sets a new name
-  MODELAPI_EXPORT void setNewName(const std::string& theNewName);
+  MODELAPI_EXPORT void setNewName(const std::wstring& theNewName);
 };
 
 /// Message that the parameter should be replaced with its value