comparison dwt/internal/cocoa/NSScriptClassDescription.d @ 1:8b48be5454ce

The internal cocoa classes compile now
author Jacob Carlborg <doob@me.com> <jacob.carlborg@gmail.com>
date Tue, 19 Aug 2008 17:35:17 +0200
parents 380af2bdd8e5
children f565d3a95c0a
comparison
equal deleted inserted replaced
0:380af2bdd8e5 1:8b48be5454ce
35 super(id); 35 super(id);
36 } 36 }
37 37
38 public FourCharCode appleEventCode () 38 public FourCharCode appleEventCode ()
39 { 39 {
40 return cast(FourCharCode) OS.objc_msgSend(this.id, OS.sel_appleEventCode); 40 return cast(FourCharCode) OS.objc_msgSend(this.id_, OS.sel_appleEventCode);
41 } 41 }
42 42
43 public FourCharCode appleEventCodeForKey (NSString key) 43 public FourCharCode appleEventCodeForKey (NSString key)
44 { 44 {
45 return cast(FourCharCode) OS.objc_msgSend(this.id, OS.sel_appleEventCodeForKey_1, key !is null ? key.id : null); 45 return cast(FourCharCode) OS.objc_msgSend(this.id_, OS.sel_appleEventCodeForKey_1, key !is null ? key.id_ : null);
46 } 46 }
47 47
48 //public static NSScriptClassDescription classDescriptionForClass(int aClass) { 48 //public static NSScriptClassDescription classDescriptionForClass(int aClass) {
49 // objc.id result = OS.objc_msgSend(OS.class_NSScriptClassDescription, OS.sel_classDescriptionForClass_1, aClass); 49 // objc.id result = OS.objc_msgSend(OS.class_NSScriptClassDescription, OS.sel_classDescriptionForClass_1, aClass);
50 // return result !is null ? new NSScriptClassDescription(result) : null; 50 // return result !is null ? new NSScriptClassDescription(result) : null;
51 //} 51 //}
52 52
53 public NSScriptClassDescription classDescriptionForKey (NSString key) 53 public NSScriptClassDescription classDescriptionForKey (NSString key)
54 { 54 {
55 objc.id result = OS.objc_msgSend(this.id, OS.sel_classDescriptionForKey_1, key !is null ? key.id : null); 55 objc.id result = OS.objc_msgSend(this.id_, OS.sel_classDescriptionForKey_1, key !is null ? key.id_ : null);
56 return result is this.id ? this : (result !is null ? new NSScriptClassDescription(result) : null); 56 return result is this.id_ ? this : (result !is null ? new NSScriptClassDescription(result) : null);
57 } 57 }
58 58
59 public NSString className () 59 public NSString className ()
60 { 60 {
61 objc.id result = OS.objc_msgSend(this.id, OS.sel_className); 61 objc.id result = OS.objc_msgSend(this.id_, OS.sel_className);
62 return result !is null ? new NSString(result) : null; 62 return result !is null ? new NSString(result) : null;
63 } 63 }
64 64
65 public NSString defaultSubcontainerAttributeKey () 65 public NSString defaultSubcontainerAttributeKey ()
66 { 66 {
67 objc.id result = OS.objc_msgSend(this.id, OS.sel_defaultSubcontainerAttributeKey); 67 objc.id result = OS.objc_msgSend(this.id_, OS.sel_defaultSubcontainerAttributeKey);
68 return result !is null ? new NSString(result) : null; 68 return result !is null ? new NSString(result) : null;
69 } 69 }
70 70
71 public bool hasOrderedToManyRelationshipForKey (NSString key) 71 public bool hasOrderedToManyRelationshipForKey (NSString key)
72 { 72 {
73 return OS.objc_msgSend(this.id, OS.sel_hasOrderedToManyRelationshipForKey_1, key !is null ? key.id : null) !is null; 73 return OS.objc_msgSend(this.id_, OS.sel_hasOrderedToManyRelationshipForKey_1, key !is null ? key.id_ : null) !is null;
74 } 74 }
75 75
76 public bool hasPropertyForKey (NSString key) 76 public bool hasPropertyForKey (NSString key)
77 { 77 {
78 return OS.objc_msgSend(this.id, OS.sel_hasPropertyForKey_1, key !is null ? key.id : null) !is null; 78 return OS.objc_msgSend(this.id_, OS.sel_hasPropertyForKey_1, key !is null ? key.id_ : null) !is null;
79 } 79 }
80 80
81 public bool hasReadablePropertyForKey (NSString key) 81 public bool hasReadablePropertyForKey (NSString key)
82 { 82 {
83 return OS.objc_msgSend(this.id, OS.sel_hasReadablePropertyForKey_1, key !is null ? key.id : null) !is null; 83 return OS.objc_msgSend(this.id_, OS.sel_hasReadablePropertyForKey_1, key !is null ? key.id_ : null) !is null;
84 } 84 }
85 85
86 public bool hasWritablePropertyForKey (NSString key) 86 public bool hasWritablePropertyForKey (NSString key)
87 { 87 {
88 return OS.objc_msgSend(this.id, OS.sel_hasWritablePropertyForKey_1, key !is null ? key.id : null) !is null; 88 return OS.objc_msgSend(this.id_, OS.sel_hasWritablePropertyForKey_1, key !is null ? key.id_ : null) !is null;
89 } 89 }
90 90
91 public NSString implementationClassName () 91 public NSString implementationClassName ()
92 { 92 {
93 objc.id result = OS.objc_msgSend(this.id, OS.sel_implementationClassName); 93 objc.id result = OS.objc_msgSend(this.id_, OS.sel_implementationClassName);
94 return result !is null ? new NSString(result) : null; 94 return result !is null ? new NSString(result) : null;
95 } 95 }
96 96
97 public id initWithSuiteName (NSString suiteName, NSString className, NSDictionary classDeclaration) 97 public id initWithSuiteName (NSString suiteName, NSString className, NSDictionary classDeclaration)
98 { 98 {
99 objc.id result = OS.objc_msgSend(this.id, OS.sel_initWithSuiteName_1className_1dictionary_1, suiteName !is null ? suiteName.id : null, 99 objc.id result = OS.objc_msgSend(this.id_, OS.sel_initWithSuiteName_1className_1dictionary_1, suiteName !is null ? suiteName.id_ : null,
100 className !is null ? className.id : null, classDeclaration !is null ? classDeclaration.id : null); 100 className !is null ? className.id_ : null, classDeclaration !is null ? classDeclaration.id_ : null);
101 return result !is null ? new id(result) : null; 101 return result !is null ? new id(result) : null;
102 } 102 }
103 103
104 public bool isLocationRequiredToCreateForKey (NSString toManyRelationshipKey) 104 public bool isLocationRequiredToCreateForKey (NSString toManyRelationshipKey)
105 { 105 {
106 return OS.objc_msgSend(this.id, OS.sel_isLocationRequiredToCreateForKey_1, toManyRelationshipKey !is null ? toManyRelationshipKey.id : null) !is null; 106 return OS.objc_msgSend(this.id_, OS.sel_isLocationRequiredToCreateForKey_1, toManyRelationshipKey !is null ? toManyRelationshipKey.id_ : null) !is null;
107 } 107 }
108 108
109 public bool isReadOnlyKey (NSString key) 109 public bool isReadOnlyKey (NSString key)
110 { 110 {
111 return OS.objc_msgSend(this.id, OS.sel_isReadOnlyKey_1, key !is null ? key.id : null) !is null; 111 return OS.objc_msgSend(this.id_, OS.sel_isReadOnlyKey_1, key !is null ? key.id_ : null) !is null;
112 } 112 }
113 113
114 public NSString keyWithAppleEventCode (FourCharCode appleEventCode) 114 public NSString keyWithAppleEventCode (FourCharCode appleEventCode)
115 { 115 {
116 objc.id result = OS.objc_msgSend(this.id, OS.sel_keyWithAppleEventCode_1, appleEventCode); 116 objc.id result = OS.objc_msgSend(this.id_, OS.sel_keyWithAppleEventCode_1, appleEventCode);
117 return result !is null ? new NSString(result) : null; 117 return result !is null ? new NSString(result) : null;
118 } 118 }
119 119
120 public bool matchesAppleEventCode (FourCharCode appleEventCode) 120 public bool matchesAppleEventCode (FourCharCode appleEventCode)
121 { 121 {
122 return OS.objc_msgSend(this.id, OS.sel_matchesAppleEventCode_1, appleEventCode) !is null; 122 return OS.objc_msgSend(this.id_, OS.sel_matchesAppleEventCode_1, appleEventCode) !is null;
123 } 123 }
124 124
125 public int selectorForCommand (NSScriptCommandDescription commandDescription) 125 public objc.SEL selectorForCommand (NSScriptCommandDescription commandDescription)
126 { 126 {
127 return OS.objc_msgSend(this.id, OS.sel_selectorForCommand_1, commandDescription !is null ? commandDescription.id : null); 127 return cast(objc.SEL) OS.objc_msgSend(this.id_, OS.sel_selectorForCommand_1, commandDescription !is null ? commandDescription.id_ : null);
128 } 128 }
129 129
130 public NSString suiteName () 130 public NSString suiteName ()
131 { 131 {
132 objc.id result = OS.objc_msgSend(this.id, OS.sel_suiteName); 132 objc.id result = OS.objc_msgSend(this.id_, OS.sel_suiteName);
133 return result !is null ? new NSString(result) : null; 133 return result !is null ? new NSString(result) : null;
134 } 134 }
135 135
136 public NSScriptClassDescription superclassDescription () 136 public NSScriptClassDescription superclassDescription ()
137 { 137 {
138 objc.id result = OS.objc_msgSend(this.id, OS.sel_superclassDescription); 138 objc.id result = OS.objc_msgSend(this.id_, OS.sel_superclassDescription);
139 return result is this.id ? this : (result !is null ? new NSScriptClassDescription(result) : null); 139 return result is this.id_ ? this : (result !is null ? new NSScriptClassDescription(result) : null);
140 } 140 }
141 141
142 public bool supportsCommand (NSScriptCommandDescription commandDescription) 142 public bool supportsCommand (NSScriptCommandDescription commandDescription)
143 { 143 {
144 return OS.objc_msgSend(this.id, OS.sel_supportsCommand_1, commandDescription !is null ? commandDescription.id : null) !is null; 144 return OS.objc_msgSend(this.id_, OS.sel_supportsCommand_1, commandDescription !is null ? commandDescription.id_ : null) !is null;
145 } 145 }
146 146
147 public NSString typeForKey (NSString key) 147 public NSString typeForKey (NSString key)
148 { 148 {
149 objc.id result = OS.objc_msgSend(this.id, OS.sel_typeForKey_1, key !is null ? key.id : null); 149 objc.id result = OS.objc_msgSend(this.id_, OS.sel_typeForKey_1, key !is null ? key.id_ : null);
150 return result !is null ? new NSString(result) : null; 150 return result !is null ? new NSString(result) : null;
151 } 151 }
152 152
153 } 153 }