1 -- Created on: 1997-11-17
2 -- Created by: Jean-Louis Frenkel
3 -- Copyright (c) 1997-1999 Matra Datavision
4 -- Copyright (c) 1999-2014 OPEN CASCADE SAS
6 -- This file is part of Open CASCADE Technology software library.
8 -- This library is free software; you can redistribute it and / or modify it
9 -- under the terms of the GNU Lesser General Public version 2.1 as published
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.
14 -- Alternatively, this file may be used under the terms of Open CASCADE
15 -- commercial license or contractual agreement.
17 deferred class MetaDataDriver from CDF inherits Transient from Standard
21 Document from CDM, MetaData from CDM,
22 ExtendedString from TCollection,
23 ReferenceIterator from PCDM
26 NotImplemented from Standard
31 ---Category: virtual methods
33 HasVersionCapability(me: mutable)
34 ---Purpose: returns true if the MetaDataDriver can manage different
35 -- versions of a Data.
36 -- By default, returns Standard_False.
37 returns Boolean from Standard
40 CreateDependsOn(me: mutable; aFirstData: MetaData from CDM;
41 aSecondData: MetaData from CDM)
42 ---Purpose: Creates a "Depends On" relation between two Datas.
43 -- By default does nothing
46 CreateReference(me: mutable; aFrom, aTo: MetaData from CDM; aReferenceIdentifier: Integer from Standard; aToDocumentVersion: Integer from Standard)
49 HasVersion(me: mutable; aFolder, aName: ExtendedString from TCollection)
50 returns Boolean from Standard
51 ---Purpose: by default return Standard_True.
54 BuildFileName(me: mutable; aDocument: Document from CDM)
55 returns ExtendedString from TCollection
58 SetName(me: mutable; aDocument: Document from CDM; aName: ExtendedString from TCollection)
59 returns ExtendedString from TCollection
61 ---Purpose: this methods is usefull if the name of an object --
62 -- depends on the metadatadriver. For example a Driver
63 -- -- based on the operating system can choose to add
64 -- the extension of file to create to the object.
66 ---Category: Deferred methods
68 ---Overview: inquiring can be made either using a folder, a name and eventually
70 -- or a path which is the concatenation of a folder, a name and eventually
72 Find(me: mutable; aFolder, aName, aVersion: ExtendedString from TCollection)
73 returns Boolean from Standard
74 ---Purpose: should indicate whether meta-data exist in the DBMS corresponding
76 -- aVersion may be NULL;
79 HasReadPermission(me: mutable; aFolder, aName, aVersion: ExtendedString from TCollection)
80 returns Boolean from Standard
83 MetaData(me: mutable; aFolder, aName, aVersion: ExtendedString from TCollection)
84 returns MetaData from CDM
85 ---Purpose: should return the MetaData stored in the DBMS with the meta-data
86 -- corresponding to the Data. If the MetaDataDriver has version management capabilities
87 -- the version has to be set in the returned MetaData.
88 -- aVersion may be NULL
89 -- MetaData is called by GetMetaData
90 -- If the version is set to NULL, MetaData should return
91 -- the last version of the metadata
94 LastVersion(me: mutable; aMetaData: MetaData from CDM)
95 returns MetaData from CDM
97 ---Purpose: by default returns aMetaDATA
99 -- MetaData(me: mutable; aPath: ExtendedString from TCollection)
100 -- returns MetaData from CDM
101 ---Purpose: should return the MetaData stored in the DBMS with the meta-data
102 -- corresponding to the path. If the MetaDataDriver has version management capabilities
103 -- the version has to be set in the returned MetaData.
104 -- MetaData is called by GetMetaData
105 -- If the version is not included in the path , MetaData should return
106 -- the last version of the metadata
112 CreateMetaData(me: mutable; aDocument: Document from CDM;
113 aFileName: ExtendedString from TCollection)
114 ---Purpose: should create meta-data corresponding to aData and maintaining a meta-link
115 -- between these meta-data and aFileName
116 -- CreateMetaData is called by CreateData
117 returns MetaData from CDM
118 ---Purpose: If the metadata-driver
119 -- has version capabilities, version must be set in the returned Data.
122 FindFolder(me: mutable; aFolder: ExtendedString from TCollection)
123 returns Boolean from Standard
126 DefaultFolder(me: mutable) returns ExtendedString from TCollection
130 ---Category: methods about references.
132 ReferenceIterator(me: mutable)
133 returns ReferenceIterator from PCDM
137 Find(me: mutable; aFolder, aName: ExtendedString from TCollection)
138 returns Boolean from Standard;
139 ---Purpose: calls Find with an empty version
141 MetaData(me: mutable; aFolder, aName: ExtendedString from TCollection)
142 returns MetaData from CDM;
143 ---Purpose: calls MetaData with an empty version
146 end MetaDataDriver from CDF;