1 // Copyright (C) 2003 CEA/DEN, EDF R&D
5 // File : VISU_Result_i.hh
6 // Author : Alexey PETROV
9 #ifndef __VISU_RESULT_I_H__
10 #define __VISU_RESULT_I_H__
12 #include "VISUConfig.hh"
14 class vtkUnstructuredGridReader;
15 class vtkUnstructuredGrid;
21 class Result_i : public virtual POA_VISU::Result,
22 public virtual Storable
25 Result_i(const Result_i &);
27 Result_i(SALOMEDS::Study_ptr theStudy);
30 virtual VISU::VISUType GetType() { return VISU::TRESULT;};
32 typedef VISU_Convertor InputType;
33 typedef vtkUnstructuredGridReader OutputType;
40 virtual Storable* Build();
42 virtual Storable* Create(const char* theFileName);
43 virtual Storable* Create(SALOMEDS::SObject_ptr theMedSObject);
44 virtual Storable* Create(SALOME_MED::FIELD_ptr theField);
45 virtual Storable* Restore(SALOMEDS::SObject_ptr theSObject,
46 const string& thePrefix, const Storable::TRestoringMap& theMap)
47 throw(std::logic_error&);
48 virtual void ToStream(std::ostringstream& theStr);
49 virtual const char* GetComment() const;
50 static const string myComment;
51 InputType* GetInput() { return myInput;}
52 const char* GetName() const { return myName.c_str();}
53 const QFileInfo& GetFileInfo() const { return myFileInfo;}
54 int IsRestored() const { return myIsRestored;}
56 SALOMEDS::SObject_var mySObject;
57 SALOMEDS::Study_var myStudyDocument;
58 SALOMEDS::SComponent_var mySComponent;
60 string GetRefFatherEntry();
62 const SALOMEDS::SObject_var& GetSObject() const;
63 const SALOMEDS::Study_var& GetStudyDocument() const;
64 const SALOMEDS::SComponent_var& GetSComponent() const;
66 Storable* ResultRestore(SALOMEDS::SObject_ptr theSObject,
67 const string& thePrefix, const Storable::TRestoringMap& theMap)
68 throw(std::logic_error&);
69 Result_var FindResult(SALOMEDS::SObject_ptr theSObject);
70 QString GenerateName(const string& theFmt, int theId);
71 void WriteToFile(vtkUnstructuredGrid* theDataSet, const string& theFileName);