27 #include "../../../dataaccess/dataset/DataSetType.h" 28 #include "../../../dataaccess/dataset/UniqueKey.h" 29 #include "../utils/DoubleListWidget.h" 31 #include "ui_ConstraintWidgetForm.h" 32 #include "ui_DoubleListWidgetForm.h" 50 if(
m_ui->m_nameLineEdit->text().isEmpty())
55 std::string constraintName =
m_ui->m_nameLineEdit->text().toUtf8().data();
70 for(
size_t t = 0; t < vec.size(); ++t)
90 m_ui->m_nameLineEdit->setText(uk->
getName().c_str());
93 std::vector<std::string> ukPropsStr;
94 for(std::size_t i = 0; i < ukProps.size(); ++i)
96 ukPropsStr.push_back(ukProps[i]->getName());
100 std::vector<std::string> dtPropsStr;
101 for(std::size_t i = 0; i < dtProps.size(); ++i)
103 std::string propStr = dtProps[i]->getName();
105 if(std::find(ukPropsStr.begin(), ukPropsStr.end(), propStr) != ukPropsStr.end())
108 dtPropsStr.push_back(propStr);
virtual void setName(const std::string &name)
It sets the constraint name.
Property * getProperty(std::size_t i) const
It returns the i-th property.
void add(te::dt::Property *p)
It adds the property to the list of properties that participates in the unique key.
A class that models the description of a dataset.
virtual Property * clone() const =0
It returns a clone of the object.
It models a property definition.
const std::vector< Property * > & getProperties() const
It returns the list of properties describing the CompositeProperty.
It describes a unique key (uk) constraint.
const std::vector< te::dt::Property * > & getProperties() const
It returns the properties that form the unique key.
virtual const std::string & getName() const
It returns the constraint name.