header.go
func (f HeaderExtension) EntrySize() int {
	// Length of the name includes a null terminator
	// the 4 * 5 is 4 bytes (uint32) for the 5 fields
	baseSize := f.FileEntry.EntrySize()

	for key, val := range f.ExtendedFields {
		// + 2 for the null terminator for each key/val
		baseSize += len(key) + len(val) + 2
	}

	// There's a null terminator at the end of the block
	return baseSize + 1
}
func (f HeaderExtension) EntrySize() int {
	// Length of the name includes a null terminator
	// the 4 * 5 is 4 bytes (uint32) for the 5 fields
	baseSize := f.FileEntry.EntrySize()

	for key, val := range f.ExtendedFields {
		// + 2 for the null terminator for each key/val
		baseSize += len(key) + len(val) + 2
	}

	// There's a null terminator at the end of the block
	return baseSize + 1
}
func ( f HeaderExtension ) EntrySize ( ) int { // Length of the name includes a null terminator // the 4 * 5 is 4 bytes (uint32) for the 5 fields baseSize := f . FileEntry . EntrySize ( ) for key , val := range f . ExtendedFields { // + 2 for the null terminator for each key/val baseSize += len ( key ) + len ( val ) + 2 } // There's a null terminator at the end of the block return baseSize + 1 }
// Gets the length of the entry block
Gets the length of the entry block