• BlackBerry Dynamics
  • Runtime library for iOS applications
  • 10.1.0.36
NSURLCache(GDURLCache) Category Reference

NSURLCache category with additional features. More...

#import <GDNET.h>

Description

This class is a category of the native NSURLCache class that adds the functions documented below to the interface. The additional functions can be used when the BlackBerry Dynamics proxy infrastructure is in use in the URL Loading System, see GDURLLoadingSystem, or in the URL session system, see NSURLSession Support.

This class provides additional features to the default cache.

This documentation includes only additional operations that are not part of the default NSURLCache interface.

Note that the additional features cannot be used when the BlackBerry Dynamics proxy infrastructure isn't in use, even if temporarily. If the functions are called in this state, they have no effect.

See also
NSURLCache Class Reference on the apple.com developer website.

Instance Methods

(void) - setMaxCacheFileAge:
 Set the default maximum age of cached files. More...
 
(void) - setMaxCacheFileSize:
 Set the maximum permitted size of a cached file. More...
 
(NSUInteger) - maxCacheFileSize
 Get the maximum permitted size of a cached file. More...
 

Method Documentation

◆ setMaxCacheFileAge:

- (void) setMaxCacheFileAge: (NSTimeInterval)  age

Call this function to set a default maximum age for cached files. The default maximum age will be used where it is less than the maximum age specified in the server cache directive, if any.

The default maximum only applies when the BlackBerry Dynamics proxy infrastructure is in use as described in the description, above.

Parameters
ageNSTimeInterval representing the maximum age in seconds.

◆ setMaxCacheFileSize:

- (void) setMaxCacheFileSize: (NSUInteger)  fileSize

Call this function to set the maximum permitted size of a cached file. If not set, a default maximum of 1 megabyte will be used. If set to 0, cache will be disabled. If size of file is greater than 5% of cache capacity, the file will not be cached.

This function sets the limit for a single file, not for the size of the whole cache. The capacity of the cache as a whole can be set using the native NSURLCache programming interfacer. See the NSURLCache Class Reference on the apple.com developer website for details.

The permitted maximum only applies when the BlackBerry Dynamics proxy infrastructure is in use as described in the description, above.

Parameters
fileSizeNSUInteger representing the maximum file size in bytes.

◆ maxCacheFileSize

- (NSUInteger) maxCacheFileSize

Call this function to get the maximum permitted size of a cached file.

This function returns the limit for a single file, not for the size of the whole cache. The native NSURLCache API can be used to access information about the cache as a whole. See the NSURLCache Class Reference on the apple.com developer website for details.

The permitted maximum only applies when the BlackBerry Dynamics proxy infrastructure is in use as described in the description, above.

Returns
NSUInteger representing the maximum file size in bytes.

The documentation for this category was generated from the following file: