2000-02-28 16:30:00 +00:00
|
|
|
<?xml version="1.0"?>
|
2000-07-04 19:53:39 +00:00
|
|
|
<!DOCTYPE gsdoc PUBLIC "-//GNUstep//DTD gsdoc 0.6.6//EN" "http://www.gnustep.org/gsdoc-0_6_6.xml">
|
|
|
|
<gsdoc base="NSURLHandle" prev="NSURL" next="NSUnarchiver" up="Base">
|
2000-02-28 16:30:00 +00:00
|
|
|
<head>
|
|
|
|
<title>NSURLHandle</title>
|
|
|
|
<author name="Richard Frith-Macdonald">
|
|
|
|
<email address="rfm@gnu.org"/>
|
|
|
|
<url url="http://www.gnustep.org/developers/whoiswho.html"/>
|
|
|
|
</author>
|
|
|
|
<version>0.1</version>
|
|
|
|
<date>28 February, 2000</date>
|
|
|
|
</head>
|
|
|
|
<body>
|
|
|
|
<chapter>
|
|
|
|
<heading>NSURLHandle</heading>
|
|
|
|
<class name="NSURLHandle" super="NSObject">
|
|
|
|
<declared>Foundation/NSURLHandle.h</declared>
|
2000-02-29 11:01:41 +00:00
|
|
|
<desc>
|
2000-09-25 04:58:37 +00:00
|
|
|
<p>
|
|
|
|
An NSURLHandle instance is used to manage the resource data
|
|
|
|
corresponding to an NSURL object. A single NSURLHandle can
|
|
|
|
be used to manage multiple NSURL objects as long as those
|
|
|
|
objects all refer to the same resource.
|
|
|
|
</p>
|
|
|
|
<p>
|
|
|
|
Different NSURLHandle subclasses are used to manage different
|
|
|
|
types of URL (usually based on the scheme of the URL), and you
|
|
|
|
can register new subclasses to extend (or replace) the
|
|
|
|
standard ones.
|
|
|
|
</p>
|
2000-02-29 11:01:41 +00:00
|
|
|
</desc>
|
2000-09-22 13:45:58 +00:00
|
|
|
|
2000-02-29 11:01:41 +00:00
|
|
|
<method type="Class" factory="yes">
|
|
|
|
<sel>URLHandleClassForURL:</sel>
|
|
|
|
<arg type="NSURL*">anURL</arg>
|
|
|
|
<desc>
|
2000-09-22 13:45:58 +00:00
|
|
|
Returns the most recently registered NSURLHandle subclass that
|
2000-09-25 04:58:37 +00:00
|
|
|
responds to <ref id="initWithURL:">canInitWithURL:</ref>
|
|
|
|
with <code>YES</code>. If there is no such subclass, returns nil.
|
2000-02-29 11:01:41 +00:00
|
|
|
</desc>
|
|
|
|
</method>
|
2000-09-22 13:45:58 +00:00
|
|
|
|
2000-02-29 11:01:41 +00:00
|
|
|
<method type="NSURLHandle*" factory="yes">
|
|
|
|
<sel>cachedHandleForURL:</sel>
|
|
|
|
<arg type="NSURL*">anURL</arg>
|
|
|
|
<desc>
|
2000-09-22 13:45:58 +00:00
|
|
|
Returns a previously created object that handles the specified
|
2000-09-25 04:58:37 +00:00
|
|
|
URL (if any exists), otherwise returns nil.
|
2000-02-29 11:01:41 +00:00
|
|
|
</desc>
|
|
|
|
</method>
|
2000-09-22 13:45:58 +00:00
|
|
|
|
2000-02-29 11:01:41 +00:00
|
|
|
<method type="BOOL" factory="yes">
|
|
|
|
<sel>canInitWithURL:</sel>
|
|
|
|
<arg type="NSURL*">anURL</arg>
|
|
|
|
<desc>
|
2000-09-25 04:58:37 +00:00
|
|
|
MUST be implemented by subclasses to say which URLs they can handle.
|
|
|
|
This method is used to determine which subclasses can be used
|
|
|
|
to handle a particular URL.
|
2000-02-29 11:01:41 +00:00
|
|
|
</desc>
|
|
|
|
</method>
|
2000-09-22 13:45:58 +00:00
|
|
|
|
2000-02-29 11:01:41 +00:00
|
|
|
<method type="void" factory="yes">
|
|
|
|
<sel>registerURLHandleClass:</sel>
|
|
|
|
<arg type="Class">anURLHandleSubclass</arg>
|
|
|
|
<desc>
|
2000-09-22 13:45:58 +00:00
|
|
|
Used to register a subclass as being available to handle URLs.
|
2000-02-29 11:01:41 +00:00
|
|
|
</desc>
|
|
|
|
</method>
|
2000-09-22 13:45:58 +00:00
|
|
|
|
2000-02-29 11:01:41 +00:00
|
|
|
<method type="void">
|
|
|
|
<sel>addClient:</sel>
|
|
|
|
<arg type="id<NSURLHandleClient>">client</arg>
|
|
|
|
<desc>
|
|
|
|
</desc>
|
|
|
|
</method>
|
2000-09-22 13:45:58 +00:00
|
|
|
|
2000-02-29 11:01:41 +00:00
|
|
|
<method type="NSData*">
|
|
|
|
<sel>availableResourceData</sel>
|
|
|
|
<desc>
|
|
|
|
</desc>
|
|
|
|
</method>
|
2000-09-22 13:45:58 +00:00
|
|
|
|
2000-02-29 11:01:41 +00:00
|
|
|
<method type="void">
|
|
|
|
<sel>backgroundLoadDidFailWithReason:</sel>
|
|
|
|
<arg type="NSString*">reason</arg>
|
|
|
|
<desc>
|
|
|
|
</desc>
|
|
|
|
</method>
|
2000-09-22 13:45:58 +00:00
|
|
|
|
2000-02-29 11:01:41 +00:00
|
|
|
<method type="void">
|
|
|
|
<sel>beginLoadInBackground</sel>
|
|
|
|
<desc>
|
|
|
|
</desc>
|
|
|
|
</method>
|
2000-09-22 13:45:58 +00:00
|
|
|
|
2000-02-29 11:01:41 +00:00
|
|
|
<method type="void">
|
|
|
|
<sel>cancelLoadInBackground</sel>
|
|
|
|
<desc>
|
|
|
|
</desc>
|
|
|
|
</method>
|
2000-09-22 13:45:58 +00:00
|
|
|
|
2000-02-29 11:01:41 +00:00
|
|
|
<method type="void">
|
|
|
|
<sel>didLoadBytes:</sel>
|
|
|
|
<arg type="NSData*">newBytes</arg>
|
|
|
|
<sel>loadComplete:</sel>
|
|
|
|
<arg type="BOOL">yorn</arg>
|
|
|
|
<desc>
|
|
|
|
</desc>
|
|
|
|
</method>
|
2000-09-22 13:45:58 +00:00
|
|
|
|
2000-02-29 11:01:41 +00:00
|
|
|
<method type="void">
|
|
|
|
<sel>endLoadInBackground</sel>
|
|
|
|
<desc>
|
|
|
|
</desc>
|
|
|
|
</method>
|
2000-09-22 13:45:58 +00:00
|
|
|
|
2000-02-29 11:01:41 +00:00
|
|
|
<method type="NSString*">
|
|
|
|
<sel>failureReason</sel>
|
|
|
|
<desc>
|
|
|
|
</desc>
|
|
|
|
</method>
|
2000-09-22 13:45:58 +00:00
|
|
|
|
2000-02-29 11:01:41 +00:00
|
|
|
<method type="void">
|
|
|
|
<sel>flushCachedData</sel>
|
|
|
|
<desc>
|
|
|
|
</desc>
|
|
|
|
</method>
|
2000-09-22 13:45:58 +00:00
|
|
|
|
2000-02-29 11:01:41 +00:00
|
|
|
<method type="void">
|
|
|
|
<sel>loadInBackground</sel>
|
|
|
|
<desc>
|
|
|
|
</desc>
|
|
|
|
</method>
|
2000-09-22 13:45:58 +00:00
|
|
|
|
2000-02-29 11:01:41 +00:00
|
|
|
<method type="NSData*">
|
|
|
|
<sel>loadInForeground</sel>
|
|
|
|
<desc>
|
|
|
|
</desc>
|
|
|
|
</method>
|
2000-09-22 13:45:58 +00:00
|
|
|
|
2000-02-29 11:01:41 +00:00
|
|
|
<method type="id">
|
|
|
|
<sel>propertyForKey:</sel>
|
|
|
|
<arg type="NSString*">propertyKey</arg>
|
|
|
|
<desc>
|
|
|
|
</desc>
|
|
|
|
</method>
|
2000-09-22 13:45:58 +00:00
|
|
|
|
2000-02-29 11:01:41 +00:00
|
|
|
<method type="id">
|
|
|
|
<sel>propertyForKeyIfAvailable:</sel>
|
|
|
|
<arg type="NSString*">propertyKey</arg>
|
|
|
|
<desc>
|
|
|
|
</desc>
|
|
|
|
</method>
|
2000-09-22 13:45:58 +00:00
|
|
|
|
2000-02-29 11:01:41 +00:00
|
|
|
<method type="void">
|
|
|
|
<sel>removeClient:</sel>
|
|
|
|
<arg type="id<NSURLHandleClient>">client</arg>
|
|
|
|
<desc>
|
|
|
|
</desc>
|
|
|
|
</method>
|
2000-09-22 13:45:58 +00:00
|
|
|
|
2000-02-29 11:01:41 +00:00
|
|
|
<method type="NSData*">
|
|
|
|
<sel>resourceData</sel>
|
|
|
|
<desc>
|
|
|
|
</desc>
|
|
|
|
</method>
|
2000-09-22 13:45:58 +00:00
|
|
|
|
2000-02-29 11:01:41 +00:00
|
|
|
<method type="NSURLHandleStatus">
|
|
|
|
<sel>status</sel>
|
|
|
|
<desc>
|
|
|
|
</desc>
|
|
|
|
</method>
|
2000-09-22 13:45:58 +00:00
|
|
|
|
2000-02-29 11:01:41 +00:00
|
|
|
<method type="BOOL">
|
|
|
|
<sel>writeData:</sel>
|
|
|
|
<arg type="NSData*">data</arg>
|
|
|
|
<desc>
|
|
|
|
</desc>
|
|
|
|
</method>
|
2000-09-22 13:45:58 +00:00
|
|
|
|
2000-02-29 11:01:41 +00:00
|
|
|
<method type="BOOL">
|
|
|
|
<sel>writeProperty:</sel>
|
|
|
|
<arg type="id">propertyValue</arg>
|
|
|
|
<desc>
|
|
|
|
</desc>
|
2000-02-28 18:30:41 +00:00
|
|
|
</method>
|
2000-09-25 04:58:37 +00:00
|
|
|
<standards><MacOS-X/><NotOpenStep/></standards>
|
2000-02-28 16:30:00 +00:00
|
|
|
</class>
|
2000-09-25 04:58:37 +00:00
|
|
|
|
|
|
|
<protocol name="NSURLHandleClient">
|
|
|
|
<declared>Foundation/NSURLHandle.h</declared>
|
|
|
|
<desc>
|
|
|
|
</desc>
|
|
|
|
|
|
|
|
<method type="void">
|
|
|
|
<sel>URLHandleResourceDidBeginLoading:</sel>
|
|
|
|
<arg type="NSURLHandle*">sender</arg>
|
|
|
|
<desc>
|
|
|
|
Sent by the NSURLHandle object when it begins loading
|
|
|
|
resource data.
|
|
|
|
</desc>
|
|
|
|
</method>
|
|
|
|
|
|
|
|
<method type="void">
|
|
|
|
<sel>URLHandleResourceDidCancelLoading:</sel>
|
|
|
|
<arg type="NSURLHandle*">sender</arg>
|
|
|
|
<desc>
|
|
|
|
Sent by the NSURLHandle object when resource loading is cancelled
|
|
|
|
by programmatic request (rather than by failure).
|
|
|
|
</desc>
|
|
|
|
</method>
|
|
|
|
|
|
|
|
<method type="void">
|
|
|
|
<sel>URLHandleResourceDidFinishLoading:</sel>
|
|
|
|
<arg type="NSURLHandle*">sender</arg>
|
|
|
|
<desc>
|
|
|
|
Sent by the NSURLHandle object when it completes loading
|
|
|
|
resource data.
|
|
|
|
</desc>
|
|
|
|
</method>
|
|
|
|
|
|
|
|
<method type="void">
|
|
|
|
<sel>URLHandle:</sel>
|
|
|
|
<arg type="NSURLHandle*">sender</arg>
|
|
|
|
<sel>resourceDidBecomeAvailable:</sel>
|
|
|
|
<arg type="NSData*">data</arg>
|
|
|
|
<desc>
|
|
|
|
Sent by the NSURLHandle object when some data becomes available
|
|
|
|
from the handle.
|
|
|
|
</desc>
|
|
|
|
</method>
|
|
|
|
|
|
|
|
<method type="void">
|
|
|
|
<sel>URLHandle:</sel>
|
|
|
|
<arg type="NSURLHandle*">sender</arg>
|
|
|
|
<sel>resourceDidFailLoadingWithReason:</sel>
|
|
|
|
<arg type="NSString*">reason</arg>
|
|
|
|
<desc>
|
|
|
|
Sent by the NSURLHandle object on resource load failure.
|
|
|
|
Supplies a human readable failure reason.
|
|
|
|
</desc>
|
|
|
|
</method>
|
|
|
|
|
|
|
|
<standards><MacOS-X/><NotOpenStep/></standards>
|
|
|
|
</protocol>
|
|
|
|
|
|
|
|
<type name="NSURLHandleStatus">
|
|
|
|
<typespec>int</typespec>
|
|
|
|
<declared>Foundation/NSURLHandle.h</declared>
|
|
|
|
<desc>
|
|
|
|
An NSURLHandleStatus is used to report the current state of an
|
|
|
|
NSURLHandle object, it can take the following values -
|
|
|
|
<list>
|
|
|
|
<item>NSURLHandleNotLoaded</item>
|
|
|
|
<item>NSURLHandleLoadSucceeded</item>
|
|
|
|
<item>NSURLHandleLoadInProgress</item>
|
|
|
|
<item>NSURLHandleLoadFailed</item>
|
|
|
|
</list>
|
|
|
|
</desc>
|
|
|
|
<standards><MacOS-X/><NotOpenStep/></standards>
|
|
|
|
</type>
|
2000-02-28 16:30:00 +00:00
|
|
|
</chapter>
|
|
|
|
</body>
|
|
|
|
</gsdoc>
|