Table of Contents

Class MockComputationCollection

Namespace
NMF.Transformations.Tests
Assembly
NMF.Transformations.dll

Represents a collection of computations used by the mocked context

public class MockComputationCollection : ObservableCollection<ITraceEntry>, IList<ITraceEntry>, ICollection<ITraceEntry>, IReadOnlyList<ITraceEntry>, IReadOnlyCollection<ITraceEntry>, IEnumerable<ITraceEntry>, IList, ICollection, IEnumerable, INotifyCollectionChanged, INotifyPropertyChanged
Inheritance
MockComputationCollection
Implements
Inherited Members

Constructors

MockComputationCollection(MockContext)

Creates a new mock computation collection for the given mocked context

public MockComputationCollection(MockContext context)

Parameters

context MockContext

The mock context in which to create the computation collection

Methods

Add(GeneralTransformationRule, object[])

Creates a computation mock for the given transformation rule with the given input and the given context and adds the computation to the context

public MockComputation Add(GeneralTransformationRule transformationRule, object[] input)

Parameters

transformationRule GeneralTransformationRule

The transformation rule for this computation mock

input object[]

The input for this computation

Returns

MockComputation

The computation mock

Add<TIn>(GeneralTransformationRule<TIn>, TIn)

Creates a computation mock for the given transformation rule with the given input and the given context and adds the computation to the context

public MockComputation Add<TIn>(GeneralTransformationRule<TIn> transformationRule, TIn input) where TIn : class

Parameters

transformationRule GeneralTransformationRule<TIn>

The transformation rule for this computation mock

input TIn

The input for this computation

Returns

MockComputation

The computation mock

Type Parameters

TIn

Add<TOut>(TransformationRuleBase<TOut>, object[], TOut)

Creates a computation mock for the given transformation rule with the given input and the given context and adds the computation to the context

public MockComputation Add<TOut>(TransformationRuleBase<TOut> transformationRule, object[] input, TOut output) where TOut : class

Parameters

transformationRule TransformationRuleBase<TOut>

The transformation rule for this computation mock

input object[]

The input for this computation

output TOut

The output of the mock computation

Returns

MockComputation

The computation mock

Type Parameters

TOut

Add<TIn1, TIn2>(GeneralTransformationRule<TIn1, TIn2>, TIn1, TIn2)

Creates a computation mock for the given transformation rule with the given input and the given context and adds the computation to the context

public MockComputation Add<TIn1, TIn2>(GeneralTransformationRule<TIn1, TIn2> transformationRule, TIn1 input1, TIn2 input2) where TIn1 : class where TIn2 : class

Parameters

transformationRule GeneralTransformationRule<TIn1, TIn2>

The transformation rule for this computation mock

input1 TIn1

The first input for this computation

input2 TIn2

The second input for this computation

Returns

MockComputation

The computation mock

Type Parameters

TIn1
TIn2

Add<TIn, TOut>(TransformationRuleBase<TIn, TOut>, TIn, TOut)

Creates a computation mock for the given transformation rule with the given input and the given context and adds the computation to the context

public MockComputation Add<TIn, TOut>(TransformationRuleBase<TIn, TOut> transformationRule, TIn input, TOut output) where TIn : class where TOut : class

Parameters

transformationRule TransformationRuleBase<TIn, TOut>

The transformation rule for this computation mock

input TIn

The input for this computation

output TOut

The output for the mock computation

Returns

MockComputation

The computation mock

Type Parameters

TIn
TOut

Add<TIn1, TIn2, TOut>(TransformationRuleBase<TIn1, TIn2, TOut>, TIn1, TIn2, TOut)

Creates a computation mock for the given transformation rule with the given input and the given context and adds the computation to the context

public MockComputation Add<TIn1, TIn2, TOut>(TransformationRuleBase<TIn1, TIn2, TOut> transformationRule, TIn1 input1, TIn2 input2, TOut output) where TIn1 : class where TIn2 : class where TOut : class

Parameters

transformationRule TransformationRuleBase<TIn1, TIn2, TOut>

The transformation rule for this computation mock

input1 TIn1

The first input for this computation

input2 TIn2

The second input for this computation

output TOut

The output of the mock computation

Returns

MockComputation

The computation mock

Type Parameters

TIn1
TIn2
TOut