DUNE-DAQ
DUNE Trigger and Data Acquisition software
Loading...
Searching...
No Matches
dbse::SetAttributeMultiCommand Class Reference

#include <SchemaCommand.hpp>

Inheritance diagram for dbse::SetAttributeMultiCommand:
[legend]
Collaboration diagram for dbse::SetAttributeMultiCommand:
[legend]

Public Member Functions

 SetAttributeMultiCommand (dunedaq::oks::OksClass *Class, dunedaq::oks::OksAttribute *Attribute, bool NewIsMulti)
 ~SetAttributeMultiCommand ()
void redo ()
void undo ()

Private Attributes

std::string ClassName
dunedaq::oks::OksAttribute * SchemaAttribute
std::string AttributeName
bool NewAttributeMulti
bool OldAttributeMulti

Detailed Description

Definition at line 563 of file SchemaCommand.hpp.

Constructor & Destructor Documentation

◆ SetAttributeMultiCommand()

dbse::SetAttributeMultiCommand::SetAttributeMultiCommand ( dunedaq::oks::OksClass * Class,
dunedaq::oks::OksAttribute * Attribute,
bool NewIsMulti )

Definition at line 963 of file SchemaCommand.cpp.

964 : ClassName(Class->get_name())
965 , SchemaAttribute(Attribute)
966 , AttributeName(Attribute->get_name())
967 , NewAttributeMulti(NewIsMulti)
969{
970 setText(QString::fromStdString("Set multiplicity for attribute \"" + Attribute->get_name() + "\" of class \"" +
971 ClassName + "\""));
972}
dunedaq::oks::OksAttribute * SchemaAttribute
bool get_is_multi_values() const noexcept
const std::string & get_name() const noexcept
out stream operator
const std::string & get_name() const noexcept
Definition class.hpp:374

◆ ~SetAttributeMultiCommand()

dbse::SetAttributeMultiCommand::~SetAttributeMultiCommand ( )

Definition at line 974 of file SchemaCommand.cpp.

974{}

Member Function Documentation

◆ redo()

void dbse::SetAttributeMultiCommand::redo ( )

Definition at line 977 of file SchemaCommand.cpp.

978{
980 if (a != nullptr) {
981 SchemaAttribute = a;
982 }
983
985 emit KernelWrapper::GetInstance().ClassUpdated(QString::fromStdString(ClassName));
986}
static KernelWrapper & GetInstance()
dunedaq::oks::OksClass * FindClass(std::string ClassName) const
void ClassUpdated(QString ClassName)
void set_is_multi_values(bool multi_values)
Set attribute is a single-value or multi-value.
OksAttribute * find_direct_attribute(const std::string &name) const noexcept
Find direct attribute.
Definition class.cpp:973

◆ undo()

void dbse::SetAttributeMultiCommand::undo ( )

Definition at line 989 of file SchemaCommand.cpp.

Member Data Documentation

◆ AttributeName

std::string dbse::SetAttributeMultiCommand::AttributeName
private

Definition at line 574 of file SchemaCommand.hpp.

◆ ClassName

std::string dbse::SetAttributeMultiCommand::ClassName
private

Definition at line 572 of file SchemaCommand.hpp.

◆ NewAttributeMulti

bool dbse::SetAttributeMultiCommand::NewAttributeMulti
private

Definition at line 575 of file SchemaCommand.hpp.

◆ OldAttributeMulti

bool dbse::SetAttributeMultiCommand::OldAttributeMulti
private

Definition at line 576 of file SchemaCommand.hpp.

◆ SchemaAttribute

dunedaq::oks::OksAttribute* dbse::SetAttributeMultiCommand::SchemaAttribute
private

Definition at line 573 of file SchemaCommand.hpp.


The documentation for this class was generated from the following files: