Class: NKLibrary
Overview
An instance of the NKLibrary class represents the library of issues for a newsstand content application.
Instance Attribute Summary (collapse)
-
- currentlyReadingIssue
Accesses or sets the newsstand issue that the user is currently reading.
-
- downloadingAssets
readonly
The assets that are currently being downloaded for one or more issues of the newsstand content library.
-
- issues
readonly
Returns the current issues of the newsstand content library.
Class Method Summary (collapse)
-
+ sharedLibrary
Returns the shared instance representing the newsstand content library.
Instance Method Summary (collapse)
-
- addIssueWithName:date:
Creates a newsstand issue and adds it to the content library.
-
- issueWithName:
Returns an issue of the newsstand content library specified by name.
-
- removeIssue:
Removes the specified issue from the newsstand content library.
Methods inherited from NSObject
#!, #!=, #!~, #, #==, #===, #=~, #Rational, #__callee__, #__method__, #__send__, #__type__, `, alloc, allocWithZone:, #autoContentAccessingProxy, autoload, autoload?, autorelease_pool, #awakeAfterUsingCoder:, binding, block_given?, caller, cancelPreviousPerformRequestsWithTarget:, cancelPreviousPerformRequestsWithTarget:selector:object:, catch, class, classFallbacksForKeyedArchiver, #classForCoder, #classForKeyedArchiver, classForKeyedUnarchiver, #clone, conformsToProtocol:, #copy, copyWithZone:, #dealloc, #define_singleton_method, description, display, #doesNotRecognizeSelector:, #dup, #enum_for, #eql?, #equal?, #extend, fail, #finalize, format, #forwardInvocation:, #forwardingTargetForSelector:, framework, #freeze, #frozen?, getpass, gets, global_variables, #init, initialize, #initialize_clone, #initialize_copy, #initialize_dup, #inspect, instanceMethodForSelector:, instanceMethodSignatureForSelector:, #instance_eval, #instance_exec, #instance_of?, #instance_variable_defined?, #instance_variable_get, #instance_variable_set, #instance_variables, instancesRespondToSelector:, isSubclassOfClass:, #is_a?, iterator?, #kind_of?, lambda, load, load_bridge_support_file, load_plist, local_variables, loop, #method, #methodForSelector:, #methodSignatureForSelector:, #methods, #mutableCopy, mutableCopyWithZone:, new, #nil?, open, p, #performSelector:onThread:withObject:waitUntilDone:, #performSelector:onThread:withObject:waitUntilDone:modes:, #performSelector:withObject:afterDelay:, #performSelector:withObject:afterDelay:inModes:, #performSelectorInBackground:withObject:, #performSelectorOnMainThread:withObject:waitUntilDone:, #performSelectorOnMainThread:withObject:waitUntilDone:modes:, print, printf, #private_methods, proc, #protected_methods, #public_method, #public_methods, #public_send, putc, puts, raise, rand, readline, readlines, #replacementObjectForCoder:, #replacementObjectForKeyedArchiver:, require, resolveClassMethod:, resolveInstanceMethod:, #respond_to?, #respond_to_missing?, select, #send, setVersion:, #singleton_methods, sprintf, srand, superclass, #taint, #tainted?, #tap, test, throw, #to_plist, #to_s, trace_var, trap, #trust, #untaint, untrace_var, #untrust, #untrusted?, version
Constructor Details
This class inherits a constructor from NSObject
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class NSObject
Instance Attribute Details
- (NKIssue) currentlyReadingIssue
Accesses or sets the newsstand issue that the user is currently reading. When you ascertain what issue the user is currently reading, you should set this property to the corresponding NKIssue instance. Newsstand Kit takes this setting into consideration when it purges back issues because of low levels of available flash storage.
- (Array) downloadingAssets (readonly)
The assets that are currently being downloaded for one or more issues of the newsstand content library. (read-only) When a newsstand application launches, it should enumerate the NKAssetDownload objects in the returned array, call downloadWithDelegate: on each object, and process each downloaded asset.
Class Method Details
+ (NKLibrary) sharedLibrary
Returns the shared instance representing the newsstand content library.
Instance Method Details
- (NKIssue) addIssueWithName(name, date:date)
Creates a newsstand issue and adds it to the content library. The created issue is automatically added to the newsstand content library. Issues are ordered by their release date. The release date of an issue can be a factor when Newsstand Kit must delete back issues because of low levels of available flash storage.This method throws an exception if the name and date parameters are nil or are otherwise not valid objects. It also throws an exception if you pass in an issue name that is used by another issue.
- (NKIssue) issueWithName(name)
Returns an issue of the newsstand content library specified by name.
- (Object) removeIssue(issue)
Removes the specified issue from the newsstand content library. When an issue is removed, any data at the file-system location identified by the issue’s content URL (accessed through the contentURL property of NKIssue) is deleted from disk. If you have issue content elsewhere in the application sandbox, it’s your responsibility to clean it up. Calling this method also cancels any asset downloads for that issue that are underway.