CFx SDK Documentation 2024 SP0
Loading...
Searching...
No Matches
SSet.h
Go to the documentation of this file.
1
2// Copyright (C) 2002-2022, Open Design Alliance (the "Alliance").
3// All rights reserved.
4//
5// This software and its documentation and related materials are owned by
6// the Alliance. The software may only be incorporated into application
7// programs owned by members of the Alliance, subject to a signed
8// Membership Agreement and Supplemental Software License Agreement with the
9// Alliance. The structure and organization of this software are the valuable
10// trade secrets of the Alliance and its suppliers. The software is also
11// protected by copyright law and international treaty provisions. Application
12// programs incorporating this software must include the following statement
13// with their copyright notices:
14//
15// This application incorporates Open Design Alliance software pursuant to a license
16// agreement with Open Design Alliance.
17// Open Design Alliance Copyright (C) 2002-2022 by Open Design Alliance.
18// All rights reserved.
19//
20// By use of this software, its documentation or related materials, you
21// acknowledge and accept the above terms.
23
24#ifndef _SSET_H_
25#define _SSET_H_
26
27#include "OdPlatform.h"
28
29#include "Ge/GePoint3d.h"
30#include "DbBaseSubentId.h"
31
38{
39protected:
41public:
43};
44
46
47class OdGiViewport;
48
54{
55protected:
57public:
59
60 enum Mode
61 {
62 kPoint = 0, // Selection by single point. Returns single object: top for 3D render modes or first for 2D render mode.
63 kBox = 1, // Selection by two points (represents rectangle) and choose between kWindow and kCrossing modes using direction vector between points.
64 kWindow = 2, // Selection by two points (represents rectangle). Select only objects which is entirely inside selection area.
65 kCrossing = 3, // Selection by two points (represents rectangle). Select objects which is entirely inside or intersects selection area.
66 kFence = 4, // Selection by two or more points (represents polyline). Select object which is intersects selection polyline.
67 kWPoly = 5, // Selection by three or more points (represents polygon). Select only objects which is entirely inside selection area.
68 kCPoly = 6 // Selection by three or more points (represents polygon). Select objects which is entirely inside or intersects selection area.
69 };
70
72 {
73 kDisableSubents = 0,
74 kEnableSubents = 1,
75 // #CORE-13269 : include ModelSpace viewport into selection path.
76 kIncludeViewport = 2,
77 // #CORE-13761 : include nested entities even if them doesn't contain subentities (geometry markers).
78 kNestedEntities = 4
79 };
80
81 virtual OdDbStub* viewport() const = 0;
82 virtual OdGePoint3dArray points() const = 0;
83 virtual Mode mode() const = 0;
84};
85
87
88
99{
100public:
102
103 virtual OdDbSelectionMethodPtr method() const = 0;
104
108 virtual bool done() const = 0;
109
116 virtual bool next() = 0;
117
125 virtual OdUInt32 subentCount() = 0;
126
136 virtual bool getSubentity(OdUInt32 i, OdDbBaseFullSubentPath& path) = 0;
137
142 virtual OdDbStub* id() const = 0;
143
144protected:
146};
147
152
157
168{
169protected:
171public:
173
174 virtual const OdRxObject* baseDatabase() const = 0;
175
180
181 // operations on the selection set
182
186 virtual OdUInt32 numEntities() const = 0;
187
194 virtual OdUInt32 subentCount(OdDbStub* rootEntId = 0) const { return 0; }
195
202 virtual void append(OdDbStub* entityId, OdDbSelectionMethod* pMethod = 0) = 0;
203
209 virtual void append(const OdDbBaseFullSubentPath& subent, OdDbSelectionMethod* pMethod = 0) = 0;
210
216 virtual void append(const OdSelectionSet* pSSet) = 0;
217
223 virtual void remove(OdDbStub* entityId) = 0;
224
230 virtual void remove(const OdDbBaseFullSubentPath& subent) = 0;
231
237 virtual void remove(const OdSelectionSet* pSSet) = 0;
238
244 virtual bool isMember(OdDbStub* entityId) const = 0;
245
251 virtual bool isMember(const OdDbBaseFullSubentPath& subent) const = 0;
252
253 virtual OdDbSelectionMethodPtr method(OdDbStub* entityId) const = 0;
254
258 virtual void clear() = 0;
259};
260
261#endif //_SSET_H_
unsigned int OdUInt32
#define ODRX_ABSTRACT
#define FIRSTDLL_EXPORT
Definition: RootExport.h:39
OdSmartPtr< OdDbVisualSelection > OdDbVisualSelectionPtr
Definition: SSet.h:86
OdSmartPtr< OdSelectionSetIterator > OdSelectionSetIteratorPtr
Definition: SSet.h:151
OdSmartPtr< class OdSelectionSet > OdSelectionSetPtr
Definition: SSet.h:156
OdSmartPtr< OdDbSelectionMethod > OdDbSelectionMethodPtr
Definition: SSet.h:45
ODRX_DECLARE_MEMBERS(OdDbSelectionMethod)
virtual OdGePoint3dArray points() const =0
virtual Mode mode() const =0
virtual OdDbStub * viewport() const =0
ODRX_DECLARE_MEMBERS(OdDbVisualSelection)
virtual void remove(OdDbStub *entityId)=0
virtual OdUInt32 subentCount(OdDbStub *rootEntId=0) const
Definition: SSet.h:194
virtual void append(const OdDbBaseFullSubentPath &subent, OdDbSelectionMethod *pMethod=0)=0
virtual bool isMember(OdDbStub *entityId) const =0
virtual void remove(const OdDbBaseFullSubentPath &subent)=0
virtual OdUInt32 numEntities() const =0
virtual OdSelectionSetIteratorPtr newIterator() const =0
virtual void append(OdDbStub *entityId, OdDbSelectionMethod *pMethod=0)=0
ODRX_DECLARE_MEMBERS(OdSelectionSet)
virtual OdDbSelectionMethodPtr method(OdDbStub *entityId) const =0
virtual bool isMember(const OdDbBaseFullSubentPath &subent) const =0
virtual void remove(const OdSelectionSet *pSSet)=0
virtual const OdRxObject * baseDatabase() const =0
virtual void append(const OdSelectionSet *pSSet)=0
virtual void clear()=0
ODRX_DECLARE_MEMBERS(OdSelectionSetIterator)
virtual OdDbStub * id() const =0
virtual bool next()=0
virtual OdDbSelectionMethodPtr method() const =0
virtual bool done() const =0
virtual OdUInt32 subentCount()=0
virtual bool getSubentity(OdUInt32 i, OdDbBaseFullSubentPath &path)=0