NX Open C++ 参考指南 2406 v1.1
载入中...
搜索中...
未找到
DatumCollection.hxx
1//--------------------------------------------------------------------------
2// Copyright 2024 Siemens
3//--------------------------------------------------------------------------
4// JA API的C++接口头文件
5//--------------------------------------------------------------------------
6//
7// 源文件:
8// DatumCollection.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/ugmath.hxx>
25#include <NXOpen/libnxopencpp_exports.hxx>
26#ifdef _MSC_VER
27#pragma warning(push)
28#pragma warning(disable:4996)
29#endif
30#ifdef __GNUC__
31#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
32#endif
33namespace NXOpen
34{
35 class DatumCollection;
36 class BasePart;
38 class DatumAxis;
39 class DatumPlane;
40 class DatumCollectionImpl;
44 class NXOPENCPPEXPORT DatumCollection : public NXOpen::TaggedObjectCollection
45 {
46 private: DatumCollectionImpl * m_datumcollection_impl;
47 private: NXOpen::BasePart* m_owner;
49 public: explicit DatumCollection(NXOpen::BasePart *owner);
51 public:
53 tag_t Tag() const;
54 public: ~DatumCollection();
56 //lint -sem(NXOpen::DatumCollection::iterator::copy,initializer)
57 class iterator : public std::iterator<std::forward_iterator_tag, NXOpen::DisplayableObject *>
58 {
59 public:
61 iterator() : m_context(nullptr), m_current(NULL_TAG)
62 {
63 // coverity[uninit_member]
64 } //lint !e1401 m_state未初始化
65
66 explicit iterator(NXOpen::DatumCollection *context) : m_context(context), m_current(NULL_TAG)
67 {
68 // coverity[uninit_member]
69 }//lint !e1401 m_state未初始化
71
72 iterator(const iterator &other): m_context(nullptr), m_current(NULL_TAG)
73 {
74 copy(other);
75 }
76
77 iterator &operator =(const iterator &other)
78 {
79 if (&other != this)
80 copy(other);
81 return *this;
82 }
83
84 bool operator ==(const iterator &other) const
85 {
86 return m_current == other.m_current && m_context == other.m_context;
87 }
88
89 bool operator !=(const iterator &other) const
90 {
91 return !operator == (other);
92 }
93
94 NXOPENCPPEXPORT value_type operator * () const;
96 iterator & operator ++()
97 {
98 next();
99 return *this;
100 }
101
102 iterator operator ++(int)
103 {
104 iterator tmp(*this);
105 ++*this;
106 return tmp;
107 }
108 private:
109 void copy(const iterator &other)
110 {
111 m_context = other.m_context;
112 m_current = other.m_current;
113 for (int i = 0; i < sizeof(m_state)/sizeof(m_state[0]); i++)
114 m_state[i] = other.m_state[i];
115 }
116 NXOPENCPPEXPORT void next();
117 NXOpen::DatumCollection *m_context;
118 tag_t m_current;
119 unsigned int m_state[8];
120 };
121
125 {
126 return iterator(this);
127 }
128
132 (
133 const NXOpen::Point3d & origin ,
134 const NXOpen::Matrix3x3 & orientation
135 );
141 (
142 const NXOpen::Point3d & start ,
143 const NXOpen::Point3d & end
144 );
149 (
150 const NXString & journalIdentifier
151 );
156 (
157 const char * journalIdentifier
158 );
159 }; //lint !e1712 类未定义默认构造函数
160}
161#ifdef _MSC_VER
162#pragma warning(pop)
163#endif
164#ifdef __GNUC__
165#ifndef NX_NO_GCC_DEPRECATION_WARNINGS
166#pragma GCC diagnostic warning "-Wdeprecated-declarations"
167#endif
168#endif
169#undef EXPORTLIBRARY