Version: 8.3.0
SALOMEDS_DriverDefaultImpl.hxx
Go to the documentation of this file.
1 // Copyright (C) 2007-2016 CEA/DEN, EDF R&D, OPEN CASCADE
2 //
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.
7 //
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.
12 //
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
16 //
17 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
18 //
19 // Author: Guillaume Boulant (EDF/R&D)
20 
21 #ifndef __SALOMEDS_DRIVER_DEFAULT_IMPL_H__
22 #define __SALOMEDS_DRIVER_DEFAULT_IMPL_H__
23 
24 #include "KernelHelpers.hxx"
25 
26 #include "SALOME_Component_i.hxx"
27 #include "SALOME_NamingService.hxx"
28 
29 #include CORBA_CLIENT_HEADER(SALOMEDS)
30 
31 
32 //---------------------------------------------------------
33 
35  public virtual POA_SALOMEDS::Driver
36 //---------------------------------------------------------
37  {
38 
39 
41  public:
42  SALOMEDS_DriverDefaultImpl(CORBA::ORB_ptr orb,
43  PortableServer::POA_ptr poa,
44  PortableServer::ObjectId * contId,
45  const char *instanceName,
46  const char *interfaceName);
47 
48 
49  virtual ~SALOMEDS_DriverDefaultImpl();
50 
51  //---------------------------------------------
52  // inherited methods from SALOMEDS::Driver
53  //---------------------------------------------
54 
55  //virtual SALOMEDS::TMPFile* Save(SALOMEDS::SComponent_ptr theComponent,
56  SALOMEDS::TMPFile* Save(SALOMEDS::SComponent_ptr theComponent,
57  const char* theURL,
58  bool isMultiFile);
59 
60  virtual SALOMEDS::TMPFile* SaveASCII(SALOMEDS::SComponent_ptr theComponent,
61  const char* theURL,
62  bool isMultiFile);
63 
64  virtual bool Load(SALOMEDS::SComponent_ptr,
65  const SALOMEDS::TMPFile &,
66  const char* theURL,
67  bool isMultiFile);
68 
69  virtual bool LoadASCII(SALOMEDS::SComponent_ptr,
70  const SALOMEDS::TMPFile &,
71  const char* theURL,
72  bool isMultiFile);
73 
74  virtual void Close(SALOMEDS::SComponent_ptr IORSComponent);
75 
76  virtual char* ComponentDataType();
77 
78  virtual char* IORToLocalPersistentID(SALOMEDS::SObject_ptr theSObject,
79  const char* IORString,
80  CORBA::Boolean isMultiFile,
81  CORBA::Boolean isASCII);
82 
83  virtual char* LocalPersistentIDToIOR(SALOMEDS::SObject_ptr theSObject,
84  const char* aLocalPersistentID,
85  CORBA::Boolean isMultiFile,
86  CORBA::Boolean isASCII);
87 
88  virtual bool CanPublishInStudy(CORBA::Object_ptr theIOR);
89 
90  virtual SALOMEDS::SObject_ptr PublishInStudy
91  (SALOMEDS::Study_ptr theStudy,
92  SALOMEDS::SObject_ptr theSObject,
93  CORBA::Object_ptr theObject,
94  const char* theName)
96 
97  virtual CORBA::Boolean CanCopy(SALOMEDS::SObject_ptr theObject);
98 
99  virtual SALOMEDS::TMPFile* CopyFrom(SALOMEDS::SObject_ptr theObject,
100  CORBA::Long& theObjectID);
101 
102  virtual CORBA::Boolean CanPaste(const char* theComponentName,
103  CORBA::Long theObjectID);
104 
105  virtual SALOMEDS::SObject_ptr PasteInto(const SALOMEDS::TMPFile& theStream,
106  CORBA::Long theObjectID,
107  SALOMEDS::SObject_ptr theObject);
108  };
109 #endif