]> gitweb.hhaalo.de Git - discspan.git/commitdiff
add: description in header files
authorBastian Dehn <hhaalo@arcor.de>
Sun, 15 Aug 2021 08:45:34 +0000 (10:45 +0200)
committerBastian Dehn <hhaalo@arcor.de>
Sun, 15 Aug 2021 08:45:34 +0000 (10:45 +0200)
libs/spandisc/include/filehandler.h
libs/spandisc/include/libspandisc.h
libs/spandisc/include/logic.h
libs/spandisc/include/splitter.h

index 04bd2ee02b39708338c1538ff6a29f12f638a608..6502170ee497124cc53e4d625edebf664784b88e 100644 (file)
@@ -1,8 +1,20 @@
 #ifndef _FILEHANDLER_H
 #define _FILEHANDLER_H
 
+/**
+ * Read a text file with file pathes into medium_t struct
+ *
+ * @param input is the input file path
+ * @param pointer to an empty medium_t struct
+ */
 void read_input_file(const char *input, medium_t *srcdata);
 
+/**
+ * Write a text file with file pathes from medium_t struct
+ *
+ * @param output is the file name
+ * @param disc is the struct with file pathes
+ */
 void write_output_file(const char *output, medium_t disc);
 
 #endif
index 5c07e2215bffecf189ef4ba75bc7f7ad89a00fa1..8d0468a34e4b214470487dd205f9e18e28fd6799 100644 (file)
@@ -1,9 +1,13 @@
 #ifndef LIBSPANDISC_H
 #define LIBSPANDISC_H
 
+// contains struct types
 #include "spandisc.h"
+// contains spanning logic with read and write file
 #include "logic.h"
+// read and write a text file
 #include "filehandler.h"
+// contains splitting logic
 #include "splitter.h"
 
 #endif
index e7e4740d6576c2f4d6cf1398084f4e4ac0f029b7..cf5ca92291a589fef14b07d913303afe74d3ac43 100644 (file)
@@ -1,8 +1,24 @@
 #ifndef _LOGIC_H
 #define _LOGIC_H
 
+/**
+ * Event pointer to method execute by the writing file.
+ * This Method is called by span
+ *
+ * @param output is the file name
+ * @param disc is the disc struct
+ */
 void (*status_print)(const char *output, medium_t disc);
 
+/**
+ * Split file pathes from input file with split size into seperated
+ * output files. Output files contains the pathes fit on a media. Output files
+ * name generate with output prefix and four digit number.
+ *
+ * @param input path to the input text file
+ * @param output prefix of output files
+ * @param split size to split in bytes
+ */
 void span(const char *input, const char *output, unsigned long long split);
 
 #endif
index e7f2ca7729589d8891c910f41071f67700afd1b5..ca834de3a58fd955107b80db141d1ddb33c35f43 100644 (file)
@@ -4,8 +4,31 @@
 void free_medium(medium_t *medium);
 void free_collection(collection_t *col);
 
+/**
+ * Calc a medium from srcdata and shrink srcdata struct.
+ *
+ * @param srcdata struct with all pathes
+ *
+ * @return one splitted medium
+ */
 medium_t splitter(medium_t *srcdata);
+
+/**
+ * Calc all files to big to split.
+ *
+ * @param srcdata struct with all pathes
+ *
+ * @return medium with pathes can not split
+ */
 medium_t ignore(medium_t *srcdata);
+
+/**
+ * Calc all file pathes and make a medium collection
+ *
+ * @param srcdata with all file pathes
+ *
+ * @return collection with many mediums
+ */
 collection_t split_all(medium_t *srcdata);
 
 #endif