Zen API

- Home
- Topics
- Types
- Files

All Classes Files Functions Variables Typedefs Friends Macros Modules Pages
kAssembly.h
Go to the documentation of this file.
1
10 #include <kApi/kApiDef.h> //--inclusion order controlled by kApiDef
11
12 #ifndef K_API_ASSEMBLY_H
13 #define K_API_ASSEMBLY_H
14
15 #include <kApi/kAssembly.x.h>
16
69 //typedef kObject kAssembly; --forward-declared in kApiDef.x.h
70
81 kFx(kStatus) kAssembly_Enumerate(kArrayList assemblies);
82
94 kFx(kStatus) kAssembly_Find(const kChar* name, kAssembly* assembly);
95
111 kFx(kStatus) kAssembly_AddLoadHandler(kCallbackFx function, kPointer receiver);
112
121 kFx(kStatus) kAssembly_RemoveLoadHandler(kCallbackFx function, kPointer receiver);
122
138 kFx(kStatus) kAssembly_AddUnloadHandler(kCallbackFx function, kPointer receiver);
139
148 kFx(kStatus) kAssembly_RemoveUnloadHandler(kCallbackFx function, kPointer receiver);
149
166 kFx(kStatus) kAssembly_AddUnloadedHandler(kCallbackFx function, kPointer receiver);
167
176 kFx(kStatus) kAssembly_RemoveUnloadedHandler(kCallbackFx function, kPointer receiver);
177
185 kInlineFx(kVersion) kAssembly_Version(kAssembly assembly)
186 {
187 kObj(kAssembly, assembly);
188
189 return obj->version;
190 }
191
199 kInlineFx(kVersion) kAssembly_PlatformVersion(kAssembly assembly)
200 {
201 kObj(kAssembly, assembly);
202
203 return obj->platformVersion;
204 }
205
213 kInlineFx(const kChar*) kAssembly_Name(kAssembly assembly)
214 {
215 kObj(kAssembly, assembly);
216
217 return obj->name;
218 }
219
227 kInlineFx(kSize) kAssembly_TypeCount(kAssembly assembly)
228 {
229 kObj(kAssembly, assembly);
230
231 return obj->typeCount;
232 }
233
242 kInlineFx(kType) kAssembly_TypeAt(kAssembly assembly, kSize index)
243 {
244 kObj(kAssembly, assembly);
245
246 kAssert(index < obj->typeCount);
247
248 return obj->types[index];
249 }
250
260 kFx(kStatus) kAssembly_FindType(kAssembly assembly, const kChar* name, kType* type);
261
271 kFx(kStatus) kAssembly_FindDerivedTypes(kAssembly assembly, kType base, kArrayList types);
272
280 kInlineFx(kSize) kAssembly_DependencyCount(kAssembly assembly)
281 {
282 kObj(kAssembly, assembly);
283
284 return obj->dependencyCount;
285 }
286
295 kInlineFx(kAssembly) kAssembly_DependencyAt(kAssembly assembly, kSize index)
296 {
297 kObj(kAssembly, assembly);
298
299 kAssert(index < obj->dependencyCount);
300
301 return obj->dependencies[index];
302 }
303
304 #endif
kAssembly::kAssembly_PlatformVersion
kVersion kAssembly_PlatformVersion(kAssembly assembly)
Gets the platform version.
Definition: kAssembly.h:199
kAssembly::kAssembly_RemoveUnloadHandler
kStatus kAssembly_RemoveUnloadHandler(kCallbackFx function, kPointer receiver)
Removes a callback that was registered with the kAssembly_AddUnloadHandler function.
kAssembly
Represents a library of types.
kPointer
Represents a void pointer.
kSize
Represents an unsigned integer that can store a pointer address.
kAssembly::kAssembly_RemoveUnloadedHandler
kStatus kAssembly_RemoveUnloadedHandler(kCallbackFx function, kPointer receiver)
Removes a callback that was registered with the kAssembly_AddUnloadedHandler function.
kInlineFx
#define kInlineFx(TYPE)
Inline method declaration helper.
Definition: kApiDef.h:26
kChar
Represents a single unit (byte) in a UTF-8 character.
kAssembly::kAssembly_Name
const kChar * kAssembly_Name(kAssembly assembly)
Gets the assembly name.
Definition: kAssembly.h:213
kAssembly::kAssembly_RemoveLoadHandler
kStatus kAssembly_RemoveLoadHandler(kCallbackFx function, kPointer receiver)
Removes a callback that was registered with the kAssembly_AddLoadHandler function.
kAssembly::kAssembly_DependencyAt
kAssembly kAssembly_DependencyAt(kAssembly assembly, kSize index)
Gets the assembly dependency at the specified index.
Definition: kAssembly.h:295
kAssembly::kAssembly_Find
kStatus kAssembly_Find(const kChar *name, kAssembly *assembly)
Finds an assembly by name.
kObj
#define kObj(TypeName_T, T_object)
Declares a local "obj" (this-pointer) variable and initializes it from a type-checked object handle...
Definition: kApiDef.h:2923
kAssembly::kAssembly_AddUnloadHandler
kStatus kAssembly_AddUnloadHandler(kCallbackFx function, kPointer receiver)
Adds a callback to be notified just prior to unloading an assembly.
kAssembly::kAssembly_AddUnloadedHandler
kStatus kAssembly_AddUnloadedHandler(kCallbackFx function, kPointer receiver)
Adds a callback to be notified after unloading an assembly.
kAssembly::kAssembly_Enumerate
kStatus kAssembly_Enumerate(kArrayList assemblies)
Gets a list of the currently-loaded assemblies.
kApiDef.h
Core Zen type declarations.
kAssembly::kAssembly_FindDerivedTypes
kStatus kAssembly_FindDerivedTypes(kAssembly assembly, kType base, kArrayList types)
Finds all types that descend from the specified base.
kCallbackFx
kStatus(kCall * kCallbackFx)(kPointer receiver, kPointer sender, void *args)
Callback signature for a generic event handler.
Definition: kApiDef.h:1737
kAssembly::kAssembly_TypeCount
kSize kAssembly_TypeCount(kAssembly assembly)
Gets the number of types in an assembly.
Definition: kAssembly.h:227
kType
Represents metadata about a type (class, interface, or value).
kArrayList
Represents a list implemented with a dynamic array.
kAssert
#define kAssert(EXPRESSION)
Aborts execution if EXPRESSION is kFALSE.
Definition: kApiDef.h:751
kAssembly::kAssembly_FindType
kStatus kAssembly_FindType(kAssembly assembly, const kChar *name, kType *type)
Finds a type by name.
kVersion
Represents a version number.
kStatus
Represents an error code.
kAssembly::kAssembly_AddLoadHandler
kStatus kAssembly_AddLoadHandler(kCallbackFx function, kPointer receiver)
Adds a callback to be notified when a new assembly is loaded.
kAssembly::kAssembly_TypeAt
kType kAssembly_TypeAt(kAssembly assembly, kSize index)
Gets the type at a particular index within an assembly.
Definition: kAssembly.h:242
kAssembly::kAssembly_DependencyCount
kSize kAssembly_DependencyCount(kAssembly assembly)
Gets the count of assembly dependencies.
Definition: kAssembly.h:280
kAssembly::kAssembly_Version
kVersion kAssembly_Version(kAssembly assembly)
Gets the assembly version.
Definition: kAssembly.h:185