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

#include <SchemaCommand.hpp>

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

Public Member Functions

 SetIsExclusiveRelationshipCommand (dunedaq::oks::OksClass *Class, dunedaq::oks::OksRelationship *Relationship, bool Value)
 ~SetIsExclusiveRelationshipCommand ()
void redo ()
void undo ()

Private Attributes

std::string ClassName
dunedaq::oks::OksRelationship * SchemaRelationship
std::string RelationshipName
bool NewValue
bool OldValue

Detailed Description

Definition at line 235 of file SchemaCommand.hpp.

Constructor & Destructor Documentation

◆ SetIsExclusiveRelationshipCommand()

dbse::SetIsExclusiveRelationshipCommand::SetIsExclusiveRelationshipCommand ( dunedaq::oks::OksClass * Class,
dunedaq::oks::OksRelationship * Relationship,
bool Value )

Definition at line 404 of file SchemaCommand.cpp.

407 : ClassName(Class->get_name())
408 , SchemaRelationship(Relationship)
409 , RelationshipName(Relationship->get_name())
410 , NewValue(Value)
412{
413 setText(QString::fromStdString("Changed the \"is exclusive\" constraint for relationship \"" +
414 Relationship->get_name() + "\" of class \"" + ClassName + "\""));
415}
dunedaq::oks::OksRelationship * SchemaRelationship
const std::string & get_name() const noexcept
Definition class.hpp:374
bool get_is_exclusive() const noexcept
const std::string & get_name() const noexcept

◆ ~SetIsExclusiveRelationshipCommand()

dbse::SetIsExclusiveRelationshipCommand::~SetIsExclusiveRelationshipCommand ( )

Definition at line 417 of file SchemaCommand.cpp.

417{}

Member Function Documentation

◆ redo()

void dbse::SetIsExclusiveRelationshipCommand::redo ( )

Definition at line 420 of file SchemaCommand.cpp.

421{
423 if (r != nullptr) {
425 }
426
428 emit KernelWrapper::GetInstance().ClassUpdated(QString::fromStdString(ClassName));
429}
static KernelWrapper & GetInstance()
dunedaq::oks::OksClass * FindClass(std::string ClassName) const
void ClassUpdated(QString ClassName)
OksRelationship * find_direct_relationship(const std::string &name) const noexcept
Find direct relationship.
Definition class.cpp:1130
void set_is_exclusive(bool exclusive)
Set the composite relationship exclusive property.

◆ undo()

void dbse::SetIsExclusiveRelationshipCommand::undo ( )

Definition at line 432 of file SchemaCommand.cpp.

433{
435 emit KernelWrapper::GetInstance().ClassUpdated(QString::fromStdString(ClassName));
436}

Member Data Documentation

◆ ClassName

std::string dbse::SetIsExclusiveRelationshipCommand::ClassName
private

Definition at line 246 of file SchemaCommand.hpp.

◆ NewValue

bool dbse::SetIsExclusiveRelationshipCommand::NewValue
private

Definition at line 249 of file SchemaCommand.hpp.

◆ OldValue

bool dbse::SetIsExclusiveRelationshipCommand::OldValue
private

Definition at line 250 of file SchemaCommand.hpp.

◆ RelationshipName

std::string dbse::SetIsExclusiveRelationshipCommand::RelationshipName
private

Definition at line 248 of file SchemaCommand.hpp.

◆ SchemaRelationship

dunedaq::oks::OksRelationship* dbse::SetIsExclusiveRelationshipCommand::SchemaRelationship
private

Definition at line 247 of file SchemaCommand.hpp.


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