this.ready = false;
this.records = [];
this.source = kwargs.source;
+ this.delimiter = kwargs.delimiter
this.current_record = 0;
if (this.source) this.ready = true;
} else if (this.source.match(/^\s*</)) { // this is xml text
this.source = dojox.xml.parser.parse( this.source );
this.parse();
- } else { // must be a breaker doc. split on blank lines
+ } else { // must be a marcbreaker doc. split on blank lines
this.source = this.source.split(/^$/);
- this.type = 'breaker';
+ this.type = 'marcbreaker';
}
},
if (chunk) {
var args = {};
args[this.type] = chunk;
+ if (this.delimiter) args.delimiter = this.delimiter;
return new MARC.Record(args);
}