Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2026-09-29 09:20:42

0001 // Created on: 1997-03-03
0002 // Created by: Yves FRICAUD
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 _TNaming_Identifier_HeaderFile
0018 #define _TNaming_Identifier_HeaderFile
0019 
0020 #include <Standard.hxx>
0021 #include <Standard_DefineAlloc.hxx>
0022 #include <Standard_Handle.hxx>
0023 
0024 #include <TDF_Label.hxx>
0025 #include <TNaming_NameType.hxx>
0026 #include <TNaming_NamedShape.hxx>
0027 #include <NCollection_List.hxx>
0028 #include <TopoDS_Shape.hxx>
0029 class TNaming_NamedShape;
0030 class TNaming_Localizer;
0031 
0032 class TNaming_Identifier
0033 {
0034 public:
0035   DEFINE_STANDARD_ALLOC
0036 
0037   Standard_EXPORT TNaming_Identifier(const TDF_Label&    Lab,
0038                                      const TopoDS_Shape& S,
0039                                      const TopoDS_Shape& Context,
0040                                      const bool          Geom);
0041 
0042   Standard_EXPORT TNaming_Identifier(const TDF_Label&                       Lab,
0043                                      const TopoDS_Shape&                    S,
0044                                      const occ::handle<TNaming_NamedShape>& ContextNS,
0045                                      const bool                             Geom);
0046 
0047   Standard_EXPORT bool IsDone() const;
0048 
0049   Standard_EXPORT TNaming_NameType Type() const;
0050 
0051   Standard_EXPORT bool IsFeature();
0052 
0053   Standard_EXPORT occ::handle<TNaming_NamedShape> Feature() const;
0054 
0055   Standard_EXPORT void InitArgs();
0056 
0057   Standard_EXPORT bool MoreArgs() const;
0058 
0059   Standard_EXPORT void NextArg();
0060 
0061   Standard_EXPORT bool ArgIsFeature() const;
0062 
0063   Standard_EXPORT occ::handle<TNaming_NamedShape> FeatureArg();
0064 
0065   Standard_EXPORT TopoDS_Shape ShapeArg();
0066 
0067   Standard_EXPORT TopoDS_Shape ShapeContext() const;
0068 
0069   Standard_EXPORT occ::handle<TNaming_NamedShape> NamedShapeOfGeneration() const;
0070 
0071   Standard_EXPORT void AncestorIdentification(TNaming_Localizer&  Localizer,
0072                                               const TopoDS_Shape& Context);
0073 
0074   Standard_EXPORT void PrimitiveIdentification(TNaming_Localizer&                     Localizer,
0075                                                const occ::handle<TNaming_NamedShape>& NS);
0076 
0077   Standard_EXPORT void GeneratedIdentification(TNaming_Localizer&                     Localizer,
0078                                                const occ::handle<TNaming_NamedShape>& NS);
0079 
0080   Standard_EXPORT void Identification(TNaming_Localizer&                     Localizer,
0081                                       const occ::handle<TNaming_NamedShape>& NS);
0082 
0083 private:
0084   Standard_EXPORT void Init(const TopoDS_Shape& Context);
0085 
0086   TDF_Label                                         myTDFAcces;
0087   TopoDS_Shape                                      myShape;
0088   bool                                              myDone;
0089   bool                                              myIsFeature;
0090   TNaming_NameType                                  myType;
0091   occ::handle<TNaming_NamedShape>                   myFeature;
0092   NCollection_List<occ::handle<TNaming_NamedShape>> myPrimitiveArgs;
0093   NCollection_List<TopoDS_Shape>                    myShapeArgs;
0094   occ::handle<TNaming_NamedShape>                   myNSContext;
0095 };
0096 
0097 #endif // _TNaming_Identifier_HeaderFile