43 mTypeRegexp(typeRegexp),
44 mPatientModelService(patientModelService),
60 std::map<QString, DataPtr>::iterator iter, current;
62 for (iter=input.begin(); iter!=input.end(); )
65 if (!current->second->getType().contains(reg))
86 std::map<QString, DataPtr>::iterator iter, current;
87 for (iter=input.begin(); iter!=input.end(); )
90 if (!current->second->getUid().contains(reg))
102 std::map<QString, DataPtr>::iterator iter, current;
103 for (iter=input.begin(); iter!=input.end(); )
106 ImagePtr image = boost::dynamic_pointer_cast<
Image>(current->second);
107 if(image && !image->is2D())
108 input.erase(current);
135 for (
unsigned i=0; i<sorted.size(); ++i)
136 retval << sorted[i]->
getUid();
QString qstring_cast(const T &val)
void setOnly2DImagesFilter(bool only2D)
SelectDataStringPropertyBase(PatientModelServicePtr patientModelService, QString typeRegexp=".*")
std::map< QString, DataPtr > filterOnUid(std::map< QString, DataPtr > input, QString regexp) const
std::map< QString, DataPtr > filterImagesOn2D(std::map< QString, DataPtr > input, bool only2D) const
virtual void setTypeRegexp(QString regexp)
virtual QStringList getValueRange() const
virtual QString getDisplayName() const
name of data entity. Used for display to user.
boost::shared_ptr< class Image > ImagePtr
virtual void setValueName(const QString name)
static std::map< QString, DataPtr > filterOnType(std::map< QString, DataPtr > input, QString regexp)
boost::shared_ptr< class Data > DataPtr
std::vector< T > sortOnGroupsAndAcquisitionTime(std::map< QString, T > input)
boost::shared_ptr< class PatientModelService > PatientModelServicePtr
virtual QString getHelp() const
return a descriptive help string for the data, used for example as a tool tip.
void changed()
emit when the underlying data value is changed: The user interface will be updated.
virtual void setHelp(QString text)
virtual DataPtr getData() const
virtual QString getUid() const
virtual void setUidRegexp(QString regexp)
virtual QString convertInternal2Display(QString internal)
range of value. Use if data is constrained to a set.
virtual QString getValue() const =0
get the data value.
PatientModelServicePtr mPatientModelService
Namespace for all CustusX production code.