Rework of catalog objects. Several of them are now inheriting from common
base classes that implement common functionality.
This commit is contained in:
parent
840af1e0a9
commit
73c4cf4790
45 changed files with 340 additions and 265 deletions
25
pglablib/PgOwnedObject.cpp
Normal file
25
pglablib/PgOwnedObject.cpp
Normal file
|
|
@ -0,0 +1,25 @@
|
|||
#include "PgOwnedObject.h"
|
||||
#include "PgAuthId.h"
|
||||
#include "PgAuthIdContainer.h"
|
||||
#include "PgDatabaseCatalog.h"
|
||||
|
||||
void PgOwnedObject::setOwnerOid(PgDatabaseCatalog& cat, Oid oid)
|
||||
{
|
||||
m_ownerOid = oid;
|
||||
m_owner = cat.authIds()->getByKey(oid);
|
||||
}
|
||||
|
||||
Oid PgOwnedObject::ownerOid() const
|
||||
{
|
||||
return m_ownerOid;
|
||||
}
|
||||
|
||||
QString PgOwnedObject::ownerName() const
|
||||
{
|
||||
return m_owner->name;
|
||||
}
|
||||
|
||||
const PgAuthId* PgOwnedObject::owner() const
|
||||
{
|
||||
return m_owner;
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue