NX Open C++ 参考指南 2406 v1.1
载入中...
搜索中...
未找到
Motion_MotionSolutionCollection.hxx
1//--------------------------------------------------------------------------
2// Copyright 2024 Siemens
3//--------------------------------------------------------------------------
4// C++接口到JA API的头文件
5//--------------------------------------------------------------------------
6//
7// 源文件:
8// Motion_MotionSolutionCollection.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/Motion_AdvancedSolution.hxx>
23#include <NXOpen/Motion_AdvancedSolutionBuilder.hxx>
24#include <NXOpen/Motion_MotionSolution.hxx>
25#include <NXOpen/Motion_MotionSolutionBuilder.hxx>
26#include <NXOpen/TaggedObjectCollection.hxx>
27#include <NXOpen/TaggedObject.hxx>
28#include <NXOpen/libnxopencpp_motion_exports.hxx>
29#ifdef _MSC_VER
30#pragma warning(push)
31#pragma warning(disable:4996)
32#endif
33#ifdef __GNUC__
34#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
35#endif
36namespace NXOpen
37{
38 namespace Motion
39 {
41 }
42 namespace Motion
43 {
44 class MotionManager;
45 }
46 namespace Motion
47 {
48 class MotionSolution;
49 }
50 namespace Motion
51 {
52 class AdvancedSolution;
53 }
54 namespace Motion
55 {
57 }
58 namespace Motion
59 {
61 }
62 namespace Motion
63 {
64 class MotionSolutionCollectionImpl;
68 class NXOPENCPP_MOTIONEXPORT MotionSolutionCollection : public NXOpen::TaggedObjectCollection
69 {
70 private: MotionSolutionCollectionImpl * m_motionsolutioncollection_impl;
71 private: NXOpen::Motion::MotionManager* m_owner;
75 public:
77 tag_t Tag() const;
80 //lint -sem(NXOpen::Motion::MotionSolutionCollection::iterator::copy,initializer)
81 class iterator : public std::iterator<std::forward_iterator_tag, NXOpen::Motion::MotionSolution *>
82 {
83 public:
85 iterator() : m_context(nullptr), m_current(NULL_TAG)
86 {
87 // coverity[uninit_member]
88 } //lint !e1401 m_state is not initialized
89
90 explicit iterator(NXOpen::Motion::MotionSolutionCollection *context) : m_context(context), m_current(NULL_TAG)
91 {
92 // coverity[uninit_member]
93 }//lint !e1401 m_state is not initialized
95
96 iterator(const iterator &other): m_context(nullptr), m_current(NULL_TAG)
97{
98 copy(other);
99 }
100
101 iterator &operator =(const iterator &other)
102 {
103 if (&other != this)
104 copy(other);
105 return *this;
106 }
107
108 bool operator ==(const iterator &other) const
109 {
110 return m_current == other.m_current && m_context == other.m_context;
111 }
112
113 bool operator !=(const iterator &other) const
114 {
115 return !operator == (other);
116 }
117
118 NXOPENCPP_MOTIONEXPORT value_type operator * () const;
120 iterator & operator ++()
121 {
122 next();
123 return *this;
124 }
125
126 iterator operator ++(int)
127 {
128 iterator tmp(*this);
129 ++*this;
130 return tmp;
131 }
132 private:
133 void copy(const iterator &other)
134 {
135 m_context = other.m_context;
136 m_current = other.m_current;
137 for (int i = 0; i < sizeof(m_state)/sizeof(m_state[0]); i++)
138 m_state[i] = other.m_state[i];
139 }
140 NXOPENCPP_MOTIONEXPORT void next();
142 tag_t m_current;
143 unsigned int m_state[8];
144 };
145
149 {
150 return iterator(this);
151 }
152
156 (
159 );
165 (
166 const std::vector<NXOpen::Motion::MotionSolution *> & solutions
167 );
172 (
173 const NXString & name
174 );
179 (
180 const char * name
181 );
186 (
187 );
191 public: void SetActiveSolution
192 (
193 NXOpen::Motion::MotionSolution * activeSolution
194 );
198 public: void DeleteSolution
199 (
201 bool ifDeleteResult
202 );
207 (
208 NXOpen::Motion::AdvancedSolution * advancedSolution
209 );
210 }; //lint !e1712 default constructor not defined for class
211 }
212}
213#ifdef _MSC_VER
214#pragma warning(pop)
215#endif
216#ifdef __GNUC__
217#ifndef NX_NO_GCC_DEPRECATION_WARNINGS
218#pragma GCC diagnostic warning "-Wdeprecated-declarations"
219#endif
220#endif
221#undef EXPORTLIBRARY