Go to the source code of this file.
|
KAPI b8 | kpackage_create_from_manifest (const asset_manifest *manifest, kpackage *out_package) |
|
KAPI b8 | kpackage_create_from_binary (u64 size, void *bytes, kpackage *out_package) |
|
KAPI void | kpackage_destroy (kpackage *package) |
|
KAPI kpackage_result | kpackage_asset_bytes_get (const kpackage *package, kname name, u64 *out_size, const void **out_data) |
|
KAPI kpackage_result | kpackage_asset_text_get (const kpackage *package, kname name, u64 *out_size, const char **out_text) |
|
KAPI const char * | kpackage_path_for_asset (const kpackage *package, kname name) |
|
KAPI const char * | kpackage_source_path_for_asset (const kpackage *package, kname name) |
|
KAPI b8 | kpackage_asset_bytes_write (kpackage *package, kname name, u64 size, const void *bytes) |
|
KAPI b8 | kpackage_asset_text_write (kpackage *package, kname name, u64 size, const char *text) |
|
KAPI b8 | kpackage_parse_manifest_file_content (const char *path, asset_manifest *out_manifest) |
|
KAPI void | kpackage_manifest_destroy (asset_manifest *manifest) |
|
◆ asset_manifest
◆ asset_manifest_asset
◆ asset_manifest_reference
A reference to another package in an asset manifest.
◆ kpackage
◆ kpackage_result
◆ kpackage_result
Enumerator |
---|
KPACKAGE_RESULT_SUCCESS | |
KPACKAGE_RESULT_ASSET_GET_FAILURE | |
KPACKAGE_RESULT_INTERNAL_FAILURE | |
◆ kpackage_asset_bytes_get()
◆ kpackage_asset_bytes_write()
◆ kpackage_asset_text_get()
◆ kpackage_asset_text_write()
◆ kpackage_create_from_binary()
KAPI b8 kpackage_create_from_binary |
( |
u64 |
size, |
|
|
void * |
bytes, |
|
|
kpackage * |
out_package |
|
) |
| |
◆ kpackage_create_from_manifest()
◆ kpackage_destroy()
◆ kpackage_manifest_destroy()
◆ kpackage_parse_manifest_file_content()
◆ kpackage_path_for_asset()
Attempts to retrieve the path string for the given asset within the provided package. NOTE: If found, returns a copy of the string (dynamically allocated) which must be freed by the caller.
- Parameters
-
package | A constant pointer to the package to search. |
name | The name of the asset to search for. |
- Returns
- A copy of the path string, if found. Otherwise 0/null.
◆ kpackage_source_path_for_asset()
KAPI const char* kpackage_source_path_for_asset |
( |
const kpackage * |
package, |
|
|
kname |
name |
|
) |
| |
Attempts to retrieve the source path string for the given asset within the provided package. NOTE: If found, returns a copy of the string (dynamically allocated) which must be freed by the caller.
- Parameters
-
package | A constant pointer to the package to search. |
name | The name of the asset to search for. |
- Returns
- A copy of the source path string, if found. Otherwise 0/null.