hhp-xml
v0.3.0
Published
Poker HandHistory Parser for XML formatted histories.
Downloads
13
Readme
hhp-xml
Poker HandHistory Parser for XML formatted histories.
const fs = require('fs')
const { parseHands } = require('hhp-xml')
const xml = fs.readFileSync('iPokerHistory.xml', 'utf8')
const { parsedHands, errors, count } = parseHands(xml)
Installation
npm install hhp-xml
API
canParse
Determines if any of the parsers can parse the passed XML hand.
Parameters
xml
String to parse
Returns Boolean true
if it knows how to parse this xml
parseHands
Parses hands for Poker rooms that save them in xml format. Currently only iPoker is supported.
The structure of the returned hand objects is the same as for hhp.
Parameters
xml
String to parse
Returns object parsed hands and errors encountered: { parsedHands: Array, errors: Array, count: Number }
License
MIT