Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2026-10-23 09:22:01

0001 // Created on: 1997-03-19
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_Name_HeaderFile
0018 #define _TNaming_Name_HeaderFile
0019 
0020 #include <Standard.hxx>
0021 #include <Standard_DefineAlloc.hxx>
0022 #include <Standard_Handle.hxx>
0023 
0024 #include <TNaming_NameType.hxx>
0025 #include <TopAbs_ShapeEnum.hxx>
0026 #include <TNaming_NamedShape.hxx>
0027 #include <NCollection_List.hxx>
0028 #include <Standard_Integer.hxx>
0029 #include <TopoDS_Shape.hxx>
0030 #include <TDF_Label.hxx>
0031 #include <TopAbs_Orientation.hxx>
0032 #include <NCollection_Map.hxx>
0033 class TNaming_NamedShape;
0034 class TDF_RelocationTable;
0035 
0036 //! store the arguments of Naming.
0037 class TNaming_Name
0038 {
0039 public:
0040   DEFINE_STANDARD_ALLOC
0041 
0042   Standard_EXPORT TNaming_Name();
0043 
0044   Standard_EXPORT void Type(const TNaming_NameType aType);
0045 
0046   Standard_EXPORT void ShapeType(const TopAbs_ShapeEnum aType);
0047 
0048   Standard_EXPORT void Shape(const TopoDS_Shape& theShape);
0049 
0050   Standard_EXPORT void Append(const occ::handle<TNaming_NamedShape>& arg);
0051 
0052   Standard_EXPORT void StopNamedShape(const occ::handle<TNaming_NamedShape>& arg);
0053 
0054   Standard_EXPORT void Index(const int I);
0055 
0056   Standard_EXPORT void ContextLabel(const TDF_Label& theLab);
0057 
0058   Standard_EXPORT void Orientation(const TopAbs_Orientation theOrientation);
0059 
0060   Standard_EXPORT TNaming_NameType Type() const;
0061 
0062   Standard_EXPORT TopAbs_ShapeEnum ShapeType() const;
0063 
0064   Standard_EXPORT TopoDS_Shape Shape() const;
0065 
0066   Standard_EXPORT const NCollection_List<occ::handle<TNaming_NamedShape>>& Arguments() const;
0067 
0068   Standard_EXPORT occ::handle<TNaming_NamedShape> StopNamedShape() const;
0069 
0070   Standard_EXPORT int Index() const;
0071 
0072   Standard_EXPORT const TDF_Label& ContextLabel() const;
0073 
0074   TopAbs_Orientation Orientation() const { return myOrientation; }
0075 
0076   Standard_EXPORT bool Solve(const TDF_Label& aLab, const NCollection_Map<TDF_Label>& Valid) const;
0077 
0078   Standard_EXPORT void Paste(TNaming_Name& into, const occ::handle<TDF_RelocationTable>& RT) const;
0079 
0080   //! Dumps the content of me into the stream
0081   Standard_EXPORT void DumpJson(Standard_OStream& theOStream, int theDepth = -1) const;
0082 
0083 private:
0084   TNaming_NameType                                  myType;
0085   TopAbs_ShapeEnum                                  myShapeType;
0086   NCollection_List<occ::handle<TNaming_NamedShape>> myArgs;
0087   occ::handle<TNaming_NamedShape>                   myStop;
0088   int                                               myIndex;
0089   TopoDS_Shape                                      myShape;
0090   TDF_Label                                         myContextLabel;
0091   TopAbs_Orientation                                myOrientation;
0092 };
0093 
0094 #endif // _TNaming_Name_HeaderFile