46 ASSERT_LOG(database,
"Database cannot be null.");
47 ASSERT_LOG(target_user,
"Target user must be non null.");
48 ASSERT_LOG(target_user->id(),
"Target user must be already persisted.");
49 ASSERT_LOG(parent,
"Parent must be non null.");
50 ASSERT_LOG(parent->id(),
"Parent must be already persisted.");
53 ASSERT_LOG(parent_odb,
"Parent object was not an instance of AuditEntry");
62 ASSERT_LOG(database,
"Database cannot be null.");
63 ASSERT_LOG(target_group,
"Target group must be non null.");
64 ASSERT_LOG(target_group->id(),
"Target group must be already persisted.");
65 ASSERT_LOG(parent,
"Parent must be non null.");
66 ASSERT_LOG(parent->id(),
"Parent must be already persisted.");
69 ASSERT_LOG(parent_odb,
"Parent object was not an instance of AuditEntry");
76 ASSERT_LOG(database,
"Database cannot be null.");
85 ASSERT_LOG(database,
"Database cannot be null.");
86 ASSERT_LOG(target_group,
"Group shall not be null.");
87 ASSERT_LOG(target_group->id(),
"Group must be already persisted.");
88 ASSERT_LOG(target_user,
"User shall not be null.");
89 ASSERT_LOG(target_user->id(),
"User must be already persisted.");
92 ASSERT_LOG(parent_odb,
"Parent object was not an instance of AuditEntry");
95 target_user, parent_odb);
102 ASSERT_LOG(database,
"Database cannot be null.");
103 ASSERT_LOG(target_cred,
"Credential shall not be null.");
104 ASSERT_LOG(target_cred->id(),
"Credential must be already persisted.");
107 ASSERT_LOG(parent_odb,
"Parent object was not an instance of AuditEntry");
116 ASSERT_LOG(database,
"Database cannot be null.");
117 ASSERT_LOG(target_sched,
"Schedule shall not be null.");
118 ASSERT_LOG(target_sched->id(),
"Schedule must be already persisted.");
127 ASSERT_LOG(database,
"Database cannot be null.");
128 ASSERT_LOG(target_door,
"Target door must be non null.");
129 ASSERT_LOG(target_door->id(),
"Target door must be already persisted.");
130 ASSERT_LOG(parent,
"Parent must be non null.");
131 ASSERT_LOG(parent->id(),
"Parent must be already persisted.");
134 ASSERT_LOG(parent_odb,
"Parent object was not an instance of AuditEntry");
143 ASSERT_LOG(database,
"Database cannot be null.");
144 ASSERT_LOG(target_ap,
"Target AccessPoint must be non null.");
145 ASSERT_LOG(target_ap->id(),
"Target AccessPoint must be already persisted.");
146 ASSERT_LOG(parent,
"Parent must be non null.");
147 ASSERT_LOG(parent->id(),
"Parent must be already persisted.");
150 ASSERT_LOG(parent_odb,
"Parent object was not an instance of AuditEntry");
159 ASSERT_LOG(database,
"Database cannot be null.");
160 ASSERT_LOG(target_update,
"Target AccessPoint must be non null.");
161 ASSERT_LOG(target_update->id(),
"Target AccessPoint must be already persisted.");
162 ASSERT_LOG(parent,
"Parent must be non null.");
163 ASSERT_LOG(parent->id(),
"Parent must be already persisted.");
166 ASSERT_LOG(parent_odb,
"Parent object was not an instance of AuditEntry");
174 ASSERT_LOG(database,
"Database cannot be null.");
175 ASSERT_LOG(target_zone,
"Target zone must be non null.");
176 ASSERT_LOG(target_zone->id(),
"Target zone must be already persisted.");
177 ASSERT_LOG(parent,
"Parent must be non null.");
178 ASSERT_LOG(parent->id(),
"Parent must be already persisted.");
181 ASSERT_LOG(parent_odb,
"Parent object was not an instance of AuditEntry");
static IUserEventPtr UserEvent(const DBPtr &database, Auth::UserPtr target_user, IAuditEntryPtr parent)
static IUserGroupMembershipEventPtr UserGroupMembershipEvent(const DBPtr &database, Auth::GroupPtr target_group, Auth::UserPtr target_user, IAuditEntryPtr parent)
static std::shared_ptr< DoorEvent > create(const DBPtr &database, Auth::IDoorPtr target_door, AuditEntryPtr parent)
Implementation of IAuditEntry, backed by ODB.
std::shared_ptr< IZone > IZonePtr
static UserGroupMembershipEventPtr create(const DBPtr &database, Auth::GroupPtr target_group, Auth::UserPtr target_user, AuditEntryPtr parent)
This is the header file for a generated source file, GitSHA1.cpp.
static std::shared_ptr< GroupEvent > create(const DBPtr &database, Auth::GroupPtr target_group, AuditEntryPtr parent)
static IAccessPointEventPtr AccessPointEvent(const DBPtr &database, Auth::IAccessPointPtr target_ap, IAuditEntryPtr parent)
std::shared_ptr< IWSAPICall > IWSAPICallPtr
static IScheduleEventPtr ScheduleEvent(const DBPtr &database, Tools::ISchedulePtr target_sched, IAuditEntryPtr parent)
static ICredentialEventPtr CredentialEventPtr(const DBPtr &database, Cred::ICredentialPtr target_cred, IAuditEntryPtr parent)
std::shared_ptr< IAuditEntry > IAuditEntryPtr
std::shared_ptr< IGroupEvent > IGroupEventPtr
std::shared_ptr< IDoor > IDoorPtr
std::shared_ptr< IAccessPoint > IAccessPointPtr
std::shared_ptr< ICredential > ICredentialPtr
std::shared_ptr< IZoneEvent > IZoneEventPtr
std::shared_ptr< IUpdate > IUpdatePtr
std::shared_ptr< Group > GroupPtr
static WSAPICallPtr create(const DBPtr &database)
std::shared_ptr< IScheduleEvent > IScheduleEventPtr
static std::shared_ptr< AccessPointEvent > create(const DBPtr &database, Auth::IAccessPointPtr target_ap, AuditEntryPtr parent)
static std::shared_ptr< CredentialEvent > create(const DBPtr &database, Cred::ICredentialPtr target_cred, AuditEntryPtr parent)
static IGroupEventPtr GroupEvent(const DBPtr &database, Auth::GroupPtr target_group, IAuditEntryPtr parent)
std::shared_ptr< IUserEvent > IUserEventPtr
std::shared_ptr< AuditEntry > AuditEntryPtr
std::shared_ptr< User > UserPtr
std::shared_ptr< ICredentialEvent > ICredentialEventPtr
std::shared_ptr< IAccessPointEvent > IAccessPointEventPtr
#define ASSERT_LOG(cond, msg)
std::shared_ptr< IUserGroupMembershipEvent > IUserGroupMembershipEventPtr
static std::shared_ptr< ZoneEvent > create(const DBPtr &database, Auth::IZonePtr target_zone, AuditEntryPtr parent)
static std::shared_ptr< ScheduleEvent > create(const DBPtr &database, Tools::ISchedulePtr target_sched, AuditEntryPtr parent)
static IUpdateEventPtr UpdateEvent(const DBPtr &database, update::IUpdatePtr target_update, IAuditEntryPtr parent)
static std::shared_ptr< UserEvent > create(const DBPtr &database, Auth::UserPtr target_user, AuditEntryPtr parent)
std::shared_ptr< IDoorEvent > IDoorEventPtr
std::shared_ptr< IUpdateEvent > IUpdateEventPtr
static std::shared_ptr< UpdateEvent > create(const DBPtr &database, update::IUpdatePtr target_update, AuditEntryPtr parent)
std::shared_ptr< odb::database > DBPtr
static IDoorEventPtr DoorEvent(const DBPtr &database, Auth::IDoorPtr target_door, IAuditEntryPtr parent)
std::enable_if_t< is_shared_ptr_v< Out >, Out > assert_cast(const std::shared_ptr< In > &in)
static IWSAPICallPtr WSAPICall(const DBPtr &database)
static IZoneEventPtr ZoneEvent(const DBPtr &database, Auth::IZonePtr target_zone, IAuditEntryPtr parent)
The Audit namespace provides classes and facilities to keep track of what's happening on the Leosac d...