Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(383)

Side by Side Diff: public/platform/WebBlobRegistry.h

Issue 23703003: Couple of minor changes to the WebKitAPI. This is a small step in a larger work-in-progress. See th… (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 7 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « public/platform/WebBlobData.h ('k') | public/platform/WebFileWriter.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2010 Google Inc. All rights reserved. 2 * Copyright (C) 2010 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 24 matching lines...) Expand all
35 35
36 namespace WebKit { 36 namespace WebKit {
37 37
38 class WebBlobData; 38 class WebBlobData;
39 class WebString; 39 class WebString;
40 class WebThreadSafeData; 40 class WebThreadSafeData;
41 class WebURL; 41 class WebURL;
42 42
43 class WebBlobRegistry { 43 class WebBlobRegistry {
44 public: 44 public:
45 WEBKIT_EXPORT static WebBlobRegistry* create();
46
47 virtual ~WebBlobRegistry() { } 45 virtual ~WebBlobRegistry() { }
48 46
49 // Registers a blob URL referring to the specified blob data. 47 virtual void registerBlobData(const WebKit::WebString& uuid, const WebKit::W ebBlobData&) { }
50 virtual void registerBlobURL(const WebURL&, WebBlobData&) = 0; 48 virtual void addBlobDataRef(const WebKit::WebString& uuid) { }
49 virtual void removeBlobDataRef(const WebKit::WebString& uuid) { }
50 virtual void registerPublicBlobURL(const WebKit::WebURL&, const WebKit::WebS tring& uuid) { }
51 virtual void revokePublicBlobURL(const WebKit::WebURL&) { }
51 52
52 // Registers a blob URL referring to the blob data identified by the 53 // DEPRECATED - old style blob handling is being replaced
53 // specified srcURL. 54 virtual void registerBlobURL(const WebURL&, WebBlobData&) { }
54 virtual void registerBlobURL(const WebURL&, const WebURL& srcURL) = 0; 55 virtual void registerBlobURL(const WebURL&, const WebURL& srcURL) { }
55 56 virtual void unregisterBlobURL(const WebURL&) { }
56 // Unregisters a blob referred by the URL.
57 virtual void unregisterBlobURL(const WebURL&) = 0;
58 57
59 // Registers a stream URL referring to a stream with the specified media 58 // Registers a stream URL referring to a stream with the specified media
60 // type. 59 // type.
61 virtual void registerStreamURL(const WebURL&, const WebString&) { WEBKIT_ASS ERT_NOT_REACHED(); } 60 virtual void registerStreamURL(const WebURL&, const WebString&) { WEBKIT_ASS ERT_NOT_REACHED(); }
62 61
63 // Registers a stream URL referring to the stream identified by the 62 // Registers a stream URL referring to the stream identified by the
64 // specified srcURL. 63 // specified srcURL.
65 virtual void registerStreamURL(const WebURL&, const WebURL& srcURL) { WEBKIT _ASSERT_NOT_REACHED(); }; 64 virtual void registerStreamURL(const WebURL&, const WebURL& srcURL) { WEBKIT _ASSERT_NOT_REACHED(); };
66 65
67 // Add data to the stream referred by the URL. 66 // Add data to the stream referred by the URL.
68 virtual void addDataToStream(const WebURL&, WebThreadSafeData&) { WEBKIT_ASS ERT_NOT_REACHED(); } 67 virtual void addDataToStream(const WebURL&, WebThreadSafeData&) { WEBKIT_ASS ERT_NOT_REACHED(); }
69 68
70 // Tell the registry that this stream won't receive any more data. 69 // Tell the registry that this stream won't receive any more data.
71 virtual void finalizeStream(const WebURL&) { WEBKIT_ASSERT_NOT_REACHED(); } 70 virtual void finalizeStream(const WebURL&) { WEBKIT_ASSERT_NOT_REACHED(); }
72 71
73 // Unregisters a stream referred by the URL. 72 // Unregisters a stream referred by the URL.
74 virtual void unregisterStreamURL(const WebURL&) { WEBKIT_ASSERT_NOT_REACHED( ); } 73 virtual void unregisterStreamURL(const WebURL&) { WEBKIT_ASSERT_NOT_REACHED( ); }
75 }; 74 };
76 75
77 } // namespace WebKit 76 } // namespace WebKit
78 77
79 #endif // WebBlobRegistry_h 78 #endif // WebBlobRegistry_h
OLDNEW
« no previous file with comments | « public/platform/WebBlobData.h ('k') | public/platform/WebFileWriter.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698