This file is indexed.

/usr/include/oce/CDM_Document.hxx is in liboce-ocaf-lite-dev 0.17.2-2.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
// This file is generated by WOK (CPPExt).
// Please do not edit this file; modify original file instead.
// The copyright and license terms as defined for the original file apply to 
// this header file considered to be the "object code" form of the original source.

#ifndef _CDM_Document_HeaderFile
#define _CDM_Document_HeaderFile

#include <Standard.hxx>
#include <Standard_DefineHandle.hxx>
#include <Handle_CDM_Document.hxx>

#include <TColStd_SequenceOfExtendedString.hxx>
#include <TCollection_ExtendedString.hxx>
#include <Standard_Boolean.hxx>
#include <CDM_ListOfReferences.hxx>
#include <Standard_Integer.hxx>
#include <Handle_CDM_MetaData.hxx>
#include <Standard_GUID.hxx>
#include <Handle_CDM_Application.hxx>
#include <Standard_Transient.hxx>
#include <Standard_Address.hxx>
#include <Standard_ExtString.hxx>
#include <Handle_Resource_Manager.hxx>
#include <Standard_OStream.hxx>
#include <CDM_CanCloseStatus.hxx>
#include <Handle_CDM_Reference.hxx>
class CDM_MetaData;
class CDM_Application;
class Standard_NoSuchObject;
class Standard_Failure;
class Standard_DomainError;
class CDM_Reference;
class CDM_ReferenceIterator;
class TCollection_ExtendedString;
class TColStd_SequenceOfExtendedString;
class Resource_Manager;
class Standard_GUID;


//! An applicative document is an instance of a class inheriting CDM_Document.
//! These documents have the following properties:
//! - they can have references to other documents.
//! - the modifications of a document are propagated to the referencing
//! documents.
//! - a  document can be   stored in different formats, with  or
//! without a persistent model.
//! - the drivers  for  storing  and retrieving documents  are
//! plugged in when necessary.
//! - a  document has a modification counter. This counter is
//! incremented when the document is  modified.  When a document
//! is stored,  the current  counter  value is memorized as the
//! last storage  version of the   document.  A document  is
//! considered to be  modified   when the  counter value  is
//! different from the storage version.  Once  the document is
//! saved  the storage  version  and the  counter  value are
//! identical.  The document  is  now  not considered  to  be
//! modified.
//! - a reference is a link between two documents. A reference has two
//! components: the "From Document" and the "To Document". When
//! a reference is created, an identifier of the reference is generated.
//! This identifier is unique in the scope of the From Document and
//! is conserved during storage and retrieval. This means that the
//! referenced document will be always accessible through this
//! identifier.
//! - a reference memorizes the counter value of the To Document when
//! the reference is created. The From Document is considered to
//! be up to date relative to the To Document when the
//! reference counter value is equal to the To Document counter value.
//! -  retrieval of a document  having references does not imply
//! the retrieving of the referenced documents.
class CDM_Document : public Standard_Transient
{

public:

  
  //! The Update  method  will be called  once  for each
  //! reference, but it  should not perform any computation,
  //! to avoid multiple computation of a same document.
  Standard_EXPORT virtual   void Update (const Handle(CDM_Document)& aToDocument, const Standard_Integer aReferenceIdentifier, const Standard_Address aModifContext) ;
  
  //! This method Update   will be called
  //! to signal the end   of the modified references list.
  //! The    document     should    be  recomputed     and
  //! UpdateFromDocuments  should be called.  Update should
  //! returns True in case  of success, false otherwise.  In
  //! case of Failure, additional information can be given in
  //! ErrorString.
  Standard_EXPORT virtual   Standard_Boolean Update (TCollection_ExtendedString& ErrorString) ;
  
  //! The Storage Format is the key which is used to determine in the
  //! application resources the storage driver plugin, the file
  //! extension and other data used to store the document.
  Standard_EXPORT virtual   TCollection_ExtendedString StorageFormat()  const = 0;
  
