5 // Created by Jack Jansen on Sun Jul 21 2002.
6 // Copyright (c) 2002 __MyCompanyName__. All rights reserved.
9 #import <Foundation/Foundation.h>
11 @protocol FileSettingsSource
12 - (NSString
*) interpreter
;
13 - (BOOL
) honourhashbang
;
20 - (NSString
*) others
;
21 - (BOOL
) with_terminal
;
22 - (NSString
*) scriptargs
;
25 @interface FileSettings
: NSObject
<FileSettingsSource
>
27 NSString
*interpreter
; // The pathname of the interpreter to use
28 NSArray
*interpreters
; // List of known interpreters
29 BOOL honourhashbang
; // #! line overrides interpreter
30 BOOL debug
; // -d option: debug parser
31 BOOL verbose
; // -v option: verbose import
32 BOOL inspect
; // -i option: interactive mode after script
33 BOOL optimize
; // -O option: optimize bytecode
34 BOOL nosite
; // -S option: don't import site.py
35 BOOL tabs
; // -t option: warn about inconsistent tabs
36 NSString
*others
; // other options
37 NSString
*scriptargs
; // script arguments (not for preferences)
38 BOOL with_terminal
; // Run in terminal window
40 FileSettings
*origsource
;
44 + (id
)getDefaultsForFileType
: (NSString
*)filetype
;
45 + (id
)getFactorySettingsForFileType
: (NSString
*)filetype
;
46 + (id
)newSettingsForFileType
: (NSString
*)filetype
;
49 - (id
)initForFileType
: (NSString
*)filetype
;
50 - (id
)initForFSDefaultFileType
: (NSString
*)filetype
;
51 - (id
)initForDefaultFileType
: (NSString
*)filetype
;
52 //- (id)initWithFileSettings: (FileSettings *)source;
54 - (void)updateFromSource
: (id
<FileSettingsSource
>)source
;
55 - (NSString
*)commandLineForScript
: (NSString
*)script
;
57 //- (void)applyFactorySettingsForFileType: (NSString *)filetype;
58 //- (void)saveDefaults;
59 //- (void)applyUserDefaults: (NSString *)filetype;
60 - (void)applyValuesFromDict
: (NSDictionary
*)dict
;
62 - (NSArray
*) interpreters
;