libaaruformat 1.0
Aaru Data Preservation Suite - Format Library
Loading...
Searching...
No Matches
tape.h
Go to the documentation of this file.
1/*
2 * This file is part of the Aaru Data Preservation Suite.
3 * Copyright (c) 2019-2025 Natalia Portillo.
4 *
5 * This library is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU Lesser General Public License as
7 * published by the Free Software Foundation; either version 2.1 of the
8 * License, or (at your option) any later version.
9 *
10 * This library is distributed in the hope that it will be useful, but
11 * WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * Lesser General Public License for more details.
14 *
15 * You should have received a copy of the GNU Lesser General Public
16 * License along with this library; if not, see <http://www.gnu.org/licenses/>.
17 * */
18
73
74#ifndef LIBAARUFORMAT_TAPE_H
75#define LIBAARUFORMAT_TAPE_H
76
77#include <stdint.h>
78
79#pragma pack(push, 1)
80
133typedef struct TapeFileEntry
134{
135 uint32_t File;
137 uint8_t Partition;
139 uint64_t FirstBlock;
141 uint64_t
145
237typedef struct TapeFileHeader
238{
239 uint32_t identifier;
241 uint32_t entries;
243 uint64_t length;
245 uint64_t crc64;
248
319typedef struct TapePartitionEntry
320{
321 uint8_t Number;
323 uint64_t FirstBlock;
325 uint64_t LastBlock;
329
441{
442 uint32_t identifier;
444 uint8_t entries;
446 uint64_t length;
448 uint64_t crc64;
451
452#pragma pack(pop)
453
454#endif // LIBAARUFORMAT_TAPE_H
Describes a single logical file on a tape medium.
Definition tape.h:134
uint32_t File
File number (unique within the partition).
Definition tape.h:135
uint64_t LastBlock
Last block of the file (inclusive).
Definition tape.h:142
uint64_t FirstBlock
First block of the file (inclusive).
Definition tape.h:139
uint8_t Partition
Partition number containing this file.
Definition tape.h:137
Header for a tape file metadata block containing file layout information.
Definition tape.h:238
uint32_t entries
Number of file entries following this header.
Definition tape.h:241
uint32_t identifier
Block type identifier.
Definition tape.h:239
uint64_t crc64
CRC64-ECMA checksum of the entry data.
Definition tape.h:245
uint64_t length
Size of entry data in bytes (excluding this header).
Definition tape.h:243
Describes a single physical partition on a tape medium.
Definition tape.h:320
uint64_t LastBlock
Last block in the partition (inclusive).
Definition tape.h:325
uint64_t FirstBlock
First block in the partition (inclusive).
Definition tape.h:323
uint8_t Number
Partition number (unique identifier for this partition).
Definition tape.h:321
Header for a tape partition metadata block containing partition layout information.
Definition tape.h:441
uint64_t crc64
CRC64-ECMA checksum of the entry data.
Definition tape.h:448
uint64_t length
Size of entry data in bytes (excluding this header).
Definition tape.h:446
uint8_t entries
Number of partition entries following this header.
Definition tape.h:444
uint32_t identifier
Block type identifier.
Definition tape.h:442