  //! by default empties the extensions.
  Standard_EXPORT virtual   void Extensions (TColStd_SequenceOfExtendedString& Extensions)  const;
  
  //! This method can be redefined to extract another document in
  //! a different format. For example, to extract a MDTV-Shape
  //! from an applicative document.
  Standard_EXPORT virtual   Standard_Boolean GetAlternativeDocument (const TCollection_ExtendedString& aFormat, Handle(CDM_Document)& anAlternativeDocument) ;
  
  //! Creates a reference from this document to {anOtherDocument}.
  //! Returns a reference identifier. This reference identifier
  //! is unique in the document and will not be used for the
  //! next references, even after the storing of the document.
  //! If there is already a reference between the two documents,
  //! the reference is not created, but its reference identifier
  //! is returned.
  Standard_EXPORT   Standard_Integer CreateReference (const Handle(CDM_Document)& anOtherDocument) ;
  
  //! Removes the reference between the From Document and the
  //! To Document identified by a reference identifier.
  Standard_EXPORT   void RemoveReference (const Standard_Integer aReferenceIdentifier) ;
  
  //! Removes all references having this document for From Document.
  Standard_EXPORT   void RemoveAllReferences() ;
  
  //! Returns the To Document  of the reference identified by
  //! aReferenceIdentifier. If the ToDocument is stored and
  //! has not yet been retrieved, this method will retrieve it.
  Standard_EXPORT   Handle(CDM_Document) Document (const Standard_Integer aReferenceIdentifier)  const;
  
  //! returns True if   the  To Document of the  reference
  //! identified by aReferenceIdentifier is in session,  False
  //! if it corresponds to a not yet retrieved document.
  Standard_EXPORT   Standard_Boolean IsInSession (const Standard_Integer aReferenceIdentifier)  const;
  
  //! returns True if   the  To Document of the  reference
  //! identified by aReferenceIdentifier has already been stored,
  //! False  otherwise.
  Standard_EXPORT   Standard_Boolean IsStored (const Standard_Integer aReferenceIdentifier)  const;
  
  //! returns the name of the metadata of the To Document of
  //! the reference identified by aReferenceIdentifier.
  Standard_EXPORT   TCollection_ExtendedString Name (const Standard_Integer aReferenceIdentifier)  const;
  
  //! call  virtual  method   Update  on  all   referencing
  //! documents.   This method keeps  the list  of the --
  //! documents  to process.It may  be the starting of an
  //! update -- cycle. If  not,  the reentrant calls made by
  //! Update  method (without argument)  will append the
  //! referencing documents to the list and call the Update method
  //! (with arguments). Only the first call to UpdateFromDocuments
  //! generate call to Update().
  Standard_EXPORT   void UpdateFromDocuments (const Standard_Address aModifContext)  const;
  
  //! returns the number of references having this document as
  //! From Document.
  Standard_EXPORT   Standard_Integer ToReferencesNumber()  const;
  
  //! returns the number of references having this document as
  //! To Document.
  Standard_EXPORT   Standard_Integer FromReferencesNumber()  const;
  
  //! returns True is this document references aDocument;
  Standard_EXPORT   Standard_Boolean ShallowReferences (const Handle(CDM_Document)& aDocument)  const;
  
  //! returns True is this document references aDocument;
  Standard_EXPORT   Standard_Boolean DeepReferences (const Handle(CDM_Document)& aDocument)  const;
  
  //! Copies a  reference  to  this document.   This  method
  //! avoid retrieval of referenced document.  The arguments
  //! are  the  original  document  and a  valid  reference
  //! identifier Returns the  local identifier.
  Standard_EXPORT   Standard_Integer CopyReference (const Handle(CDM_Document)& aFromDocument, const Standard_Integer aReferenceIdentifier) ;
  
  //! indicates  that  this document cannot be   modified.
  Standard_EXPORT   Standard_Boolean IsReadOnly()  const;
  
