ImagingTools Core SDK
CUserCollectionAdapterComp.h
1// SPDX-License-Identifier: LGPL-2.1-or-later OR GPL-2.0-or-later OR GPL-3.0-or-later OR LicenseRef-ImtCore-Commercial
2#pragma once
3
4
5// ACF includes
6#include <icomp/CComponentBase.h>
7
8// ImtCore includes
9#include <imtbase/IObjectCollection.h>
10#include <imtauth/IUserInfoProvider.h>
11
12
13namespace imtauth
14{
15
16
17class CUserCollectionAdapterComp: public icomp::CComponentBase, virtual public IUserInfoProvider
18{
19public:
20 typedef icomp::CComponentBase BaseClass;
21
22 I_BEGIN_COMPONENT(CUserCollectionAdapterComp);
23 I_REGISTER_INTERFACE(IUserInfoProvider);
24 I_ASSIGN(m_userCollectionCompPtr, "UserCollection", "Undelaying user collection", true, "UserCollection");
25 I_END_COMPONENT;
26
27 // reimplemented (IUserInfoProvider)
28 virtual const imtbase::ICollectionInfo& GetUserList() const override;
29 virtual imtauth::IUserInfoUniquePtr GetUser(const QByteArray& objectId, const iprm::IParamsSet* paramsPtr = nullptr) const override;
30
31protected:
32 I_REF(imtbase::IObjectCollection, m_userCollectionCompPtr);
33};
34
35
36} // namespace imtauth
37
38