1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef IOS_WEB_NAVIGATION_NSCODER_UTIL_H_
6 #define IOS_WEB_NAVIGATION_NSCODER_UTIL_H_
8 #import <Foundation/Foundation.h>
13 namespace nscoder_util
{
15 // Archives a std::string in an Objective-C key archiver.
16 void EncodeString(NSCoder
* coder
, NSString
* key
, const std::string
& string
);
18 // Decode a std::string from an Objective-C key unarchiver.
19 std::string
DecodeString(NSCoder
* decoder
, NSString
* key
);
21 } // namespace nscoder_util
24 #endif // IOS_WEB_NAVIGATION_NSCODER_UTIL_H_