  //! indicates that the referenced document cannot be modified,
  Standard_EXPORT   Standard_Boolean IsReadOnly (const Standard_Integer aReferenceIdentifier)  const;
  
  Standard_EXPORT   void SetIsReadOnly() ;
  
  Standard_EXPORT   void UnsetIsReadOnly() ;
  
  //! Indicates that this document has been modified.
  //! This method increments the modification counter.
  Standard_EXPORT   void Modify() ;
  
  //! returns the current modification counter.
  Standard_EXPORT   Standard_Integer Modifications()  const;
  
  Standard_EXPORT   void UnModify() ;
  
  //! returns true if the modification counter found in the given
  //! reference is equal to the actual modification counter of
  //! the To Document. This method is able to deal with a reference
  //! to a not retrieved document.
  Standard_EXPORT   Standard_Boolean IsUpToDate (const Standard_Integer aReferenceIdentifier)  const;
  
  //! Resets the modification counter in the given reference
  //! to the actual modification counter of its To Document.
  //! This method should be called after the application has updated
  //! this document.
  Standard_EXPORT   void SetIsUpToDate (const Standard_Integer aReferenceIdentifier) ;
  
  //! associates a comment with this document.
  Standard_EXPORT   void SetComment (const TCollection_ExtendedString& aComment) ;
  
  //! appends a comment into comments of this document.
  Standard_EXPORT   void AddComment (const TCollection_ExtendedString& aComment) ;
  
  //! associates a comments with this document.
  Standard_EXPORT   void SetComments (const TColStd_SequenceOfExtendedString& aComments) ;
  
  //! returns the associated comments through <aComments>.
  //! Returns empty sequence if no comments are associated.
  Standard_EXPORT   void Comments (TColStd_SequenceOfExtendedString& aComments)  const;
  
  //! returns the first of associated comments. By defaut
  //! the comment is an empty string.
  Standard_EXPORT   Standard_ExtString Comment()  const;
  
  //! Returns an alphanumeric string identifying this document
  //! in a unique manner in the current process. The presentation
  //! may change when the document is stored.
  //! Tries to get the 'FileFormat`.Presentation resource
  //! This item is used to give a default presentation
  //! to the document.
  Standard_EXPORT   Standard_ExtString Presentation() ;
  
  //! returns the document having the given alphanumeric presentation.
  Standard_EXPORT static   Handle(CDM_Document) FindFromPresentation (const TCollection_ExtendedString& aPresentation) ;
  
  //! indicates whether a document having the given presentation
  //! does exist.
  Standard_EXPORT static   Standard_Boolean FindPresentation (const TCollection_ExtendedString& aPresentation) ;
  
  Standard_EXPORT   Standard_Boolean IsStored()  const;
  
  //! returns  the value of  the modification counter at the
  //! time of storage. By default returns 0.
  Standard_EXPORT   Standard_Integer StorageVersion()  const;
  
  //! associates database  information to  a document which
  //! has been stored.  The name of the  document is now the
  //! name which has beenused to store the data.
  Standard_EXPORT   void SetMetaData (const Handle(CDM_MetaData)& aMetaData) ;
  
  Standard_EXPORT   void UnsetIsStored() ;
  
  Standard_EXPORT   Handle(CDM_MetaData) MetaData()  const;
  
  Standard_EXPORT   TCollection_ExtendedString Folder()  const;
  
  //! defines the folder in which the object should be stored.
  Standard_EXPORT   void SetRequestedFolder (const TCollection_ExtendedString& aFolder) ;
  
  Standard_EXPORT   TCollection_ExtendedString RequestedFolder()  const;
  
  Standard_EXPORT   Standard_Boolean HasRequestedFolder()  const;
  
  //! defines the name under which the object should be stored.
  Standard_EXPORT   void SetRequestedName (const TCollection_ExtendedString& aName) ;
  
  //! determines  under  which the document  is  going to be
  //! store.  By default the name of the document wil be --
  //! used.  If the document has  no name  its presentation
  //! will be used.
  Standard_EXPORT   TCollection_ExtendedString RequestedName() ;
  
