0031642: Visualization - crash in Graphic3d_Structure::SetVisual() on redisplaying...
[occt.git] / src / IGESDimen / IGESDimen_GeneralSymbol.hxx
CommitLineData
42cf5bc1 1// Created on: 1993-01-09
2// Created by: CKY / Contract Toubro-Larsen (Anand NATRAJAN)
3// Copyright (c) 1993-1999 Matra Datavision
4// Copyright (c) 1999-2014 OPEN CASCADE SAS
5//
6// This file is part of Open CASCADE Technology software library.
7//
8// This library is free software; you can redistribute it and/or modify it under
9// the terms of the GNU Lesser General Public License version 2.1 as published
10// by the Free Software Foundation, with special exception defined in the file
11// OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
12// distribution for complete text of the license and disclaimer of any warranty.
13//
14// Alternatively, this file may be used under the terms of Open CASCADE
15// commercial license or contractual agreement.
16
17#ifndef _IGESDimen_GeneralSymbol_HeaderFile
18#define _IGESDimen_GeneralSymbol_HeaderFile
19
20#include <Standard.hxx>
21#include <Standard_Type.hxx>
22
23#include <IGESData_HArray1OfIGESEntity.hxx>
24#include <IGESDimen_HArray1OfLeaderArrow.hxx>
25#include <IGESData_IGESEntity.hxx>
26#include <Standard_Integer.hxx>
27#include <Standard_Boolean.hxx>
28class IGESDimen_GeneralNote;
29class Standard_OutOfRange;
30class IGESData_IGESEntity;
31class IGESDimen_LeaderArrow;
32
33
34class IGESDimen_GeneralSymbol;
35DEFINE_STANDARD_HANDLE(IGESDimen_GeneralSymbol, IGESData_IGESEntity)
36
37//! defines General Symbol, Type <228>, Form <0-3,5001-9999>
38//! in package IGESDimen
39//! Consists of zero or one (Form 0) or one (all other
40//! forms), one or more geometry entities which define
41//! a symbol, and zero, one or more associated leaders.
42class IGESDimen_GeneralSymbol : public IGESData_IGESEntity
43{
44
45public:
46
47
48 Standard_EXPORT IGESDimen_GeneralSymbol();
49
50 //! This method is used to set the fields of the class
51 //! GeneralSymbol
52 //! - aNote : General Note, null for form 0
53 //! - allGeoms : Geometric Entities
54 //! - allLeaders : Leader Arrows
55 Standard_EXPORT void Init (const Handle(IGESDimen_GeneralNote)& aNote, const Handle(IGESData_HArray1OfIGESEntity)& allGeoms, const Handle(IGESDimen_HArray1OfLeaderArrow)& allLeaders);
56
57 //! Changes FormNumber (indicates the Nature of the Symbole)
58 //! Error if not in ranges [0-3] or [> 5000]
59 Standard_EXPORT void SetFormNumber (const Standard_Integer form);
60
61 //! returns True if there is associated General Note Entity
62 Standard_EXPORT Standard_Boolean HasNote() const;
63
64 //! returns Null handle for form 0 only
65 Standard_EXPORT Handle(IGESDimen_GeneralNote) Note() const;
66
67 //! returns number of Geometry Entities
68 Standard_EXPORT Standard_Integer NbGeomEntities() const;
69
70 //! returns the Index'th Geometry Entity
71 //! raises exception if Index <= 0 or Index > NbGeomEntities()
72 Standard_EXPORT Handle(IGESData_IGESEntity) GeomEntity (const Standard_Integer Index) const;
73
74 //! returns number of Leaders or zero if not specified
75 Standard_EXPORT Standard_Integer NbLeaders() const;
76
77 //! returns the Index'th Leader Arrow
78 //! raises exception if Index <= 0 or Index > NbLeaders()
79 Standard_EXPORT Handle(IGESDimen_LeaderArrow) LeaderArrow (const Standard_Integer Index) const;
80
81
82
83
92efcf78 84 DEFINE_STANDARD_RTTIEXT(IGESDimen_GeneralSymbol,IGESData_IGESEntity)
42cf5bc1 85
86protected:
87
88
89
90
91private:
92
93
94 Handle(IGESDimen_GeneralNote) theNote;
95 Handle(IGESData_HArray1OfIGESEntity) theGeoms;
96 Handle(IGESDimen_HArray1OfLeaderArrow) theLeaders;
97
98
99};
100
101
102
103
104
105
106
107#endif // _IGESDimen_GeneralSymbol_HeaderFile