Home Reference Source Test
public class | source

MdSeedRunner

mongoose-data-seed runner

Static Member Summary

Static Public Members
public static

MdSeedRunner operations constants

Constructor Summary

Public Constructor
public

constructor(connect: Function<Promise>, dropdb: Function<Promise>, seedersList: Map<string, Function>)

Creates MdSeedRunner

Static Public Members

public static operations: Object source

MdSeedRunner operations constants

Properties:

NameTypeAttributeDescription
START string

MdSeedRunner starts.

SUCCESS string

MdSeedRunner succeed.

ERROR string

MdSeedRunner finished with an error.

Public Constructors

public constructor(connect: Function<Promise>, dropdb: Function<Promise>, seedersList: Map<string, Function>) source

Creates MdSeedRunner

Params:

NameTypeAttributeDescription
connect Function<Promise>

Connect to mongodb implementation

dropdb Function<Promise>

Drop/Clear the database implementation

seedersList Map<string, Function>

key=Seeder name | value=Seeder implementation