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

#include <SchemaCommand.hpp>

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

Public Member Functions

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

Private Attributes

std::string ClassName
dunedaq::oks::OksAttribute * SchemaAttribute
std::string AttributeName
bool NewAttributeIsNull
bool OldAttributeIsNull

Detailed Description

Definition at line 579 of file SchemaCommand.hpp.

Constructor & Destructor Documentation

◆ SetAttributeIsNullCommand()

dbse::SetAttributeIsNullCommand::SetAttributeIsNullCommand ( dunedaq::oks::OksClass * Class,
dunedaq::oks::OksAttribute * Attribute,
bool NewIsNull )

Definition at line 995 of file SchemaCommand.cpp.

996 : ClassName(Class->get_name())
997 , SchemaAttribute(Attribute)
998 , AttributeName(Attribute->get_name())
999 , NewAttributeIsNull(NewIsNull)
1001{
1002 setText(QString::fromStdString("Set null-ness for attribute \"" + Attribute->get_name() + "\" of class \"" +
1003 ClassName + "\""));
1004}
dunedaq::oks::OksAttribute * SchemaAttribute
const std::string & get_name() const noexcept
out stream operator
bool get_is_no_null() const noexcept
const std::string & get_name() const noexcept
Definition class.hpp:374

◆ ~SetAttributeIsNullCommand()

dbse::SetAttributeIsNullCommand::~SetAttributeIsNullCommand ( )

Definition at line 1006 of file SchemaCommand.cpp.

1006{}

Member Function Documentation

◆ redo()

void dbse::SetAttributeIsNullCommand::redo ( )

Definition at line 1009 of file SchemaCommand.cpp.

1010{
1012 if (a != nullptr) {
1013 SchemaAttribute = a;
1014 }
1015
1017 emit KernelWrapper::GetInstance().ClassUpdated(QString::fromStdString(ClassName));
1018}
static KernelWrapper & GetInstance()
dunedaq::oks::OksClass * FindClass(std::string ClassName) const
void ClassUpdated(QString ClassName)
void set_is_no_null(bool no_null)
Set attribute is-no-null property.
OksAttribute * find_direct_attribute(const std::string &name) const noexcept
Find direct attribute.
Definition class.cpp:973

◆ undo()

void dbse::SetAttributeIsNullCommand::undo ( )

Definition at line 1021 of file SchemaCommand.cpp.

1022{
1024 emit KernelWrapper::GetInstance().ClassUpdated(QString::fromStdString(ClassName));
1025}

Member Data Documentation

◆ AttributeName

std::string dbse::SetAttributeIsNullCommand::AttributeName
private

Definition at line 590 of file SchemaCommand.hpp.

◆ ClassName

std::string dbse::SetAttributeIsNullCommand::ClassName
private

Definition at line 588 of file SchemaCommand.hpp.

◆ NewAttributeIsNull

bool dbse::SetAttributeIsNullCommand::NewAttributeIsNull
private

Definition at line 591 of file SchemaCommand.hpp.

◆ OldAttributeIsNull

bool dbse::SetAttributeIsNullCommand::OldAttributeIsNull
private

Definition at line 592 of file SchemaCommand.hpp.

◆ SchemaAttribute

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

Definition at line 589 of file SchemaCommand.hpp.


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