Import dotnetDBF for error handling.

This commit is contained in:
Patrick Fic
2022-02-11 15:06:05 -08:00
parent 991ad38839
commit f32c149bae
75 changed files with 5585 additions and 7 deletions

37
dotnetdbf/DBTHeader.cs Normal file
View File

@@ -0,0 +1,37 @@
using System;
using System.Collections.Generic;
using System.IO;
using System.Text;
namespace DotNetDBF
{
public class DBTHeader
{
public const byte FieldTerminator = 0x1A;
private int _nextBlock; /* 0-3*/
private byte _version = 0x03;
internal int NextBlock
{
get => _nextBlock;
set => _nextBlock = value;
}
internal byte Version
{
get => _version;
set => _version = value;
}
internal void Write(BinaryWriter dataOutput)
{
dataOutput.Write(_nextBlock);
dataOutput.Write(new byte[12]);
dataOutput.Write(_version);
dataOutput.Write(new byte[495]);
}
}
}