webkit
2cdf99a9e3038c7e01b3c37e8ad903ecbe5eecf1
https://github.com/WebKit/webkit
|
#import <WebDataSource.h>
Instance Methods | |
(instancetype) | - initWithRequest: |
(WebResource *) | - subresourceForURL: |
(void) | - addSubresource: |
(virtual HRESULT STDMETHODCALLTYPE) | - QueryInterface |
(virtual ULONG STDMETHODCALLTYPE) | - AddRef |
(virtual ULONG STDMETHODCALLTYPE) | - Release |
(virtual HRESULT STDMETHODCALLTYPE) | - initWithRequest |
(virtual HRESULT STDMETHODCALLTYPE) | - data |
(virtual HRESULT STDMETHODCALLTYPE) | - representation |
(virtual HRESULT STDMETHODCALLTYPE) | - webFrame |
(virtual HRESULT STDMETHODCALLTYPE) | - initialRequest |
(virtual HRESULT STDMETHODCALLTYPE) | - request |
(virtual HRESULT STDMETHODCALLTYPE) | - response |
(virtual HRESULT STDMETHODCALLTYPE) | - textEncodingName |
(virtual HRESULT STDMETHODCALLTYPE) | - isLoading |
(virtual HRESULT STDMETHODCALLTYPE) | - pageTitle |
(virtual HRESULT STDMETHODCALLTYPE) | - unreachableURL |
(virtual HRESULT STDMETHODCALLTYPE) | - webArchive |
(virtual HRESULT STDMETHODCALLTYPE) | - mainResource |
(virtual HRESULT STDMETHODCALLTYPE) | - subresources |
(virtual HRESULT STDMETHODCALLTYPE) | - subresourceForURL |
(virtual HRESULT STDMETHODCALLTYPE) | - addSubresource |
(virtual HRESULT STDMETHODCALLTYPE) | - overrideEncoding |
(virtual HRESULT STDMETHODCALLTYPE) | - setOverrideEncoding |
(virtual HRESULT STDMETHODCALLTYPE) | - mainDocumentError |
(virtual HRESULT STDMETHODCALLTYPE) | - setDeferMainResourceDataLoad |
(WebDocumentLoader *) | - documentLoader |
Instance Methods inherited from IWebDataSource | |
HRESULT | initWithRequest ([in] IWebURLRequest *request) |
HRESULT | data ([out, retval] IStream **stream) |
HRESULT | representation ([out, retval] IWebDocumentRepresentation **rep) |
HRESULT | webFrame ([out, retval] IWebFrame **frame) |
HRESULT | initialRequest ([out, retval] IWebURLRequest **request) |
HRESULT | request ([out, retval] IWebMutableURLRequest **request) |
HRESULT | response ([out, retval] IWebURLResponse **response) |
HRESULT | textEncodingName ([out, retval] BSTR *name) |
HRESULT | isLoading ([out, retval] BOOL *loading) |
HRESULT | pageTitle ([out, retval] BSTR *title) |
HRESULT | unreachableURL ([out, retval] BSTR *url) |
HRESULT | webArchive ([out, retval] IWebArchive **archive) |
HRESULT | mainResource ([out, retval] IWebResource **resource) |
HRESULT | subresources ([out, retval] IEnumVARIANT **enumResources) |
HRESULT | subresourceForURL ([in] BSTR url, [out, retval] IWebResource **resource) |
HRESULT | addSubresource ([in] IWebResource *subresource) |
Instance Methods inherited from IWebDataSourcePrivate | |
HRESULT | overrideEncoding ([out, retval] BSTR *encoding) |
HRESULT | setOverrideEncoding ([in] BSTR encoding) |
HRESULT | mainDocumentError ([out, retval] IWebError **error) |
Class Methods | |
(static WebDataSource *) | + createInstance |
Protected Member Functions | |
() | - WebDataSource |
() | - ~WebDataSource |
Protected Attributes | |
package void * | _private |
ULONG | m_refCount { 0 } |
RefPtr< WebDocumentLoader > | m_loader |
COMPtr< IWebDocumentRepresentation > | m_representation |
A WebDataSource represents the data associated with a web page. A datasource has a WebDocumentRepresentation which holds an appropriate representation of the data. WebDataSources manage a hierarchy of WebFrames. WebDataSources are typically related to a view by their containing WebFrame.
- WebDataSource | (WebDocumentLoader *) | loader |
- (HRESULT) addSubresource | (_In_opt_ IWebResource *) |
- (void) addSubresource: | (WebResource *) | subresource |
addSubresource: Adds a subresource to the data source.
subresource | The subresource to be added. addSubresource: adds a subresource to the data source's list of subresources. Later, if something causes the data source to load the URL of the subresource, the data source will load the data from the subresource instead of from the network. For example, if one wants to add an image that is already downloaded to a web page, addSubresource: can be called so that the data source uses the downloaded image rather than accessing the network. NOTE: If the data source already has a subresource with the same URL, addSubresource: will replace it. |
+ (WebDataSource *) createInstance | (WebDocumentLoader *) | loader |
- (WebDocumentLoader *) documentLoader | const |
- (HRESULT) initialRequest | (_COM_Outptr_opt_ IWebURLRequest **) | request |
- (HRESULT) initWithRequest | (_In_opt_ IWebURLRequest *) |
- (instancetype) initWithRequest: | (NSURLRequest *) | request |
initWithRequest: The designated initializer for WebDataSource.
request | The request to use in creating a datasource. |
- (HRESULT) mainResource | (_COM_Outptr_opt_ IWebResource **) | resource |
- (HRESULT) representation | (_COM_Outptr_opt_ IWebDocumentRepresentation **) | rep |
- (HRESULT) request | (_COM_Outptr_opt_ IWebMutableURLRequest **) | request |
- (HRESULT) response | (_COM_Outptr_opt_ IWebURLResponse **) | response |
Implements IWebDataSourcePrivate.
- (HRESULT) setOverrideEncoding | (_In_) | BSTR |
- (HRESULT) subresourceForURL | (_In_ BSTR) | url | |
(_COM_Outptr_opt_ IWebResource **) | resource | ||
- (WebResource *) subresourceForURL: | (NSURL *) | URL |
method subresourceForURL: Returns a subresource for a given URL.
URL | The URL of the subresource. Returns non-nil if the data source has fully downloaded a subresource with the given URL. |
- (HRESULT) subresources | (_COM_Outptr_opt_ IEnumVARIANT **) | enumResources |
- (HRESULT) webArchive | (_COM_Outptr_opt_ IWebArchive **) | archive |
|
protected |
|
protected |
|
protected |
|
protected |
Returns the raw data associated with the datasource. Returns nil if the datasource hasn't loaded any data. The data will be incomplete until the datasource has completely loaded.
|
readnonatomicstrong |
|
readnonatomicassign |
|
readnonatomicstrong |
A WebResource representing the data source. This method constructs a WebResource using the original downloaded data. This method can be used to construct a WebArchive in case the archive returned by WebDataSource's webArchive isn't sufficient.
|
readnonatomicstrong |
The representation associated with this datasource. Returns nil if the datasource hasn't created its representation. A representation holds a type specific representation of the datasource's data. The representation class is determined by mapping a MIME type to a class. The representation is created once the MIME type of the datasource content has been determined.
|
readnonatomicstrong |
The request that was used to create this datasource.
|
readnonatomicstrong |
The NSURLResponse for the data source.
|
readnonatomiccopy |
All the subresources associated with the data source. The returned array only contains subresources that have fully downloaded.
|
readnonatomiccopy |
Returns either the override encoding, as set on the WebView for this dataSource or the encoding from the response.
|
readnonatomicstrong |
|
readnonatomicstrong |
A WebArchive representing the data source, its subresources and child frames. This method constructs a WebArchive using the original downloaded data. In the case of HTML, if the current state of the document is preferred, webArchive should be called on the DOM document instead.