NX Open C++ 参考指南 2406 v1.1
载入中...
搜索中...
未找到
Assemblies_RelinkerCollection.hxx
1//--------------------------------------------------------------------------
2// Copyright 2024 Siemens
3//--------------------------------------------------------------------------
4// JA API的C++接口头文件
5//--------------------------------------------------------------------------
6//
7// 源文件:
8// Assemblies_RelinkerCollection.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/TaggedObjectCollection.hxx>
23#include <NXOpen/TaggedObject.hxx>
24#include <NXOpen/libnxopencpp_assemblies_exports.hxx>
25#ifdef _MSC_VER
26#pragma warning(push)
27#pragma warning(disable:4996)
28#endif
29#ifdef __GNUC__
30#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
31#endif
32namespace NXOpen
33{
34 namespace Assemblies
35 {
37 }
38 class Part;
39 namespace Assemblies
40 {
41 class RelinkerBuilder;
42 }
43 namespace Assemblies
44 {
45 class RelinkerCollectionImpl;
49 class NXOPENCPP_ASSEMBLIESEXPORT RelinkerCollection : public NXOpen::TaggedObjectCollection
50 {
51 private: RelinkerCollectionImpl * m_relinkercollection_impl;
52 private: NXOpen::Part* m_owner;
54 public: explicit RelinkerCollection(NXOpen::Part *owner);
56 public:
58 tag_t Tag() const;
59 public: ~RelinkerCollection();
61 //lint -sem(NXOpen::Assemblies::RelinkerCollection::iterator::copy,initializer)
62 class iterator : public std::iterator<std::forward_iterator_tag, NXOpen::Assemblies::RelinkerBuilder *>
63 {
64 public:
66 iterator() : m_context(nullptr), m_current(NULL_TAG)
67 {
68 // coverity[uninit_member]
69 } //lint !e1401 m_state is not initialized
70
71 explicit iterator(NXOpen::Assemblies::RelinkerCollection *context) : m_context(context), m_current(NULL_TAG)
72 {
73 // coverity[uninit_member]
74 }//lint !e1401 m_state is not initialized
76
77 iterator(const iterator &other): m_context(nullptr), m_current(NULL_TAG)
78 {
79 copy(other);
80 }
81
82 iterator &operator =(const iterator &other)
83 {
84 if (&other != this)
85 copy(other);
86 return *this;
87 }
88
89 bool operator ==(const iterator &other) const
90 {
91 return m_current == other.m_current && m_context == other.m_context;
92 }
93
94 bool operator !=(const iterator &other) const
95 {
96 return !operator == (other);
97 }
98
99 NXOPENCPP_ASSEMBLIESEXPORT value_type operator * () const;
101 iterator & operator ++()
102 {
103 next();
104 return *this;
105 }
106
107 iterator operator ++(int)
108 {
109 iterator tmp(*this);
110 ++*this;
111 return tmp;
112 }
113 private:
114 void copy(const iterator &other)
115 {
116 m_context = other.m_context;
117 m_current = other.m_current;
118 for (int i = 0; i < sizeof(m_state)/sizeof(m_state[0]); i++)
119 m_state[i] = other.m_state[i];
120 }
121 NXOPENCPP_ASSEMBLIESEXPORT void next();
123 tag_t m_current;
124 unsigned int m_state[8];
125 };
126
130 {
131 return iterator(this);
132 }
133
137 (
138 );
139 }; //lint !e1712 default constructor not defined for class
140 }
141}
142#ifdef _MSC_VER
143#pragma warning(pop)
144#endif
145#ifdef __GNUC__
146#ifndef NX_NO_GCC_DEPRECATION_WARNINGS
147#pragma GCC diagnostic warning "-Wdeprecated-declarations"
148#endif
149#endif
150#undef EXPORTLIBRARY