ObjFW
Public Member Functions | Static Public Member Functions
OFApplication Class Reference

Represents the application as an object. More...

#import <OFApplication.h>

Inheritance diagram for OFApplication:
OFObject <OFObject>

List of all members.

Public Member Functions

(void) - setArgumentCount:andArgumentValues:
 Sets argc and argv.
(void) - getArgumentCount:andArgumentValues:
 Gets args and argv.
(OFString *) - programName
 Returns the name of the program (argv[0]).
(OFArray *) - arguments
 Returns the arguments passed to the application.
(OFDictionary *) - environment
 Returns the environment of the application.
(id< OFApplicationDelegate >) - delegate
 Returns the delegate of the application.
(void) - setDelegate:
 Sets the delegate of the application.
(void) - run
 Starts the application after everything has been initialized.
(void) - terminate
 Terminates the application.
(void) - terminateWithStatus:
 Terminates the application with the specified status.

Static Public Member Functions

(id) + sharedApplication
 Returns the only OFApplication instance in the application.
(OFString *) + programName
 Returns the name of the program (argv[0]).
(OFArray *) + arguments
 Returns the arguments passed to the application.
(OFDictionary *) + environment
 Returns the environment of the application.
(void) + terminate
 Terminates the application.
(void) + terminateWithStatus:
 Terminates the application with the specified status.

Detailed Description

Represents the application as an object.


Member Function Documentation

+ (OFArray*) arguments

Returns the arguments passed to the application.

Returns:
The arguments passed to the application
- (OFArray*) arguments

Returns the arguments passed to the application.

Returns:
The arguments passed to the application
- (id <OFApplicationDelegate>) delegate

Returns the delegate of the application.

Returns:
The delegate of the application
+ (OFDictionary*) environment

Returns the environment of the application.

Returns:
The environment of the application
- (OFDictionary*) environment

Returns the environment of the application.

Returns:
The environment of the application
- (void) getArgumentCount: (int **)  argc
andArgumentValues: (char ***[])  argv 

Gets args and argv.

Parameters:
argcA pointer where a pointer to argc should be stored
argvA pointer where a pointer to argv should be stored
+ (OFString*) programName

Returns the name of the program (argv[0]).

Returns:
The name of the program (argv[0])
- (OFString*) programName

Returns the name of the program (argv[0]).

Returns:
The name of the program (argv[0])
- (void) run

Starts the application after everything has been initialized.

You should not call this directly, but use OF_APPLICATION_DELEGATE instead!

- (void) setArgumentCount: (int *)  argc
andArgumentValues: (char **[])  argv 

Sets argc and argv.

You should not call this directly, but use OF_APPLICATION_DELEGATE instead!

Parameters:
argcThe number of arguments
argvThe argument values
- (void) setDelegate: (id <OFApplicationDelegate>)  delegate

Sets the delegate of the application.

Parameters:
delegateThe delegate for the application
+ (id) sharedApplication

Returns the only OFApplication instance in the application.

Returns:
The only OFApplication instance in the application
+ (void) terminateWithStatus: (int)  status

Terminates the application with the specified status.

Parameters:
statusThe status with which the application will terminate
- (void) terminateWithStatus: (int)  status

Terminates the application with the specified status.

Parameters:
statusThe status with which the application will terminate

The documentation for this class was generated from the following files:
 All Classes Functions Variables Properties