NX Open C++ 参考指南 2406 v1.1
载入中...
搜索中...
未找到
Layout2d_ComponentCollection.hxx
1//--------------------------------------------------------------------------
2// Copyright 2024 Siemens
3//--------------------------------------------------------------------------
4// C++接口JA API的头文件
5//--------------------------------------------------------------------------
6//
7// 源文件:
8// Layout2d_ComponentCollection.ja
9//
10// 生成工具:
11// apiwrap
12//
13// 警告:
14// 此文件由自动生成 - 请勿手动编辑
15//
16#pragma once
17#include <NXOpen/NXDeprecation.hxx>
18#include <iterator>
19#include <vector>
20#include <NXOpen/NXString.hxx>
21#include <NXOpen/Callback.hxx>
22#include <NXOpen/Layout2d_AssemblyFromLayout2dBuilder.hxx>
23#include <NXOpen/Layout2d_AssociativeAssemblyBuilder.hxx>
24#include <NXOpen/Layout2d_ComponentActiveSetBuilder.hxx>
25#include <NXOpen/Layout2d_CreateComponentFrom3DBuilder.hxx>
26#include <NXOpen/Layout2d_DefineComponentAnchorPointBuilder.hxx>
27#include <NXOpen/Layout2d_DefineComponentBuilder.hxx>
28#include <NXOpen/Layout2d_ExportComponentHierarchyBuilder.hxx>
29#include <NXOpen/Layout2d_InheritDisplayAttributesBuilder.hxx>
30#include <NXOpen/Layout2d_InsertComponentBuilder.hxx>
31#include <NXOpen/Layout2d_MakeComponentUniqueBuilder.hxx>
32#include <NXOpen/Layout2d_NewComponentBuilder.hxx>
33#include <NXOpen/Layout2d_PublishComponentBuilder.hxx>
34#include <NXOpen/Layout2d_ReparentComponentBuilder.hxx>
35#include <NXOpen/Layout2d_ReplaceComponentBuilder.hxx>
36#include <NXOpen/Layout2d_SmashComponentBuilder.hxx>
37#include <NXOpen/TaggedObjectCollection.hxx>
38#include <NXOpen/TaggedObject.hxx>
39#include <NXOpen/libnxopencpp_layout2d_exports.hxx>
40#ifdef _MSC_VER
41#pragma warning(push)
42#pragma warning(disable:4996)
43#endif
44#ifdef __GNUC__
45#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
46#endif
47namespace NXOpen
48{
49 namespace Layout2d
50 {
52 }
53 class Part;
54 namespace Layout2d
55 {
56 class Component;
57 }
59 namespace Drawings
60 {
61 class OrderManager;
62 }
63 namespace Layout2d
64 {
66 }
67 namespace Layout2d
68 {
70 }
71 namespace Layout2d
72 {
74 }
75 namespace Layout2d
76 {
78 }
79 namespace Layout2d
80 {
82 }
83 namespace Layout2d
84 {
86 }
87 namespace Layout2d
88 {
90 }
91 namespace Layout2d
92 {
94 }
95 namespace Layout2d
96 {
98 }
99namespace Layout2d
100 {
102 }
103 namespace Layout2d
104 {
106 }
107 namespace Layout2d
108 {
110 }
111 namespace Layout2d
112 {
114 }
115 namespace Layout2d
116 {
118 }
119 namespace Layout2d
120 {
122 }
123 class View;
124 namespace Layout2d
125 {
126 class ComponentCollectionImpl;
130 class NXOPENCPP_LAYOUT2DEXPORT ComponentCollection : public NXOpen::TaggedObjectCollection
131 {
132 private: ComponentCollectionImpl * m_componentcollection_impl;
133 private: NXOpen::Part* m_owner;
135 public: explicit ComponentCollection(NXOpen::Part *owner);
137 public:
139 tag_t Tag() const;
140 public: ~ComponentCollection();
142 //lint -sem(NXOpen::Layout2d::ComponentCollection::iterator::copy,initializer)
143 class iterator : public std::iterator<std::forward_iterator_tag, NXOpen::Layout2d::Component *>
144 {
145 public:
147 iterator() : m_context(nullptr), m_current(NULL_TAG)
148 {
149 // coverity[uninit_member]
150 } //lint !e1401 m_state 未初始化
151
152 explicit iterator(NXOpen::Layout2d::ComponentCollection *context) : m_context(context), m_current(NULL_TAG)
153 {
154 // coverity[uninit_member]
155 }//lint !e1401 m_state 未初始化
157
158 iterator(const iterator &other): m_context(nullptr), m_current(NULL_TAG)
159 {
160 copy(other);
161 }
162
163 iterator &operator =(const iterator &other)
164 {
165 if (&other != this)
166 copy(other);
167 return *this;
168 }
169
170 bool operator ==(const iterator &other) const
171 {
172 return m_current == other.m_current && m_context == other.m_context;
173 }
174
175 bool operator !=(const iterator &other) const
176 {
177 return !operator == (other);
178 }
179
180 NXOPENCPP_LAYOUT2DEXPORT value_type operator * () const;
182 iterator & operator ++()
183 {
184 next();
185 return *this;
186 }
187
188 iterator operator ++(int)
189 {
190 iterator tmp(*this);
191 ++*this;
192 return tmp;
193 }
194 private:
195 void copy(const iterator &other)
196 {
197 m_context = other.m_context;
198 m_current = other.m_current;
199 for (int i = 0; i < sizeof(m_state)/sizeof(m_state[0]); i++)
200m_state[i] = other.m_state[i];
201 }
202 NXOPENCPP_LAYOUT2DEXPORT void next();
204 tag_t m_current;
205 unsigned int m_state[8];
206 };
207
211 {
212 return iterator(this);
213 }
214
220 (
221 const NXString & journalIdentifier
222 );
229 (
230 const char * journalIdentifier
231 );
236 (
237 NXOpen::Layout2d::Component * component
238 );
243 (
244 );
249 (
250 );
255 (
256 );
261 (
262 );
267 (
268 );
273 (
274 );
279 (
280 );
284 public: void DeleteComponents
285 (
286 const std::vector<NXOpen::Layout2d::Component *> & components
287 );
291 public: bool IsComponentMember
292 (
293 NXOpen::DisplayableObject * disObject
294 );
299 (
300 );
305 (
306 );
310 public: void UpdateComponents
311 (
312 const std::vector<NXOpen::Layout2d::Component *> & components
313 );
318 (
319 const std::vector<NXOpen::Layout2d::Component *> & components
320 );
325 (
326 NXOpen::View * myView
327 );
332 (
333 );
338 (
339 );
344 (
345 );
350 (
351 );
356 }; //lint !e1712 default constructor not defined for class
357 }
358}
359#ifdef _MSC_VER
360#pragma warning(pop)
361#endif
362#ifdef __GNUC__
363#ifndef NX_NO_GCC_DEPRECATION_WARNINGS
364#pragma GCC diagnostic warning "-Wdeprecated-declarations"
365#endif
366#endif
367#undef EXPORTLIBRARY