added gitlab ci

This commit is contained in:
2016-09-25 14:00:16 +02:00
parent 361c7ecc2f
commit 8653abfce1
16 changed files with 164 additions and 1 deletions

23
ts/index.ts Normal file
View File

@ -0,0 +1,23 @@
import * as plugins from './smartstream.plugins'
export interface IErrorFunction {
(err): number
}
export class Smartstream {
streamArray = []
errorFunction: IErrorFunction = null
constructor(streamArrayArg: any[]){
this.streamArray = streamArrayArg
}
onError(errorFunctionArg: IErrorFunction) {
this.errorFunction = errorFunctionArg
}
run() {
let combinedStream = plugins.streamCombiner2.obj(this.streamArray)
if (this.errorFunction !== null) {
combinedStream.on('error', this.errorFunction)
}
return combinedStream
}
}

View File

@ -0,0 +1,3 @@
import 'typings-global'
export import q = require('q')
export let streamCombiner2 = require('stream-combiner2')