1 // Copyright (C) 2007-2010 CEA/DEN, EDF R&D, OPEN CASCADE
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.
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 // VISU OBJECT : interactive object for VISU entities implementation
21 // File : VISU_ResultUtils.hh
22 // Author : Alexey PETROV
25 #ifndef __VISU_RESULT_UTILS_H__
26 #define __VISU_RESULT_UTILS_H__
28 #include "VISU_Result_i.hh"
29 #include "SALOME_Event.h"
35 //----------------------------------------------------------------------------
36 struct TUpdateObjBrowser: public SALOME_Event
39 CORBA::Boolean* myIsDone;
40 TUpdateObjBrowser(const int theStudyId, CORBA::Boolean* theIsDone);
48 //----------------------------------------------------------------------------
53 TResultManager(Result_i* theResult);
59 //----------------------------------------------------------------------------
60 struct TTransactionManager
62 _PTR(StudyBuilder) myStudyBuilder;
64 TTransactionManager(_PTR(Study) theStudyDocument);
66 ~TTransactionManager();
70 //----------------------------------------------------------------------------
72 GenerateName(const std::string& theName);
75 //----------------------------------------------------------------------------
77 SplitName(const std::string& theName,
79 std::string& theSuffix,
80 char theDelimeter = ':');
83 //----------------------------------------------------------------------------
85 MakeFileName(const std::string& theName,
86 const void* thePointer);
89 //----------------------------------------------------------------------------
91 BuildEntities(Result_i* theResult,
92 Result_i::PInput theInput,
93 CORBA::Boolean* theIsDone,
94 const std::string& theResultEntry,
95 CORBA::Boolean theIsAtOnce,
96 CORBA::Boolean theIsBuildGroups,
97 CORBA::Boolean theIsBuildFields,
98 CORBA::Boolean theIsBuildParts,
99 _PTR(Study) theStudy);
102 //----------------------------------------------------------------------------
104 BuildGroups(Result_i* theResult,
105 Result_i::PInput theInput,
106 CORBA::Boolean* theIsDone,
107 CORBA::Boolean theIsBuild,
108 CORBA::Boolean theIsAtOnce,
109 _PTR(Study) theStudy);
112 //----------------------------------------------------------------------------
114 BuildFields(Result_i* theResult,
115 Result_i::PInput theInput,
116 CORBA::Boolean* theIsDone,
117 CORBA::Boolean theIsBuild,
118 CORBA::Boolean theIsAtOnce,
119 _PTR(Study) theStudy);
122 //----------------------------------------------------------------------------
124 BuildMinMax(Result_i* theResult,
125 Result_i::PInput theInput,
126 CORBA::Boolean* theIsDone,
127 CORBA::Boolean theIsBuild);
130 //----------------------------------------------------------------------------
132 BuildFieldDataTree(Result_i* theResult,
133 Result_i::PInput theInput,
134 CORBA::Boolean* theIsFieldsDone,
135 CORBA::Boolean theIsBuildFields,
136 CORBA::Boolean* theIsMinMaxDone,
137 CORBA::Boolean theIsBuildMinMax,
138 _PTR(Study) theStudy);
140 //----------------------------------------------------------------------------
142 RemoveFile(const std::string& theFileName,
143 bool theRemoveEmptyDir = true);
145 //----------------------------------------------------------------------------
147 CopyFile(const std::string& theSourceFileName,
148 const std::string& theTargetFileName);
150 //----------------------------------------------------------------------------
154 #endif // __VISU_RESULT_UTILS_H__