Difference between revisions of "Truxton C API"

From truxwiki.com
Jump to navigation Jump to search
Line 32: Line 32:
 
* [[truxton_child_file_destroy]] - Destroys a file object
 
* [[truxton_child_file_destroy]] - Destroys a file object
 
* [[truxton_child_file_clear]] - Returns a file object to an initial state of all zeroes
 
* [[truxton_child_file_clear]] - Returns a file object to an initial state of all zeroes
* [[truxton_child_file_get_id]] - Retrieves the unique id of a file
+
* [[truxton_child_file_get_id]] - Retrieves the [https://en.wikipedia.org/wiki/Universally_unique_identifier GUID] of the child file
* [[truxton_child_file_set_id]] - Sets the unique id of a file
+
* [[truxton_child_file_set_id]] - Sets the [https://en.wikipedia.org/wiki/Universally_unique_identifier GUID] of the child file
* [[truxton_child_file_get_parent_id]] -  
+
* [[truxton_child_file_get_parent_id]] - Retrieves the [https://en.wikipedia.org/wiki/Universally_unique_identifier GUID] of the parent file
* [[truxton_child_file_set_parent_id]] -  
+
* [[truxton_child_file_set_parent_id]] - Sets the [https://en.wikipedia.org/wiki/Universally_unique_identifier GUID] of the parent of the child
* [[truxton_child_file_get_media_id]] -  
+
* [[truxton_child_file_get_media_id]] - Retrieves the [https://en.wikipedia.org/wiki/Universally_unique_identifier GUID] of the media this child belongs to
* [[truxton_child_file_set_media_id]] -  
+
* [[truxton_child_file_set_media_id]] - Sets the [https://en.wikipedia.org/wiki/Universally_unique_identifier GUID] of the media this child belongs to
* [[truxton_child_file_get_name]] -  
+
* [[truxton_child_file_get_name]] - Retrieves the name of the file
* [[truxton_child_file_set_name]] -  
+
* [[truxton_child_file_set_name]] - Sets the name of the file
* [[truxton_child_file_get_path]] -  
+
* [[truxton_child_file_get_path]] - Retrieves the path of the file
* [[truxton_child_file_set_path]] -  
+
* [[truxton_child_file_set_path]] - Sets the path of the file
* [[truxton_child_file_get_hash]] -  
+
* [[truxton_child_file_get_hash]] - Retrieves the [https://en.wikipedia.org/wiki/MD5 MD5] hash (digital fingerprint) of the file's contents
* [[truxton_child_file_get_number_of_children]] -  
+
* [[truxton_child_file_get_number_of_children]] - Retrieves the number of child files of this file
* [[truxton_child_file_set_number_of_children]] -  
+
* [[truxton_child_file_set_number_of_children]] - Sets the number of child files of this file
* [[truxton_child_file_get_created]] -  
+
* [[truxton_child_file_get_created]] - Retrieves the date and time of when the file was created
* [[truxton_child_file_set_created]] -  
+
* [[truxton_child_file_set_created]] - Sets the date and time of when the file was created
* [[truxton_child_file_get_accessed]] -  
+
* [[truxton_child_file_get_accessed]] - Retrieves the date and time of when the file was accessed
* [[truxton_child_file_set_accessed]] -  
+
* [[truxton_child_file_set_accessed]] - Sets the date and time of when the file was accessed
* [[truxton_child_file_get_modified]] -  
+
* [[truxton_child_file_get_modified]] - Retrieves the date and time of when the file was modified (last written to)
* [[truxton_child_file_set_modified]] -  
+
* [[truxton_child_file_set_modified]] - Sets the date and time of when the file was modified (last written to)
* [[truxton_child_file_get_size]] -  
+
* [[truxton_child_file_get_size]] - Retrieves the size of the file, in bytes, as reported by the operating system
* [[truxton_child_file_set_size]] -  
+
* [[truxton_child_file_set_size]] - Sets the size of the file, in bytes, as reported by the operating system
* [[truxton_child_file_get_origin]] -  
+
* [[truxton_child_file_get_origin]] - Retrieves the [[Origin | origin]] of the file
* [[truxton_child_file_set_origin]] -  
+
* [[truxton_child_file_set_origin]] - Sets the [[Origin | origin]] of the file
* [[truxton_child_file_get_content_status]] -  
+
* [[truxton_child_file_get_content_status]] - Retrieves the [[Content Status | status]] of the contents of the file
* [[truxton_child_file_set_content_status]] -  
+
* [[truxton_child_file_set_content_status]] - Sets the [[Content Status | status]] of the contents of the file
* [[truxton_child_file_get_truxton]] -  
+
* [[truxton_child_file_get_truxton]] - Retrieves the instance of Truxton this child belongs to
* [[truxton_child_file_begin_write]] -  
+
* [[truxton_child_file_begin_write]] - Prepares Truxton for writing contents to be associated with this file
* [[truxton_child_file_end_write]] -  
+
* [[truxton_child_file_end_write]] - Tells Truxton to finish writing contents
* [[truxton_child_file_write]] -  
+
* [[truxton_child_file_write]] - Gives Truxton bytes to store as the file contents
* [[truxton_child_file_save]] -  
+
* [[truxton_child_file_save]] - Commits data to the database
* [[truxton_child_file_set_type]] -  
+
* [[truxton_child_file_set_type]] - Sets the [[File Types Supported | type]] of the file
* [[truxton_child_file_get_type]] -  
+
* [[truxton_child_file_get_type]] - Retrieves the [[File Types Supported | type]] of the file
* [[truxton_child_file_set_attributes]] -  
+
* [[truxton_child_file_set_attributes]] - Sets the attributes of the file
* [[truxton_child_file_get_attributes]] -  
+
* [[truxton_child_file_get_attributes]] - Retrieves the attributes of the file
* [[truxton_child_file_set_disk_offset]] -  
+
* [[truxton_child_file_set_disk_offset]] - Sets the physical disk offset of the first byte of contents
* [[truxton_child_file_get_disk_offset]] -  
+
* [[truxton_child_file_get_disk_offset]] - Retrieves the physical disk offset of the first byte of contents
* [[truxton_child_file_get_entropy]] -
+
* [[truxton_child_file_get_entropy]] - Retrieves the [https://en.wikipedia.org/wiki/Entropy_(information_theory) entropy] of the file contents

Revision as of 13:49, 20 May 2020

Truxton functionality is exposed to the C programming world as a DLL named TruxtonCAPI.dll in the C:\Program Files\Truxton\SDK folder. This DLL can be called from any programming language that has the ability to make operating system calls.

Philosophy

The API is considered to be "flat" in that only sixty-four bit integers and ASCII character strings are used in the interface. This was chosen to make it easy for other languages to interface to. The coding convention is all lower case names with underscores separating words. Truxton is a member of the east const posse.

API Groups

The API is broken down into the different areas of Truxton.

Initialization

ETL Functions

Child Files

A child file is one that you have created and need to save in Truxton.