From 1bcba20a115079dc3dd18a0d6073a989e897c8dd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dominik=20Pant=C5=AF=C4=8Dek?= Date: Mon, 27 Mar 2023 22:31:52 +0200 Subject: [PATCH] Start documenting the member-record module. --- MODULES.md | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) diff --git a/MODULES.md b/MODULES.md index e7cf355..1763300 100644 --- a/MODULES.md +++ b/MODULES.md @@ -60,6 +60,41 @@ action is required. ### Member Record +This module encapsulates the data structure representing a single +member record. + + (make-member-record file-name file-path symlinks . args) + +* ```file-name``` - a symbol representing the primary filename +* ```file-path``` - a string representing the path to the file +* ```symlinks``` - a list of symbols representing symlinks +* ```args``` - optional keyword arguments + +Creates a new member record dictionary. The three mandatory arguments +are stored under respective keys and any keyword arguments are stored +as keys obtained by converting the keyword to symbol with values +following the keyword. + +The ```'id``` key is filled with any four-digit file-name or symlink +converted to a number. Preferably the four-digit symbol should be the +file-name but it is not required. + + (member-record-input-file mr) + +* ```mr``` - a member record structure + +Returns an open file port to given member record underlying file. This +function should be used by the parser to get the member file contents. + + (member-record-set mr . args) + +* ```mr``` - a member record structure +* ```args``` - optional keyword arguments + +Any keyword arguments are stored in the member record dictionary as +keys obtained by converting the keyword to symbol with values +following the keyword. + ### Member Parser ### Member Info Printer