  Standard_EXPORT   void SetRequestedPreviousVersion (const TCollection_ExtendedString& aPreviousVersion) ;
  
  Standard_EXPORT   void UnsetRequestedPreviousVersion() ;
  
  Standard_EXPORT   Standard_Boolean HasRequestedPreviousVersion()  const;
  
  Standard_EXPORT   TCollection_ExtendedString RequestedPreviousVersion()  const;
  
  //! defines the Comment with  which the object should be stored.
  Standard_EXPORT   void SetRequestedComment (const TCollection_ExtendedString& aComment) ;
  
  Standard_EXPORT   TCollection_ExtendedString RequestedComment()  const;
  
  //! read (or rereads) the following resource.
  Standard_EXPORT   void LoadResources() ;
  
  Standard_EXPORT   Standard_Boolean FindFileExtension() ;
  
  //! gets the Desktop.Domain.Application.`FileFormat`.FileExtension resource.
  Standard_EXPORT   TCollection_ExtendedString FileExtension() ;
  
  Standard_EXPORT   Standard_Boolean FindDataType() ;
  
  //! this datatype will be used if the DBMS deals with this concept
  //! gets the `FileFormat`.DataType resource.
  //! concept.
  Standard_EXPORT   TCollection_ExtendedString DataType() ;
  
  Standard_EXPORT   Standard_Boolean FindVersionDataType() ;
  
  //! this datatype will be used if the DBMS deals with this concept
  //! gets the `FileFormat`.VersionDataType resource.
  Standard_EXPORT   TCollection_ExtendedString VersionDataType() ;
  
  Standard_EXPORT   Standard_Boolean FindDescription() ;
  
  //! gets the `FileFormat`.Description resource.
  Standard_EXPORT   TCollection_ExtendedString Description() ;
  
  Standard_EXPORT   Standard_Boolean FindDomain() ;
  
  //! gets the `FileFormat`.Domain resource.
  Standard_EXPORT   TCollection_ExtendedString Domain() ;
  
  Standard_EXPORT   Standard_Boolean FindStoragePlugin() ;
  
  Standard_EXPORT   Standard_GUID StoragePlugin() ;
  
  //! returns  true  if the   version is greater  than   the
  //! storage version
  Standard_EXPORT   Standard_Boolean IsModified()  const;
  
  Standard_EXPORT   Standard_OStream& Print (Standard_OStream& anOStream)  const;
Standard_OStream& operator << (Standard_OStream& anOStream);
  
  Standard_EXPORT   Standard_Boolean IsOpened()  const;
  
  Standard_EXPORT   void Open (const Handle(CDM_Application)& anApplication) ;
  
  Standard_EXPORT   CDM_CanCloseStatus CanClose()  const;
  
  Standard_EXPORT   void Close() ;
  
  Standard_EXPORT  const  Handle(CDM_Application)& Application()  const;
  
  //! A  referenced  document  may  indicate   through  this
  //! virtual  method that it does  not allow the closing of
  //! aDocument  which  it references through  the reference
  //! aReferenceIdentifier. By default returns Standard_True;;
  Standard_EXPORT virtual   Standard_Boolean CanCloseReference (const Handle(CDM_Document)& aDocument, const Standard_Integer aReferenceIdentifier)  const;
  
  //! A referenced document may update its internal
  //! data structure when {aDocument} which it references
  //! through the reference {aReferenceIdentifier} is being closed.
  //! By default this method does nothing.
  Standard_EXPORT virtual   void CloseReference (const Handle(CDM_Document)& aDocument, const Standard_Integer aReferenceIdentifier) ;
  
  //! returns true if  the   document corresponding to  the
  //! given   reference has    been retrieved  and  opened.
  //! Otherwise returns false. This method does not retrieve
  //! the referenced document
  Standard_EXPORT   Standard_Boolean IsOpened (const Standard_Integer aReferenceIdentifier)  const;
  
