Since: API Level v2
public final class

DataDesignPlugin

com.webmbt.plugin.DataDesignPlugin

Class Overview

Combinatorial data design plugin.

Copyright © 2008 - 2017 TestOptimal LLC. All Rights Reserved.

Summary

Public Constructors
DataDesignPlugin()
Public Methods
String[] batchRandBool(String batchSize_p)
generates a series of random true/false with equal chance of being true or false.
String[] batchRandBool(String batchSize_p, String trueProb_p)
generates a series of random true/false according to the specified probability to be true.
String[] batchRandBoolByDist(String... strings)
generates a series of random true/false according to the specified random distribution (default uniform distribution).
String[] batchRandByDist(String... strings)
generates a series of random numbers using the specified random distribution.
String[] batchRandNum(String... strings)
generates a series of random numbers within the specified start/end interval@return
String[] boundaryInt(String... strings)
generates a list of integers to test the boundary of the integer list passed in.

Public Constructors

public DataDesignPlugin ()

Since: API Level v2

Public Methods

public String[] batchRandBool (String batchSize_p)

Since: API Level v2

generates a series of random true/false with equal chance of being true or false.

For example, $batchRandBool('5') to generate 5 strings of true/false with 50% probably of being true.

Returns
  • a series of true/false strings
Throws
Exception

public String[] batchRandBool (String batchSize_p, String trueProb_p)

Since: API Level v2

generates a series of random true/false according to the specified probability to be true. For example, $batchRandBoolByProb('5', '0.2') to generate 5 strings of true/false with 0.2 probably of being true.

Returns
  • a series of true/false strings
Throws
Exception

public String[] batchRandBoolByDist (String... strings)

Since: API Level v2

generates a series of random true/false according to the specified random distribution (default uniform distribution). This is based on random sampling from the probability distribution specified.

For example, $randBoolBatch('5', '2.3', 'randNormal', '4', '3') to generate 5 strings of true/false according normal distribution with mean of 4 and standard deviation of 3 and values <= 2.3 will evaluate to true and false otherwise.

Returns
  • a series of true/false strings
Throws
Exception

public String[] batchRandByDist (String... strings)

Since: API Level v2

generates a series of random numbers using the specified random distribution.

For example: $batchRandByDist('5','randNormal','7','3') to generate 5 random numbers according to "normal/gaussian" distribution with the mean value of 7 and standard deviation of 3.
$batchRandByDist('10','randEmail') to generate 10 random email addresses.

Returns
  • a series of random numbers
Throws
Exception

public String[] batchRandNum (String... strings)

Since: API Level v2

generates a series of random numbers within the specified start/end interval@return

Throws
Exception

public String[] boundaryInt (String... strings)

Since: API Level v2

generates a list of integers to test the boundary of the integer list passed in. For example, $boundaryInt('10') to generate integers: 9,10,11 and $boundaryInt('10', '50') to generate integers: 9,10,11,49,50,51.

Parameters
strings list of integer strings
Returns
  • a list of integers to cover the boundaries of the integers passed in.