Home Reference Source Test Repository
public class | source

StepBuilder

Helper class to build Step objects.

Test:

Constructor Summary

Public Constructor
public

constructor(nodeFields: Array<string>, edgeFields: Array<string>, algorithmResult: AlgorithmResult)

Constructs a StepBuilder.

Member Summary

Public Members
public
public
public
public

step: *

Method Summary

Public Methods
public

addChange(object: Node | Edge, preValues: Object<string, *>, duringValues: Object<string, *>, postValues: Object<string, *>)

Add a Node or Edge and its values to the step.

public

Called when the step is completed.

public

newStep(description: string)

Begin building a new Step object.

Public Constructors

public constructor(nodeFields: Array<string>, edgeFields: Array<string>, algorithmResult: AlgorithmResult) source

Constructs a StepBuilder.

Params:

NameTypeAttributeDescription
nodeFields Array<string>

Array of names of Node fields that the algorithm has access to.

edgeFields Array<string>

Array of names of Edge fields that the algorithm has access to.

algorithmResult AlgorithmResult

AlgorithmResult object that the step will be stored in.

Test:

Public Members

public algorithmResult: * source

public edgeFields: * source

public nodeFields: * source

public step: * source

Public Methods

public addChange(object: Node | Edge, preValues: Object<string, *>, duringValues: Object<string, *>, postValues: Object<string, *>) source

Add a Node or Edge and its values to the step.

Params:

NameTypeAttributeDescription
object Node | Edge

Node or Edge object.

preValues Object<string, *>

Object containing field names and their respective values before the step.

duringValues Object<string, *>

Object containing field names and their respective values before the step.

postValues Object<string, *>

Object containing field names and their respective values after the step.

Test:

public completeStep() source

Called when the step is completed.

Test:

public newStep(description: string) source

Begin building a new Step object.

Params:

NameTypeAttributeDescription
description string

Description of the Step.

Test: