Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2026-05-13 08:44:37

0001 // Created on: 1997-05-09
0002 // Created by: Christian CAILLET
0003 // Copyright (c) 1997-1999 Matra Datavision
0004 // Copyright (c) 1999-2014 OPEN CASCADE SAS
0005 //
0006 // This file is part of Open CASCADE Technology software library.
0007 //
0008 // This library is free software; you can redistribute it and/or modify it under
0009 // the terms of the GNU Lesser General Public License version 2.1 as published
0010 // by the Free Software Foundation, with special exception defined in the file
0011 // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
0012 // distribution for complete text of the license and disclaimer of any warranty.
0013 //
0014 // Alternatively, this file may be used under the terms of Open CASCADE
0015 // commercial license or contractual agreement.
0016 
0017 #ifndef _StepData_Described_HeaderFile
0018 #define _StepData_Described_HeaderFile
0019 
0020 #include <Standard.hxx>
0021 #include <Standard_Type.hxx>
0022 
0023 #include <Standard_Transient.hxx>
0024 class StepData_EDescr;
0025 class StepData_Simple;
0026 class StepData_Field;
0027 class Interface_Check;
0028 class Interface_EntityIterator;
0029 
0030 class StepData_Described;
0031 DEFINE_STANDARD_HANDLE(StepData_Described, Standard_Transient)
0032 
0033 //! General frame to describe entities with Description (Simple or
0034 //! Complex)
0035 class StepData_Described : public Standard_Transient
0036 {
0037 
0038 public:
0039   //! Returns the Description used to define this entity
0040   Standard_EXPORT Handle(StepData_EDescr) Description() const;
0041 
0042   //! Tells if a described entity is complex
0043   Standard_EXPORT virtual Standard_Boolean IsComplex() const = 0;
0044 
0045   //! Tells if a step type is matched by <me>
0046   //! For a Simple Entity : own type or super type
0047   //! For a Complex Entity : one of the members
0048   Standard_EXPORT virtual Standard_Boolean Matches(const Standard_CString steptype) const = 0;
0049 
0050   //! Returns a Simple Entity which matches with a Type in <me> :
0051   //! For a Simple Entity : me if it matches, else a null handle
0052   //! For a Complex Entity : the member which matches, else null
0053   Standard_EXPORT virtual Handle(StepData_Simple) As(const Standard_CString steptype) const = 0;
0054 
0055   //! Tells if a Field brings a given name
0056   Standard_EXPORT virtual Standard_Boolean HasField(const Standard_CString name) const = 0;
0057 
0058   //! Returns a Field from its name; read-only
0059   Standard_EXPORT virtual const StepData_Field& Field(const Standard_CString name) const = 0;
0060 
0061   //! Returns a Field from its name; read or write
0062   Standard_EXPORT virtual StepData_Field& CField(const Standard_CString name) = 0;
0063 
0064   //! Fills a Check by using its Description
0065   Standard_EXPORT virtual void Check(Handle(Interface_Check)& ach) const = 0;
0066 
0067   //! Fills an EntityIterator with entities shared by <me>
0068   Standard_EXPORT virtual void Shared(Interface_EntityIterator& list) const = 0;
0069 
0070   DEFINE_STANDARD_RTTIEXT(StepData_Described, Standard_Transient)
0071 
0072 protected:
0073   //! Initializes a Described Entity from a Description
0074   //! (i.e. puts it in a field ...)
0075   Standard_EXPORT StepData_Described(const Handle(StepData_EDescr)& descr);
0076 
0077 private:
0078   Handle(StepData_EDescr) thedescr;
0079 };
0080 
0081 #endif // _StepData_Described_HeaderFile