1 //===-- CFCMutableSet.h -----------------------------------------*- C++ -*-===// 2 // 3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. 4 // See https://llvm.org/LICENSE.txt for license information. 5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception 6 // 7 //===----------------------------------------------------------------------===// 8 9 #ifndef CoreFoundationCPP_CFMutableSet_h_ 10 #define CoreFoundationCPP_CFMutableSet_h_ 11 12 #include "CFCReleaser.h" 13 14 class CFCMutableSet : public CFCReleaser<CFMutableSetRef> { 15 public: 16 //------------------------------------------------------------------ 17 // Constructors and Destructors 18 //------------------------------------------------------------------ 19 CFCMutableSet(CFMutableSetRef s = NULL); 20 CFCMutableSet(const CFCMutableSet &rhs); 21 virtual ~CFCMutableSet(); 22 23 //------------------------------------------------------------------ 24 // Operators 25 //------------------------------------------------------------------ 26 const CFCMutableSet &operator=(const CFCMutableSet &rhs); 27 28 CFIndex GetCount() const; 29 CFIndex GetCountOfValue(const void *value) const; 30 const void *GetValue(const void *value) const; 31 const void *AddValue(const void *value, bool can_create); 32 void RemoveValue(const void *value); 33 void RemoveAllValues(); 34 35 protected: 36 //------------------------------------------------------------------ 37 // Classes that inherit from CFCMutableSet can see and modify these 38 //------------------------------------------------------------------ 39 40 private: 41 //------------------------------------------------------------------ 42 // For CFCMutableSet only 43 //------------------------------------------------------------------ 44 }; 45 46 #endif // CoreFoundationCPP_CFMutableSet_h_ 47