  Standard_EXPORT   void CreateReference (const Handle(CDM_MetaData)& aMetaData, const Standard_Integer aReferenceIdentifier, const Handle(CDM_Application)& anApplication, const Standard_Integer aToDocumentVersion, const Standard_Boolean UseStorageConfiguration) ;
  
  Standard_EXPORT   Standard_Integer CreateReference (const Handle(CDM_MetaData)& aMetaData, const Handle(CDM_Application)& anApplication, const Standard_Integer aDocumentVersion, const Standard_Boolean UseStorageConfiguration) ;
  
  Standard_EXPORT   Standard_Integer ReferenceCounter()  const;
  
  //! the following method should be used instead:
  //!
  //! Update(me:mutable; ErrorString: out ExtendedString from TCollection)
  //! returns Boolean from Standard
  Standard_EXPORT virtual   void Update() ;

friend class CDM_Reference;
friend class CDM_ReferenceIterator;
friend class CDM_Application;


  DEFINE_STANDARD_RTTI(CDM_Document)

protected:

  
  Standard_EXPORT CDM_Document();
  
  Standard_EXPORT virtual   void Destroy() ;
~CDM_Document()
{
  Destroy();
}

  Standard_Boolean myResourcesAreLoaded;


private: 

  
  //! the manager returned by  this method will be
  //! used to search for the following resource items.
  Standard_EXPORT   Handle(Resource_Manager) StorageResource() ;
  
  Standard_EXPORT   Handle(CDM_Reference) Reference (const Standard_Integer aReferenceIdentifier)  const;
  
  Standard_EXPORT   void ComputePresentation() ;
  
  Standard_EXPORT   void UnvalidPresentation() ;
  
  Standard_EXPORT   void AddToReference (const Handle(CDM_Reference)& aReference) ;
  
  Standard_EXPORT   void AddFromReference (const Handle(CDM_Reference)& aReference) ;
  
  Standard_EXPORT   void RemoveFromReference (const Standard_Integer aReferenceIdentifier) ;
  
  Standard_EXPORT   void SetModifications (const Standard_Integer Modifications) ;
  
  Standard_EXPORT   void SetReferenceCounter (const Standard_Integer aReferenceCounter) ;

  TColStd_SequenceOfExtendedString myComments;
  TCollection_ExtendedString myPresentation;
  Standard_Boolean myValidPresentation;
  CDM_ListOfReferences myFromReferences;
  CDM_ListOfReferences myToReferences;
  Standard_Integer myVersion;
  Standard_Integer myActualReferenceIdentifier;
  Standard_Integer myStorageVersion;
  Handle(CDM_MetaData) myMetaData;
  TCollection_ExtendedString myRequestedComment;
  TCollection_ExtendedString myRequestedFolder;
  Standard_Boolean myRequestedFolderIsDefined;
  TCollection_ExtendedString myRequestedName;
  Standard_Boolean myRequestedNameIsDefined;
  Standard_Boolean myRequestedPreviousVersionIsDefined;
  TCollection_ExtendedString myRequestedPreviousVersion;
  TCollection_ExtendedString myFileExtension;
  TCollection_ExtendedString myDataType;
  TCollection_ExtendedString myVersionDataType;
  TCollection_ExtendedString myDescription;
  TCollection_ExtendedString myDomain;
  TCollection_ExtendedString myDefaultPresentation;
  Standard_Boolean myFileExtensionWasFound;
  Standard_Boolean myDataTypeWasFound;
  Standard_Boolean myVersionDataTypeWasFound;
  Standard_Boolean myDescriptionWasFound;
  Standard_Boolean myDomainWasFound;
  Standard_Boolean myStoragePluginWasFound;
  Standard_Boolean myDefaultPresentationWasFound;
  Standard_GUID myStoragePlugin;
  Handle(CDM_Application) myApplication;


};







#endif // _CDM_Document_HeaderFile