BornAgain  1.19.0
Simulate and fit neutron and x-ray scattering at grazing incidence
ModelView::UniqueIdGenerator Class Reference

Provides generation of unique SessionItem itentifier. More...

Static Public Member Functions

static identifier_type generate ()
 

Detailed Description

Provides generation of unique SessionItem itentifier.

In the future might be turned to singleton to keep track of all generated identifier and make sure, that SessionItem identifiers loaded from disk, are different from those generated during dynamic session. For the moment though, we rely on zero-probability of such event.

Definition at line 33 of file uniqueidgenerator.h.

Member Function Documentation

◆ generate()

identifier_type UniqueIdGenerator::generate ( )
static

Definition at line 20 of file uniqueidgenerator.cpp.

21 {
22  return QUuid::createUuid().toString().toStdString();
23 }
QString createUuid()
Definition: GUIHelpers.cpp:242

References GUIHelpers::createUuid().

Referenced by ModelView::SessionItem::SessionItem(), ModelView::JsonItemConverter::JsonItemConverterImpl::populate_item(), and ModelView::ItemPool::register_item().

Here is the call graph for this function:

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