1.0.28 • Published 4 years ago

dbfstreammemo v1.0.28

Weekly downloads
6
License
MIT
Repository
github
Last release
4 years ago

MEMO SUPPORT ADDED FOR File type 48 'Visual FoxPro'

DBFStream

This is a stream base .dbf Parser Based on https://github.com/tamtakoe/node-dbf

How to Add

npm i dbfstreammemo

OR

yarn add dbfstreammemo

Usage

creat dbf stream:

@source: dbf file path / readable stream const dbf = dbfstream(source, encoding);

const dbfstream = require('dbfstreammemo');

var dbf = dbfstream('./test.dbf', 'utf-8');

get dbf file header:

dbf.on('header', header => {
  console.log(header);
});

get dbf file data:

dbf.on('readable', () => {
  console.log(stream.read());
});

//or flowing mode
dbf.on('data', (data) => {
    console.log(data);
});

get dbf file error

dbf.on('error', (err) => {
  console.log(err);
});
  • Due to how the parser is written, currently the only condition that emits an error is insufficient bytes in the header.

dbf file stream end:

dbf.on('end', () => {
    console.log('stream end');
});
1.0.28

4 years ago

1.0.27

4 years ago

1.0.26

4 years ago

1.0.25

4 years ago