Implement more NSCoder methods
authorandersca@apple.com <andersca@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 5 Nov 2013 20:56:57 +0000 (20:56 +0000)
committerandersca@apple.com <andersca@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 5 Nov 2013 20:56:57 +0000 (20:56 +0000)
commitea205947012afa7440a8eb53f6fb5621e55eab4d
treee8e141f85b667789169e9aa23b8437b21a0885b5
parent1c62aba42815a4ad415ad3420e3f93ec60543e8f
Implement more NSCoder methods
https://bugs.webkit.org/show_bug.cgi?id=123815

Reviewed by Dan Bernstein.

Source/WebKit2:

* Shared/API/Cocoa/WKRemoteObjectCoder.mm:
(encodeObject):
Assert that object is not nil.

(createEncodedObject):
Handle nil objects.

(-[WKRemoteObjectEncoder encodeValueOfObjCType:at:]):
Call the right object stream encoding function based on the object type.

(-[WKRemoteObjectEncoder encodeBool:forKey:]):
(-[WKRemoteObjectEncoder encodeInt64:forKey:]):
(-[WKRemoteObjectEncoder encodeDouble:forKey:]):
Create APIObjects and add them to the current dictionary.

Tools:

Add a method that takes an NSArray, an NSDictionary and an NSURLRequest.

* TestWebKitAPI/Tests/WebKit2ObjC/WKRemoteObjectRegistry.mm:
(TestWebKitAPI::TEST):
* TestWebKitAPI/Tests/mac/WKRemoteObjectRegistry_Bundle.mm:
(-[BundleObject testMethodWithArray:dictionary:request:]):
* TestWebKitAPI/Tests/mac/WKRemoteObjectRegistry_Shared.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@158685 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/WebKit2/ChangeLog
Source/WebKit2/Shared/API/Cocoa/WKRemoteObjectCoder.mm
Tools/ChangeLog
Tools/TestWebKitAPI/Tests/WebKit2ObjC/WKRemoteObjectRegistry.mm
Tools/TestWebKitAPI/Tests/mac/WKRemoteObjectRegistry_Bundle.mm
Tools/TestWebKitAPI/Tests/mac/WKRemoteObjectRegistry_Shared.h