|
||||
File indexing completed on 2025-01-18 10:05:35
0001 // Created on: 2001-09-26 0002 // Created by: Julia DOROVSKIKH 0003 // Copyright (c) 2001-2014 OPEN CASCADE SAS 0004 // 0005 // This file is part of Open CASCADE Technology software library. 0006 // 0007 // This library is free software; you can redistribute it and/or modify it under 0008 // the terms of the GNU Lesser General Public License version 2.1 as published 0009 // by the Free Software Foundation, with special exception defined in the file 0010 // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT 0011 // distribution for complete text of the license and disclaimer of any warranty. 0012 // 0013 // Alternatively, this file may be used under the terms of Open CASCADE 0014 // commercial license or contractual agreement. 0015 0016 #ifndef _XmlMDF_ADriverTable_HeaderFile 0017 #define _XmlMDF_ADriverTable_HeaderFile 0018 0019 #include <Standard.hxx> 0020 0021 #include <XmlMDF_TypeADriverMap.hxx> 0022 #include <Standard_Transient.hxx> 0023 #include <Standard_Boolean.hxx> 0024 #include <Standard_Type.hxx> 0025 #include <XmlMDF_MapOfDriver.hxx> 0026 class XmlMDF_ADriver; 0027 0028 0029 class XmlMDF_ADriverTable; 0030 DEFINE_STANDARD_HANDLE(XmlMDF_ADriverTable, Standard_Transient) 0031 0032 //! A driver table is an object building links between 0033 //! object types and object drivers. In the 0034 //! translation process, a driver table is asked to 0035 //! give a translation driver for each current object 0036 //! to be translated. 0037 class XmlMDF_ADriverTable : public Standard_Transient 0038 { 0039 0040 public: 0041 0042 0043 //! Creates a mutable ADriverTable from XmlMDF. 0044 Standard_EXPORT XmlMDF_ADriverTable(); 0045 0046 //! Sets a translation driver: <aDriver>. 0047 Standard_EXPORT void AddDriver (const Handle(XmlMDF_ADriver)& anHDriver); 0048 0049 //! Adds a translation driver for the derived attribute. The base driver must be already added. 0050 //! @param theInstance is newly created attribute, detached from any label 0051 Standard_EXPORT void AddDerivedDriver (const Handle(TDF_Attribute)& theInstance); 0052 0053 //! Adds a translation driver for the derived attribute. The base driver must be already added. 0054 //! @param theDerivedType is registered attribute type using IMPLEMENT_DERIVED_ATTRIBUTE macro 0055 Standard_EXPORT const Handle(Standard_Type)& AddDerivedDriver (Standard_CString theDerivedType); 0056 0057 //! Fills the map by all registered drivers. 0058 Standard_EXPORT void CreateDrvMap (XmlMDF_MapOfDriver& theDriverMap); 0059 0060 //! Gets a driver <aDriver> according to <aType> 0061 //! 0062 //! Returns True if a driver is found; false otherwise. 0063 Standard_EXPORT Standard_Boolean GetDriver (const Handle(Standard_Type)& theType, 0064 Handle(XmlMDF_ADriver)& theDriver); 0065 0066 0067 DEFINE_STANDARD_RTTIEXT(XmlMDF_ADriverTable,Standard_Transient) 0068 0069 protected: 0070 0071 0072 0073 0074 private: 0075 0076 0077 XmlMDF_TypeADriverMap myMap; 0078 0079 0080 }; 0081 0082 0083 0084 0085 0086 0087 0088 #endif // _XmlMDF_ADriverTable_HeaderFile
[ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
This page was automatically generated by the 2.3.7 LXR engine. The LXR team |