mirror of
https://github.com/NuSkooler/enigma-bbs.git
synced 2025-06-05 04:07:23 +02:00
Pardon the noise. More tab to space conversion!
This commit is contained in:
parent
c3635bb26b
commit
1d8be6b014
128 changed files with 8017 additions and 8017 deletions
|
@ -1,16 +1,16 @@
|
|||
/* jslint node: true */
|
||||
'use strict';
|
||||
|
||||
var events = require('events');
|
||||
var assert = require('assert');
|
||||
var _ = require('lodash');
|
||||
var events = require('events');
|
||||
var assert = require('assert');
|
||||
var _ = require('lodash');
|
||||
|
||||
module.exports = MailPacket;
|
||||
|
||||
function MailPacket(options) {
|
||||
events.EventEmitter.call(this);
|
||||
|
||||
// map of network name -> address obj ( { zone, net, node, point, domain } )
|
||||
// map of network name -> address obj ( { zone, net, node, point, domain } )
|
||||
this.nodeAddresses = options.nodeAddresses || {};
|
||||
}
|
||||
|
||||
|
@ -18,19 +18,19 @@ require('util').inherits(MailPacket, events.EventEmitter);
|
|||
|
||||
MailPacket.prototype.read = function(options) {
|
||||
//
|
||||
// options.packetPath | opts.packetBuffer: supplies a path-to-file
|
||||
// or a buffer containing packet data
|
||||
// options.packetPath | opts.packetBuffer: supplies a path-to-file
|
||||
// or a buffer containing packet data
|
||||
//
|
||||
// emits 'message' event per message read
|
||||
// emits 'message' event per message read
|
||||
//
|
||||
assert(_.isString(options.packetPath) || Buffer.isBuffer(options.packetBuffer));
|
||||
};
|
||||
|
||||
MailPacket.prototype.write = function(options) {
|
||||
//
|
||||
// options.messages[]: array of message(s) to create packets from
|
||||
// options.messages[]: array of message(s) to create packets from
|
||||
//
|
||||
// emits 'packet' event per packet constructed
|
||||
// emits 'packet' event per packet constructed
|
||||
//
|
||||
assert(_.isArray(options.messages));
|
||||
};
|
Loading…
Add table
Add a link
Reference in a new issue