public class NWiseExtension extends Object implements CustomTagExtension<NWiseExtension.NWiseAction>
Modifier and Type | Class and Description |
---|---|
static class |
NWiseExtension.NWiseAction
A custom Action for the 'dg:nwise' tag inside models
|
Constructor and Description |
---|
NWiseExtension() |
Modifier and Type | Method and Description |
---|---|
List<Map<String,String>> |
expandTupleIntoTestCases(Set<String> tuple,
Map<String,String[]> variableDomains)
Expands a tuple of variable names into every combination of assignments to those variables
|
Class<NWiseExtension.NWiseAction> |
getTagActionClass()
Returns a class object representing the Action class handled by this class' pipelinePossibleStates logic
|
String |
getTagName()
Returns the name of this custom tag, as would be used in the model
|
String |
getTagNameSpace()
Returns the name space of this custom tag, as would be used in the model
|
List<Set<String>> |
makeNWiseTuples(String[] variables,
int nWise)
Produces all tuples of size n chosen from a list of variable names
|
List<Map<String,String>> |
pipelinePossibleStates(NWiseExtension.NWiseAction action,
List<Map<String,String>> possibleStateList)
Uses current variable assignments and info in an NWiseActionTag to expand on an n wise combinatorial set
|
List<Map<String,String>> |
produceNWise(int nWise,
String[] coVariables,
Map<String,String[]> variableDomains)
Finds all nWise combinations of a set of variables, each with a given domain of values
|
public Class<NWiseExtension.NWiseAction> getTagActionClass()
CustomTagExtension
getTagActionClass
in interface CustomTagExtension<NWiseExtension.NWiseAction>
public String getTagName()
CustomTagExtension
getTagName
in interface CustomTagExtension<NWiseExtension.NWiseAction>
public String getTagNameSpace()
CustomTagExtension
getTagNameSpace
in interface CustomTagExtension<NWiseExtension.NWiseAction>
public List<Set<String>> makeNWiseTuples(String[] variables, int nWise)
variables
- the list of variable names to make tuples ofnWise
- the size of the desired tuplespublic List<Map<String,String>> expandTupleIntoTestCases(Set<String> tuple, Map<String,String[]> variableDomains)
tuple
- a list of variablesvariableDomains
- a map defining the domain for each variablepublic List<Map<String,String>> produceNWise(int nWise, String[] coVariables, Map<String,String[]> variableDomains)
nWise
- the number of variables in each combinationcoVariables
- the varisblesvariableDomains
- the domainspublic List<Map<String,String>> pipelinePossibleStates(NWiseExtension.NWiseAction action, List<Map<String,String>> possibleStateList)
pipelinePossibleStates
in interface CustomTagExtension<NWiseExtension.NWiseAction>
action
- an NWiseAction ActionpossibleStateList
- a current list of possible states produced so far from expanding a model stateCopyright © 2016. All rights reserved.