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

#include <SchemaCommand.hpp>

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

Public Member Functions

 SetMethodImplementationPrototype (dunedaq::oks::OksClass *Class, dunedaq::oks::OksMethod *Method, dunedaq::oks::OksMethodImplementation *Implementation, std::string Prototype)
 ~SetMethodImplementationPrototype ()
void redo ()
void undo ()

Private Attributes

std::string ClassName
std::string MethodName
dunedaq::oks::OksMethodImplementationSchemaImplementation
std::string ImplementationLanguage
std::string NewPrototype
std::string OldPrototype

Detailed Description

Definition at line 296 of file SchemaCommand.hpp.

Constructor & Destructor Documentation

◆ SetMethodImplementationPrototype()

dbse::SetMethodImplementationPrototype::SetMethodImplementationPrototype ( dunedaq::oks::OksClass * Class,
dunedaq::oks::OksMethod * Method,
dunedaq::oks::OksMethodImplementation * Implementation,
std::string Prototype )

Definition at line 543 of file SchemaCommand.cpp.

545 : ClassName(Class->get_name()),
546 MethodName ( Method->get_name() ),
547 SchemaImplementation ( Implementation ),
548 ImplementationLanguage ( Implementation->get_language()),
549 NewPrototype ( Prototype ),
550 OldPrototype ( SchemaImplementation->get_prototype() )
551{
552 setText( QString::fromStdString("Changed prototype for method \"" + SchemaImplementation->get_prototype() + "\" of class \"" + ClassName + "\""));
553}
dunedaq::oks::OksMethodImplementation * SchemaImplementation
const std::string & get_name() const noexcept
Definition class.hpp:368
const std::string & get_language() const noexcept
Definition method.hpp:68
const std::string & get_name() const noexcept
Definition method.hpp:201

◆ ~SetMethodImplementationPrototype()

dbse::SetMethodImplementationPrototype::~SetMethodImplementationPrototype ( )

Definition at line 555 of file SchemaCommand.cpp.

556{
557}

Member Function Documentation

◆ redo()

void dbse::SetMethodImplementationPrototype::redo ( )

Definition at line 559 of file SchemaCommand.cpp.

560{
562 if(mi != nullptr) {
564 }
565
566 SchemaImplementation->set_prototype ( NewPrototype );
567 emit KernelWrapper::GetInstance().ClassUpdated ( QString::fromStdString(ClassName) );
568}
static KernelWrapper & GetInstance()
dunedaq::oks::OksClass * FindClass(std::string ClassName) const
void ClassUpdated(QString ClassName)
OksMethod * find_direct_method(const std::string &name) const noexcept
Find direct method.
Definition class.cpp:1335
OksMethodImplementation * find_implementation(const std::string &language) const
Find method implementation.
Definition method.cpp:359

◆ undo()

void dbse::SetMethodImplementationPrototype::undo ( )

Definition at line 570 of file SchemaCommand.cpp.

571{
572 SchemaImplementation->set_prototype ( OldPrototype );
573 emit KernelWrapper::GetInstance().ClassUpdated ( QString::fromStdString(ClassName) );
574}

Member Data Documentation

◆ ClassName

std::string dbse::SetMethodImplementationPrototype::ClassName
private

Definition at line 307 of file SchemaCommand.hpp.

◆ ImplementationLanguage

std::string dbse::SetMethodImplementationPrototype::ImplementationLanguage
private

Definition at line 310 of file SchemaCommand.hpp.

◆ MethodName

std::string dbse::SetMethodImplementationPrototype::MethodName
private

Definition at line 308 of file SchemaCommand.hpp.

◆ NewPrototype

std::string dbse::SetMethodImplementationPrototype::NewPrototype
private

Definition at line 311 of file SchemaCommand.hpp.

◆ OldPrototype

std::string dbse::SetMethodImplementationPrototype::OldPrototype
private

Definition at line 312 of file SchemaCommand.hpp.

◆ SchemaImplementation

dunedaq::oks::OksMethodImplementation* dbse::SetMethodImplementationPrototype::SchemaImplementation
private

Definition at line 309 of file SchemaCommand.hpp.


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