iOS Module SDK
0.97
Tools for building CampusLife modules
|
#import <D2LModuleAssistant.h>
Public Member Functions | |
(NSString *) | - title |
(void) | - setRootViewController: |
(BOOL) | - hasOption: |
(NSString *) | - stringForOption: |
(NSNumber *) | - numberForOption: |
(BOOL) | - boolForOption: |
(NSURL *) | - urlForOption: |
(NSURL *) | - localFileURLForOption: |
(void) | - setBadgeNumber: |
(void) | - dismiss |
(NSString *) | - applicationSupportPath |
(NSString *) | - cachesPath |
(NSString *) | - documentsPath |
(NSString *) | - tmpPath |
On initialization, your module receives an assistant object implementing this protocol. This object provides services specific to an instance of your module. (Your module may have multiple instances within the application; each receives its own assistant.)
- (NSString *) applicationSupportPath |
Retrieves a path to a subdirectory of the application's Library/Application Support folder specific to this module instance.
- (BOOL) boolForOption: | (NSString *) | option |
Retrieves the value of a module configuration option as a boolean.
option | - The name of the parameter to retrieve. |
- (NSString *) cachesPath |
Retrieves a path to a subdirectory of the application's Library/Caches folder specific to this module instance.
- (void) dismiss |
Closes the module and returns the user to the application's main menu. (Your module must provide a way for the user to return to the main menu.)
- (NSString *) documentsPath |
Retrieves a path to a subdirectory of the application's Documents folder specific to this module instance.
- (BOOL) hasOption: | (NSString *) | option |
Checks if an option was provided to the module.
option | - The name of the parameter to check. |
- (NSURL *) localFileURLForOption: | (NSString *) | option |
Retrieves the local file URL for a file asset that was uploaded in AppBuilder for use by the module.
option | - The name of the parameter to retrieve. |
- (NSNumber *) numberForOption: | (NSString *) | option |
Retrieves the value of a module configuration option as a number.
option | - The name of the parameter to retrieve. |
- (void) setBadgeNumber: | (NSInteger) | number |
Sets the badge number that is displayed on your module's button on the application main menu.
number | - The number to display. The badge will not be visible if the number is 0 or negative. |
- (void) setRootViewController: | (UIViewController *) | viewController |
Sets this module's root view controller.
The module's root view controller is released when the module is closed.
viewController | - The module's new root view controller. |
- (NSString *) stringForOption: | (NSString *) | option |
Retrieves the value of a module configuration option as a string.
option | - The name of the parameter to retrieve. |
- (NSString *) title |
Retrieves the title of the module instance (that is, the text of the button on the app main menu that launched it).
- (NSString *) tmpPath |
Retrieves a path to a subdirectory of the application's tmp folder specific to this module instance.
- (NSURL *) urlForOption: | (NSString *) | option |
Retrieves the value of a module configuration option as a URL.
option | - The name of the parameter to retrieve. |