Itasca C++ Interface
Loading...
Searching...
No Matches
irange.h
Go to the documentation of this file.
1#pragma once
2
4#include "shared/interface/signal.h"
5
11namespace itasca {
12 class Archive2;
13 class IThing;
14}
15
16namespace itascaxd {
17 using namespace itasca;
18
19 class IRangeElement;
20
22
31 class IRange {
32 public:
34 inline static const TType type_ = 0x4c815b93;
35
36 shared::Signal<IRangeElement *, int> elementChanged; // elem, index
37 shared::Signal<IRangeElement *, bool> notChanged; // elem, notChanged
38 shared::Signal<IRangeElement *,const string &> byChanged;
39 shared::Signal<int32> listChanged; // length
40 shared::Signal<const string &> nameChanged; // name
41 shared::Signal<bool> unionChanged;
42 shared::Signal<bool> useHiddenChanged;
43 shared::Signal<bool> selectedChanged;
44 shared::Signal<bool> deselectedChanged;
45
47 virtual const itasca::IThing *getIThing() const=0;
50
52 virtual void clear()=0;
53
55 virtual const IRange &operator=(const IRange &ir)=0;
56
58 virtual IRange *clone() const=0;
59
62 virtual string getName() const=0;
64 virtual void setName(const string &s)=0;
65
67 virtual bool isUnion() const=0;
70 virtual void setUnion(bool b)=0;
71
73 virtual int getNumberOfElements() const=0;
74
76 virtual IRangeElement *getElement(int index) const=0;
77
79 virtual void removeElement(int index)=0;
80
84 virtual StringList getCommandSwitches() const=0;
85
89 virtual const IRange *getNext() const=0;
90
92 virtual bool recursionCheck() const=0;
93
97 virtual void addElement(const string &name)=0;
98
101 virtual bool isIn(const itasca::IThing *t) const=0;
102
105 virtual bool isIn(const itasca::IThing &t) const=0;
106
109 virtual bool isIn(const DVect &pos) const=0;
110
114 virtual bool isIn(int64 index,const TType &type) const=0;
115
116 virtual void save(Archive2 &a) const=0;
117 virtual bool restore(Archive2 &a,uint64 label)=0;
118 virtual void remap(Archive2 &a)=0;
119
120 virtual void saveElement(Archive2 &a,int index) const=0;
121 virtual bool restoreElement(Archive2 &a)=0;
122
124 virtual bool getIsFish() const=0;
125
132 virtual bool isThreadSafe() const=0;
133
137 virtual void setUseHidden(bool b)=0;
138
140 virtual bool getUseHidden() const=0;
141
147 virtual bool setSelected(bool b)=0;
148
150 virtual bool getSelected() const=0;
151
152 virtual bool setDeselected(bool b)=0;
153 virtual bool getDeselected() const=0;
154
155 virtual bool isDefault() const=0;
156
158 virtual void destroy()=0;
159 };
160} // namespace itascaxd
161// EoF
Definition basestring.h:71
Base class for items that will be stored in containers.
Definition ithing.h:31
Interface to a filter element, which is a member of a IRange..
Definition irangeelement.h:18
Interface to a filter, used as the main method for filtering objects.
Definition irange.h:31
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:34
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 setName(const string &s)=0
sets the filter name
virtual bool isIn(const itasca::IThing *t) const =0
virtual bool isIn(int64 index, const TType &type) const =0
virtual void removeElement(int index)=0
Removes element at index from the filter, assumes index is less than getNumberOfElements().
virtual void addElement(const string &name)=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 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 string getName() const =0
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 StringList getCommandSwitches() const =0
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:47
DVect3 DVect
Vector of doubles, either 2D or 3D.
Definition dim.h:156
namespace Itasca
Definition basememory.cpp:14
Itasca Library standard namespace, specific to 2D or 3D.
Definition icontactmodule.h:6