Itasca C++ Interface
Loading...
Searching...
No Matches
irange.h
Go to the documentation of this file.
1#pragma once
2
3#include "base/src/baseqt.h"
5#include "shared/interface/signal.h"
6
12namespace itasca {
13 class Archive2;
14 class IThing;
15}
16
17namespace itascaxd {
18 using namespace itasca;
19
20 class IRangeElement;
21
23
32 class IRange {
33 public:
35 inline static const TType type_ = 0x4c815b93;
36
37 shared::Signal<IRangeElement *, int> elementChanged; // elem, index
38 shared::Signal<IRangeElement *, bool> notChanged; // elem, notChanged
39 shared::Signal<IRangeElement *,const QString &> byChanged;
40 shared::Signal<int32> listChanged; // length
41 shared::Signal<const QString &> nameChanged; // name
42 shared::Signal<bool> unionChanged;
43 shared::Signal<bool> useHiddenChanged;
44 shared::Signal<bool> selectedChanged;
45 shared::Signal<bool> deselectedChanged;
46
48 virtual const itasca::IThing *getIThing() const=0;
51
53 virtual void clear()=0;
54
56 virtual const IRange &operator=(const IRange &ir)=0;
57
59 virtual IRange *clone() const=0;
60
63 virtual IString getName() const=0;
65 virtual void setName(const QString &s)=0;
66
68 virtual bool isUnion() const=0;
71 virtual void setUnion(bool b)=0;
72
74 virtual int getNumberOfElements() const=0;
75
77 virtual IRangeElement *getElement(int index) const=0;
78
80 virtual void removeElement(int index)=0;
81
85 virtual QStringList getCommandSwitches() const=0;
86
90 virtual const IRange *getNext() const=0;
91
93 virtual bool recursionCheck() const=0;
94
98 virtual void addElement(const QString &name)=0;
99
102 virtual bool isIn(const itasca::IThing *t) const=0;
103
106 virtual bool isIn(const itasca::IThing &t) const=0;
107
110 virtual bool isIn(const DVect &pos) const=0;
111
115 virtual bool isIn(qint64 index,const TType &type) const=0;
116
117 virtual void save(Archive2 &a) const=0;
118 virtual bool restore(Archive2 &a,uint64 label)=0;
119 virtual void remap(Archive2 &a)=0;
120
121 virtual void saveElement(Archive2 &a,int index) const=0;
122 virtual bool restoreElement(Archive2 &a)=0;
123
125 virtual bool getIsFish() const=0;
126
133 virtual bool isThreadSafe() const=0;
134
138 virtual void setUseHidden(bool b)=0;
139
141 virtual bool getUseHidden() const=0;
142
148 virtual bool setSelected(bool b)=0;
149
151 virtual bool getSelected() const=0;
152
153 virtual bool setDeselected(bool b)=0;
154 virtual bool getDeselected() const=0;
155
156 virtual bool isDefault() const=0;
157
159 virtual void destroy()=0;
160 };
161} // namespace itascaxd
162// EoF
All default base headers if Qt is being used.
Definition istring.h:14
Base class for items that will be stored in containers.
Definition ithing.h:30
Interface to a filter element, which is a member of a IRange..
Definition irangeelement.h:19
Interface to a filter, used as the main method for filtering objects.
Definition irange.h:32
virtual bool isIn(const itasca::IThing &t) const =0
virtual const itasca::IThing * getIThing() const =0
Returns a const IThing interface pointer for a filter.
virtual int getNumberOfElements() const =0
Returns the number of RangeElement making up the filter.
static const TType type_
The type identification number for this class, for use in convert_cast() and convert_getcast().
Definition irange.h:35
virtual IString getName() const =0
virtual bool getIsFish() const =0
Returns true if a filter element is a FISH filter element.
virtual void setUnion(bool b)=0
virtual const IRange & operator=(const IRange &ir)=0
Copy a filter - including name.
virtual bool setSelected(bool b)=0
virtual void addElement(const QString &name)=0
virtual bool isIn(const itasca::IThing *t) const =0
virtual void removeElement(int index)=0
Removes element at index from the filter, assumes index is less than getNumberOfElements().
virtual bool isIn(qint64 index, const TType &type) const =0
virtual QStringList getCommandSwitches() const =0
virtual itasca::IThing * getIThing()=0
Returns a IThing interface pointer for a filter.
virtual IRange * clone() const =0
Creates a new instance of a filter - must be destroyed by the caller.
virtual void setUseHidden(bool b)=0
virtual void setName(const QString &s)=0
sets the filter name
virtual bool getSelected() const =0
Return the current selected state. See setSelected.
virtual const IRange * getNext() const =0
virtual bool isUnion() const =0
Indicates if filter is a union of filter elements.
virtual bool isIn(const DVect &pos) const =0
virtual void clear()=0
clear all elements, set to union, and remove name
virtual bool getUseHidden() const =0
Returns the current hidden state. See setUseHidden().
virtual bool isThreadSafe() const =0
virtual void destroy()=0
Destroys the filter.
virtual IRangeElement * getElement(int index) const =0
Returns the RangeElement at the given index, where index is less than getNumberOfElements().
virtual bool recursionCheck() const =0
Checks to see if an infinitely recursive named filter topology has been created.
DIM - Provides code portability between 2D and 3D codes.
uint32 TType
class type indicator
Definition basedef.h:46
DVect3 DVect
Vector of doubles, either 2D or 3D.
Definition dim.h:154
namespace Itasca
Definition basememory.cpp:14
Itasca Library standard namespace, specific to 2D or 3D.
Definition icontactmodule.h:4