Matter SDK Coverage Report
Current view: top level - access/examples - GroupAuxiliaryAccessControlDelegate.h (source / functions) Coverage Total Hit
Test: SHA:3f9cd168e84cd831b7699126f5296f5c5498690f Lines: 100.0 % 4 4
Test Date: 2026-04-27 19:52:19 Functions: 66.7 % 3 2

            Line data    Source code
       1              : /*
       2              :  *
       3              :  *    Copyright (c) 2026 Project CHIP Authors
       4              :  *    All rights reserved.
       5              :  *
       6              :  *    Licensed under the Apache License, Version 2.0 (the "License");
       7              :  *    you may not use this file except in compliance with the License.
       8              :  *    You may obtain a copy of the License at
       9              :  *
      10              :  *        http://www.apache.org/licenses/LICENSE-2.0
      11              :  *
      12              :  *    Unless required by applicable law or agreed to in writing, software
      13              :  *    distributed under the License is distributed on an "AS IS" BASIS,
      14              :  *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
      15              :  *    See the License for the specific language governing permissions and
      16              :  *    limitations under the License.
      17              :  */
      18              : 
      19              : #pragma once
      20              : 
      21              : #include "access/AccessControl.h"
      22              : #include <credentials/GroupDataProvider.h>
      23              : #include <lib/core/CHIPPersistentStorageDelegate.h>
      24              : #include <lib/core/DataModelTypes.h>
      25              : 
      26              : namespace chip {
      27              : 
      28              : class FabricTable;
      29              : 
      30              : namespace Access {
      31              : namespace Examples {
      32              : 
      33              : class GroupAuxiliaryAccessControlDelegate : public AccessControl::Delegate
      34              : {
      35              : public:
      36            3 :     GroupAuxiliaryAccessControlDelegate(Credentials::GroupDataProvider * groupDataProvider, FabricTable * fabricTable = nullptr) :
      37            3 :         mGroupDataProvider(groupDataProvider), mFabricTable(fabricTable)
      38            3 :     {}
      39            3 :     ~GroupAuxiliaryAccessControlDelegate() override = default;
      40              : 
      41              :     // Delegate implementation
      42              :     CHIP_ERROR AuxiliaryEntries(AccessControl::EntryIterator & iterator, const FabricIndex * fabricIndex) const override;
      43              : 
      44              :     CHIP_ERROR Check(const SubjectDescriptor & subjectDescriptor, const RequestPath & requestPath,
      45              :                      Privilege requestPrivilege) override;
      46              : 
      47              : private:
      48              :     Credentials::GroupDataProvider * mGroupDataProvider;
      49              :     FabricTable * mFabricTable;
      50              : };
      51              : 
      52              : } // namespace Examples
      53              : } // namespace Access
      54              : } // namespace chip
        

Generated by: LCOV version 2.0-1