dict_util.h 744 B

123456789101112131415161718192021222324252627282930
  1. // Copyright (c) 2016 GitHub, Inc.
  2. // Use of this source code is governed by the MIT license that can be
  3. // found in the LICENSE file.
  4. #ifndef SHELL_BROWSER_MAC_DICT_UTIL_H_
  5. #define SHELL_BROWSER_MAC_DICT_UTIL_H_
  6. #include <memory>
  7. #import <Foundation/Foundation.h>
  8. namespace base {
  9. class ListValue;
  10. class DictionaryValue;
  11. } // namespace base
  12. namespace electron {
  13. NSArray* ListValueToNSArray(const base::ListValue& value);
  14. std::unique_ptr<base::ListValue> NSArrayToListValue(NSArray* arr);
  15. NSDictionary* DictionaryValueToNSDictionary(const base::DictionaryValue& value);
  16. std::unique_ptr<base::DictionaryValue> NSDictionaryToDictionaryValue(
  17. NSDictionary* dict);
  18. } // namespace electron
  19. #endif // SHELL_BROWSER_MAC_DICT_UTIL_H_