File tree Expand file tree Collapse file tree 2 files changed +36
-0
lines changed Expand file tree Collapse file tree 2 files changed +36
-0
lines changed Original file line number Diff line number Diff line change @@ -66,6 +66,24 @@ import * as utils from './utils';
66
66
* storing the actual value. These are the currently supported keys for
67
67
* the extended metadata:
68
68
* - path (corresponding to file path if it is longer than 255 characters)
69
+ *
70
+ * The high-level diagram of a tar file looks like the following.
71
+ * - [File header]
72
+ * - [Data]
73
+ * - [Data]
74
+ * - [Extended header]
75
+ * - [Data]
76
+ * - [File header]
77
+ * - [Data]
78
+ * - [Data]
79
+ * - [Directory header]
80
+ * - [Null chunk]
81
+ * - [Null chunk]
82
+ *
83
+ * A file header preceedes file data. A directory header has no data. An
84
+ * extended header is the same as a file header, but it has differnet metadata
85
+ * than one, and must be immediately followed by either a file or a directory
86
+ * header. Two null chunks are always at the end, marking the end of archive.
69
87
*/
70
88
class Generator {
71
89
protected state : GeneratorState = GeneratorState . HEADER ;
Original file line number Diff line number Diff line change @@ -61,6 +61,24 @@ import * as utils from './utils';
61
61
* storing the actual value. These are the currently supported keys for
62
62
* the extended metadata:
63
63
* - path (corresponding to file path if it is longer than 255 characters)
64
+ *
65
+ * The high-level diagram of a tar file looks like the following.
66
+ * - [File header]
67
+ * - [Data]
68
+ * - [Data]
69
+ * - [Extended header]
70
+ * - [Data]
71
+ * - [File header]
72
+ * - [Data]
73
+ * - [Data]
74
+ * - [Directory header]
75
+ * - [Null chunk]
76
+ * - [Null chunk]
77
+ *
78
+ * A file header preceedes file data. A directory header has no data. An
79
+ * extended header is the same as a file header, but it has differnet metadata
80
+ * than one, and must be immediately followed by either a file or a directory
81
+ * header. Two null chunks are always at the end, marking the end of archive.
64
82
*/
65
83
class Parser {
66
84
protected state : ParserState = ParserState . HEADER ;
You can’t perform that action at this time.
0 commit comments