b311480e |
1 | // Created on: 1997-11-17 |
2 | // Created by: Jean-Louis Frenkel |
3 | // Copyright (c) 1997-1999 Matra Datavision |
973c2be1 |
4 | // Copyright (c) 1999-2014 OPEN CASCADE SAS |
b311480e |
5 | // |
973c2be1 |
6 | // This file is part of Open CASCADE Technology software library. |
b311480e |
7 | // |
d5f74e42 |
8 | // This library is free software; you can redistribute it and/or modify it under |
9 | // the terms of the GNU Lesser General Public License version 2.1 as published |
973c2be1 |
10 | // by the Free Software Foundation, with special exception defined in the file |
11 | // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT |
12 | // distribution for complete text of the license and disclaimer of any warranty. |
b311480e |
13 | // |
973c2be1 |
14 | // Alternatively, this file may be used under the terms of Open CASCADE |
15 | // commercial license or contractual agreement. |
7fd59977 |
16 | |
42cf5bc1 |
17 | |
7fd59977 |
18 | #include <CDF_Application.hxx> |
42cf5bc1 |
19 | #include <CDF_MetaDataDriver.hxx> |
7fd59977 |
20 | #include <CDF_Session.hxx> |
42cf5bc1 |
21 | #include <CDM_Document.hxx> |
22 | #include <CDM_MetaData.hxx> |
23 | #include <PCDM_ReferenceIterator.hxx> |
24 | #include <Standard_NotImplemented.hxx> |
25 | #include <Standard_Type.hxx> |
26 | #include <TCollection_ExtendedString.hxx> |
7fd59977 |
27 | |
92efcf78 |
28 | IMPLEMENT_STANDARD_RTTIEXT(CDF_MetaDataDriver,Standard_Transient) |
29 | |
7fd59977 |
30 | //======================================================================= |
31 | //function : CDF_MetaDataDriver |
32 | //purpose : |
33 | //======================================================================= |
7fd59977 |
34 | CDF_MetaDataDriver::CDF_MetaDataDriver() {} |
35 | |
36 | //======================================================================= |
37 | //function : HasVersion |
38 | //purpose : |
39 | //======================================================================= |
40 | |
41 | Standard_Boolean CDF_MetaDataDriver::HasVersion(const TCollection_ExtendedString& ,const TCollection_ExtendedString& ) { |
42 | return Standard_True; |
43 | } |
44 | |
45 | //======================================================================= |
46 | //function : HasVersionCapability |
47 | //purpose : |
48 | //======================================================================= |
49 | |
50 | //======================================================================= |
51 | //function : HasVersionCapability |
52 | //purpose : |
53 | //======================================================================= |
54 | |
55 | Standard_Boolean CDF_MetaDataDriver::HasVersionCapability() { |
56 | return Standard_False; |
57 | } |
58 | //======================================================================= |
59 | //function : CreateDependsOn |
60 | //purpose : |
61 | //======================================================================= |
62 | |
63 | void CDF_MetaDataDriver::CreateDependsOn(const Handle(CDM_MetaData)& , |
64 | const Handle(CDM_MetaData)& ) {} |
65 | |
66 | //======================================================================= |
67 | //function : CreateReference |
68 | //purpose : |
69 | //======================================================================= |
70 | |
71 | void CDF_MetaDataDriver::CreateReference(const Handle(CDM_MetaData)& ,const Handle(CDM_MetaData)& , const Standard_Integer , const Standard_Integer ) {} |
72 | |
73 | //======================================================================= |
74 | //function : ReferenceIterator |
75 | //purpose : |
76 | //======================================================================= |
77 | |
78 | Handle(PCDM_ReferenceIterator) CDF_MetaDataDriver::ReferenceIterator() { |
79 | return new PCDM_ReferenceIterator(CDF_Session::CurrentSession()->CurrentApplication()->MessageDriver()); |
80 | } |
81 | |
82 | //======================================================================= |
83 | //function : Find |
84 | //purpose : |
85 | //======================================================================= |
86 | |
87 | Standard_Boolean CDF_MetaDataDriver::Find(const TCollection_ExtendedString& aFolder, const TCollection_ExtendedString& aName) { |
88 | TCollection_ExtendedString aVersion; |
89 | return Find(aFolder,aName,aVersion); |
90 | } |
91 | //======================================================================= |
92 | //function : MetaData |
93 | //purpose : |
94 | //======================================================================= |
95 | |
96 | Handle(CDM_MetaData) CDF_MetaDataDriver::MetaData(const TCollection_ExtendedString& aFolder, const TCollection_ExtendedString& aName) { |
97 | TCollection_ExtendedString aVersion; |
98 | return MetaData(aFolder,aName,aVersion); |
99 | } |
100 | //======================================================================= |
101 | //function : LastVersion |
102 | //purpose : |
103 | //======================================================================= |
104 | |
105 | Handle(CDM_MetaData) CDF_MetaDataDriver::LastVersion(const Handle(CDM_MetaData)& aMetaData) { |
106 | return aMetaData; |
107 | } |
108 | //======================================================================= |
109 | //function : SetName |
110 | //purpose : |
111 | //======================================================================= |
112 | |
113 | TCollection_ExtendedString CDF_MetaDataDriver::SetName(const Handle(CDM_Document)& , const TCollection_ExtendedString& aName) { |
114 | return aName; |
115 | } |