FireSync API
 All Classes Files Functions Variables Typedefs Friends Macros Modules Pages
kFsUtils.h
Go to the documentation of this file.
1 
8 #ifndef K_FIRESYNC_UTILS_H
9 #define K_FIRESYNC_UTILS_H
10 
11 #include <kFireSync/kFsDef.h>
12 #include <kFireSync/Utils/kInfo.h>
13 #include <kFireSync/kNodeDef.h>
14 
15 kBeginHeader()
16 
17 
25 typedef kStatus (kCall* kLoadStreamFx)(kObject* object, kStream stream, kAlloc allocator);
26 
34 typedef kStatus (kCall* kSaveStreamFx)(kObject object, kStream stream);
35 
52 kFsFx(kStatus) kLoadFromFile(kObject* object, const kChar* path, kLoadStreamFx loadFunction, kAlloc allocator);
53 
63 kFsFx(kStatus) kSaveToFile(kObject object, const kChar* path, kSaveStreamFx saveFunction);
64 
72 kFsFx(k32u) kCountBits32u(k32u value);
73 
86 kFsFx(kStatus) kFsUtils_FindPsProgram(const kChar* programName, kControllerType type, kBool isDebug, kChar* path, kSize capacity);
87 
88 
99 kFsFx(kStatus) kFindPlProgram(k32u configuration, kChar* path, kSize capacity, kVersion* version);
100 
112 kFsFx(kStatus) kFindPl2Program(k32u configuration, kDaughterboardModel model, kChar* path, kSize capacity, kVersion* version);
113 
114 kEndHeader()
115 
116 #include <kFireSync/Utils/kFsUtils.x.h>
117 
118 #endif
k32u kCountBits32u(k32u value)
Counts the number of bits that are set in a 32-bit unsigned integer.
Declares the kInfo family of structures.
kStatus(kCall * kLoadStreamFx)(kObject *object, kStream stream, kAlloc allocator)
Callback signature used with the kLoadFromFile function.
Definition: kFsUtils.h:25
Essential declarations related to FireSync nodes.
Essential API declarations for the kFireSync library.
Represents types of node controllers.
kStatus kFsUtils_FindPsProgram(const kChar *programName, kControllerType type, kBool isDebug, kChar *path, kSize capacity)
This function returns the fully qualified (absolute) path for a given program name based on the contr...
Represents model of daughterboard.
kStatus kLoadFromFile(kObject *object, const kChar *path, kLoadStreamFx loadFunction, kAlloc allocator)
Loads a file and parses a user-defined object from the file using the specified callback.
kStatus kFindPl2Program(k32u configuration, kDaughterboardModel model, kChar *path, kSize capacity, kVersion *version)
Gives the path and the version of a Pl2 file given a specific configuration and model.
kStatus kSaveToFile(kObject object, const kChar *path, kSaveStreamFx saveFunction)
Formats a user-defined object using the specified callback and saves the result to file...
kStatus kFindPlProgram(k32u configuration, kChar *path, kSize capacity, kVersion *version)
Gives the path and the version of a Pl file given a specific configuration.
kStatus(kCall * kSaveStreamFx)(kObject object, kStream stream)
Callback signature used with the kSaveToFile function.
Definition: kFsUtils.h:34