pgLab/pglablib/PgIndex.cpp
eelke fcb191f2cc Overview of triggers extended with function name and arguments.
Did a lot of refactoring on the catalog to keep things clean.
2018-11-18 19:30:45 +01:00

22 lines
411 B
C++

#include "PgIndex.h"
#include "PgDatabaseCatalog.h"
#include "PgClassContainer.h"
#include "PgAmContainer.h"
QString PgIndex::getAm() const
{
auto&& cat = catalog();
QString result;
auto idxcls = cat.classes()->getByKey(indexrelid);
if (idxcls) {
auto am = cat.ams()->getByKey(idxcls->am);
if (am)
result = am->name;
}
return result;
}
QString PgIndex::objectName() const
{
return getAm();
}