Skip to content

Commit

Permalink
Implements export of 43235634 format. Merge branch 'utility_tag2json'.
Browse files Browse the repository at this point in the history
  • Loading branch information
evgenykislov committed Jun 9, 2024
1 parent 4539e75 commit 1f3435d
Show file tree
Hide file tree
Showing 12 changed files with 25,417 additions and 2 deletions.
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -55,5 +55,6 @@ Makefile
*.qmake.stash

test_utils/
build-test_utils-*/
build-*/
tests/*.txt
*.txt.user
2 changes: 1 addition & 1 deletion doc/Формат хранения.txt
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
Формат файла:
----
0x0000 - Заголовок:
+0x00 (4 байт) - MagicWord (0x34562343), остальное - нули
+0x00 (4 байт) - MagicWord: 0 - 43h; 1 - 23h; 2 - 56h; 3 - 35h (числовые поля big-endian) / 0 - 43h; 1 - 23h; 2 - 56h; 3 - 34h (числовые поля little-endian)
+0x04 (4 байт) - падинг (0)
+0x08 (8 байт) - позиция таблицы тегов (абсолютное смещение от начала файла). Выровнено на 256 байт.
+0x10 (8 байт) - позиция таблицы с файловыми блоками. Выровнено на 256 байт.
Expand Down
29 changes: 29 additions & 0 deletions doc/Формат экспорта.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
Экспорт в json

Для выдачи во внешний формат используется json следующего вида:

{
"settings": {
"tagrecordsize": 256,
"maxtags": 64,
"fileblocksize": 256,
},
"tags": [
{
"name": "tagname001"
},
{
"name": "tagname002"
}
],
"files": [
{
"name": "filename001",
"target": "linktofile001",
"tags": [
"tagname001",
"tagname002"
]
}
]
}
Loading

0 comments on commit 1f3435d

Please sign in to comment.