NX Open C++ 参考指南 2406 v1.1
载入中...
搜索中...
未找到
ModelingViewCollection.hxx
1//--------------------------------------------------------------------------
2// Copyright 2024 Siemens
3//--------------------------------------------------------------------------
4// C++接口JA API的头文件
5//--------------------------------------------------------------------------
6//
7// 源文件:
8// ModelingViewCollection.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_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{
35 class BasePart;
36 class ModelingView;
37 class ModelingViewCollectionImpl;
43 {
44 private: ModelingViewCollectionImpl * m_modelingviewcollection_impl;
45 private: NXOpen::BasePart* m_owner;
47 public: explicit ModelingViewCollection(NXOpen::BasePart *owner);
49 public:
51 tag_t Tag() const;
54 //lint -sem(NXOpen::ModelingViewCollection::iterator::copy,initializer)
55 class iterator : public std::iterator<std::forward_iterator_tag, NXOpen::ModelingView *>
56 {
57 public:
59 iterator() : m_context(nullptr), m_current(NULL_TAG)
60 {
61 // coverity[uninit_member]
62 } //lint !e1401 m_state 未初始化
63
64 explicit iterator(NXOpen::ModelingViewCollection *context) : m_context(context), m_current(NULL_TAG)
65 {
66 // coverity[uninit_member]
67 }//lint !e1401 m_state 未初始化
69
70 iterator(const iterator &other): m_context(nullptr), m_current(NULL_TAG)
71 {
72 copy(other);
73 }
74
75 iterator &operator =(const iterator &other)
76 {
77 if (&other != this)
78 copy(other);
79 return *this;
80 }
81
82 bool operator ==(const iterator &other) const
83 {
84 return m_current == other.m_current && m_context == other.m_context;
85 }
86
87 bool operator !=(const iterator &other) const
88 {
89 return !operator == (other);
90 }
91
92 NXOPENCPPEXPORT value_type operator * () const;
94 iterator & operator ++()
95 {
96 next();
97 return *this;
98 }
99
100 iterator operator ++(int)
101 {
102 iterator tmp(*this);
103 ++*this;
104 return tmp;
105 }
106 private:
107 void copy(const iterator &other)
108 {
109 m_context = other.m_context;
110 m_current = other.m_current;
111 for (int i = 0; i < sizeof(m_state)/sizeof(m_state[0]); i++)
112 m_state[i] = other.m_state[i];
113 }
114 NXOPENCPPEXPORT void next();
116 tag_t m_current;
117 unsigned int m_state[8];
118 };
119
123 {
124 return iterator(this);
125 }
126
131 (
132 const NXString & journalIdentifier
133 );
139 (
140 const char * journalIdentifier
141 );
146 (
147 );
152 (
153 bool expand
154 );
155 }; //lint !e1712 类未定义默认构造函数
156}
157#ifdef _MSC_VER
158#pragma warning(pop)
159#endif
160#ifdef __GNUC__
161#ifndef NX_NO_GCC_DEPRECATION_WARNINGS
162#pragma GCC diagnostic warning "-Wdeprecated-declarations"
163#endif
164#endif
165#undef EXPORTLIBRARY