Salome HOME
Copyrights update
[modules/yacs.git] / src / SALOMEDSClient / SALOMEDSClient_Study.hxx
1 // Copyright (C) 2005  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
2 // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
3 // 
4 // This library is free software; you can redistribute it and/or
5 // modify it under the terms of the GNU Lesser General Public
6 // License as published by the Free Software Foundation; either 
7 // version 2.1 of the License.
8 // 
9 // This library is distributed in the hope that it will be useful 
10 // but WITHOUT ANY WARRANTY; without even the implied warranty of 
11 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU 
12 // Lesser General Public License for more details.
13 //
14 // You should have received a copy of the GNU Lesser General Public  
15 // License along with this library; if not, write to the Free Software 
16 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
17 //
18 // See http://www.salome-platform.org/
19 //
20 //  File   : SALOMEDSClient_Study.hxx
21 //  Author : Sergey RUIN
22 //  Module : SALOME
23
24 #ifndef __SALOMEDSClient_STUDY_H__
25 #define __SALOMEDSClient_STUDY_H__
26
27 #include <vector>
28 #include <string>
29
30 #include "SALOMEDSClient_definitions.hxx"
31 #include "SALOMEDSClient_SComponentIterator.hxx"
32 #include "SALOMEDSClient_StudyBuilder.hxx"
33 #include "SALOMEDSClient_SObject.hxx"
34 #include "SALOMEDSClient_SComponent.hxx"
35 #include "SALOMEDSClient_UseCaseBuilder.hxx"
36 #include "SALOMEDSClient_AttributeStudyProperties.hxx"
37 #include "SALOMEDSClient_ChildIterator.hxx"
38
39 class SALOMEDSClient_Study
40 {
41
42 public:
43   virtual ~SALOMEDSClient_Study() {}
44
45   virtual std::string GetPersistentReference() = 0;
46   virtual std::string GetTransientReference() = 0;
47   virtual bool IsEmpty() = 0;
48   virtual _PTR(SComponent) FindComponent (const std::string& aComponentName) = 0;
49   virtual _PTR(SComponent) FindComponentID(const std::string& aComponentID) = 0;
50   virtual _PTR(SObject) FindObject(const std::string& anObjectName) = 0;
51   virtual std::vector<_PTR(SObject)> FindObjectByName( const std::string& anObjectName, const std::string& aComponentName ) = 0;  
52   virtual _PTR(SObject) FindObjectID(const std::string& anObjectID) = 0;
53   virtual _PTR(SObject) CreateObjectID(const std::string& anObjectID) = 0;
54   virtual _PTR(SObject) FindObjectIOR(const std::string& anObjectIOR) = 0;
55   virtual _PTR(SObject) FindObjectByPath(const std::string& thePath) = 0;
56   virtual std::string GetObjectPath(const _PTR(SObject)& theSO) = 0;
57   virtual void SetContext(const std::string& thePath) = 0;
58   virtual std::string GetContext() = 0;  
59   virtual std::vector<std::string> GetObjectNames(const std::string& theContext) = 0;
60   virtual std::vector<std::string> GetDirectoryNames(const std::string& theContext) = 0;
61   virtual std::vector<std::string> GetFileNames(const std::string& theContext) = 0;
62   virtual std::vector<std::string> GetComponentNames(const std::string& theContext) = 0;
63   virtual _PTR(ChildIterator) NewChildIterator(const _PTR(SObject)& theSO) = 0;
64   virtual _PTR(SComponentIterator) NewComponentIterator() = 0;
65   virtual _PTR(StudyBuilder) NewBuilder() = 0;
66   virtual std::string Name() = 0;
67   virtual void  Name(const std::string& name) = 0;
68   virtual bool IsSaved() = 0;
69   virtual void  IsSaved(bool save) = 0;
70   virtual bool IsModified() = 0;
71   virtual std::string URL() = 0;
72   virtual void  URL(const std::string& url) = 0;
73   virtual int StudyId() = 0;
74   virtual void  StudyId(int id) = 0;
75   virtual std::vector<_PTR(SObject)> FindDependances(const _PTR(SObject)& theSO) = 0;
76   virtual _PTR(AttributeStudyProperties) GetProperties() = 0;
77   virtual std::string GetLastModificationDate() = 0;
78   virtual std::vector<std::string> GetModificationsDate() = 0;
79   virtual _PTR(UseCaseBuilder) GetUseCaseBuilder() = 0;
80   virtual void Close() = 0;
81   virtual void EnableUseCaseAutoFilling(bool isEnabled) = 0;
82   virtual bool DumpStudy(const std::string& thePath, const std::string& theBaseName, bool isPublished) = 0; 
83 };
84
85
86 #endif