void FileReaderWriterBase::SetOption(const std::string& name, const us::Any& value)
{
  if (m_DefaultOptions.find(name) == m_DefaultOptions.end())
  {
    MITK_WARN << "Ignoring unknown IFileReader option '" << name << "'";
  }
  else
  {
    if (value.Empty())
    {
      // an empty Any signals 'reset to default value'
      m_Options.erase(name);
    }
    else
    {
      m_Options[name] = value;
    }
  }
}
QmitkInvalidAnyWidget::QmitkInvalidAnyWidget(const std::string& name, const us::Any& any, QWidget* parent)
  : QLabel(parent)
  , QmitkAnyAdapter(name)
{
  this->setText(QString("Unknown option type '%1'").arg(any.Type().name()));
}
QmitkAnyStringWidget::QmitkAnyStringWidget(const std::string& name, const us::Any& any, QWidget* parent)
  : QLineEdit(parent)
  , QmitkAnyAdapter(name)
{
  this->setText(QString::fromStdString(any.ToString()));
}
Beispiel #4
0
LDAPPropExpr LDAPProp::operator<=(const us::Any& any) const
{
  return operator<=(any.ToString());
}
Beispiel #5
0
LDAPPropExpr LDAPProp::Approx(const us::Any& any) const
{
  return Approx(any.ToString());
}