Itasca C++ Interface
Loading...
Searching...
No Matches
iudtypelist.h
Go to the documentation of this file.
1#pragma once
2// iudtypelist.h
3
8#include "utility/interface/igroup.h"
10
11namespace itasca {
12 class IContainer;
13}
14
15namespace itascaxd {
16 using namespace itasca;
17
19
25 template <class T> class IUDTypeList {
26 public:
28 typedef T ivalue_type;
29
31 virtual IThing *getIThing()=0;
33 virtual const IThing *getIThing() const=0;
34
38 virtual const IContainer *getIContainer() const=0;
39
41 virtual const T *getFirst() const=0;
42
44 virtual T * getFirst()=0;
45
47 virtual const T *lookupWithID(uint64 ul) const=0;
48
50 virtual T * lookupWithID(uint64 ul)=0;
51
53 virtual T *create()=0;
54
56 virtual uint32 getExtraNotice() const=0;
58 virtual uint32 getGroupNotice() const=0;
60 virtual uint32 getPositionNotice() const=0;
62 virtual uint32 getValueNotice() const=0;
64 virtual uint32 getHideNotice() const=0;
66 virtual uint32 getSelectNotice() const=0;
67
69 virtual TType getType() const=0;
71 virtual QString getLabel() const=0;
72
74 virtual T * findNear(const DVect &pos,const double &rad=limits<double>::max())=0;
76 virtual const T *findNear(const DVect &pos,const double &rad=limits<double>::max()) const=0;
78 virtual void erase(T *pnt)=0;
80 virtual bool importFromFile(const QString &filename,const IGroupID &group)=0;
84 virtual bool exportToFile(const QString &filename,bool binary,const IRange *filter=0,const QString &comment=QString())=0;
85 };
86} // namespace itascaxd
Interface for containers of IThings.
Definition icontainer.h:21
Definition igroup.h:82
Base class for items that will be stored in containers.
Definition ithing.h:30
Interface to a filter, used as the main method for filtering objects.
Definition irange.h:32
Interface to a container of user-define data value types.
Definition iudtypelist.h:25
virtual bool exportToFile(const QString &filename, bool binary, const IRange *filter=0, const QString &comment=QString())=0
virtual void erase(T *pnt)=0
Removes the object /a pnt, which is assumed to be in the container. /a pnt is destroyed.
virtual uint32 getPositionNotice() const =0
Returns the NoticeManager Code for position of object changing.
virtual uint32 getHideNotice() const =0
Returns the NoticeManager Code for hide status changing.
virtual TType getType() const =0
Returns the type indicator of the objects it contains.
T ivalue_type
The type T that this list contains.
Definition iudtypelist.h:28
virtual IThing * getIThing()=0
returns a IThing pointer
virtual const IThing * getIThing() const =0
returns a const IThing pointer
virtual bool importFromFile(const QString &filename, const IGroupID &group)=0
Imports objects of type T from the file /a filename. All objects created are assigned a group of /a g...
virtual const IContainer * getIContainer() const =0
Returns a pointer to the container class representing a list of user defined objects.
virtual T * lookupWithID(uint64 ul)=0
Find a pointer to the T object with ID ul, or 0 if no match is found.
virtual const T * findNear(const DVect &pos, const double &rad=limits< double >::max()) const =0
Returns the object whose position is closest to /a pos.
virtual uint32 getValueNotice() const =0
Returns the NoticeManager Code for object values changing.
virtual uint32 getGroupNotice() const =0
Returns the NoticeManager Code for group assignments changing.
virtual IContainer * getIContainer()=0
Returns a pointer to the container class representing a list of user defined objects.
virtual T * getFirst()=0
Returns a pointer to the first T in the list. Use T::getNext() to iterate through the entire list.
virtual uint32 getExtraNotice() const =0
Returns the NoticeManager Code for extra variables changing.
virtual T * create()=0
Creates a new T with default values.
virtual T * findNear(const DVect &pos, const double &rad=limits< double >::max())=0
Returns the object whose position is closest to /a pos.
virtual uint32 getSelectNotice() const =0
Returns the NoticeManager Code for select status changing.
virtual const T * getFirst() const =0
Returns a const pointer to the first T in the list. Use T::getNext() to iterate through the entire li...
virtual const T * lookupWithID(uint64 ul) const =0
Find a const pointer to the T object with ID ul, or 0 if no match is found.
virtual QString getLabel() const =0
Returns a lable indicating the type of object it contains.
debug checked shorthand for std::numeric_limits<T>::
Definition limit.h:25
uint32 TType
class type indicator
Definition basedef.h:46
DVect3 DVect
Vector of doubles, either 2D or 3D.
Definition dim.h:154
Interface to a filter, used as the main method for filtering objects.
namespace Itasca
Definition basememory.cpp:10
Itasca Library standard namespace, specific to 2D or 3D.
Definition icontactmodule.h:4