public SingleOperandRangeLookup(TOperand from, TOperand to, ExecutionPathGroup executionPath, ExecutionPathGroup emptyGroup) { _executionPath = executionPath; _emptyGroup = emptyGroup; _minValue = ConvertOperand(from); _maxValue = ConvertOperand(to); }
private static ExecutionPathGroup[] CreateFastLookupArray() { var fastLookup = new ExecutionPathGroup[InstructionsRange.Maximum + 1]; for (var i = 0; i < fastLookup.Length; i++) { fastLookup[i] = ExecutionPathGroup.Empty; } return(fastLookup); }
public DictionaryLookup(IEnumerable <ExecutionPathGroup> executionPaths, ExecutionPathGroup emptyGroup) { _emptyGroup = emptyGroup; foreach (var executionPath in executionPaths) { var singleMatch = (SingleMatchEntry)executionPath.Match; var operand = ConvertOperand(singleMatch.Operand); _minValue = Math.Min(_minValue, operand); _maxValue = Math.Max(_maxValue, operand); _dictionary.SetValue(operand, executionPath); } }
public RangeTreeLookup(System.Collections.Generic.IReadOnlyCollection <ExecutionPathGroup> executionPathGroups, ExecutionPathGroup emptyGroup) { _emptyGroup = emptyGroup; foreach (var executionPathGroup in executionPathGroups) { var range = CreateRange(executionPathGroup.Match); _minValue = Math.Min(_minValue, range.Minimum); _maxValue = Math.Max(_maxValue, range.Maximum); } _intervalTree = IntervalTree.Build(executionPathGroups, e => CreateRange(e.Match)); }
public PredicateLookup(ILookup matchLookup, ExecutionPathGroup predicateGroup) { _matchLookup = matchLookup; _predicateGroup = predicateGroup; }
public AnyLookup(ExecutionPathGroup executionPathGroup) { _executionPathGroup = executionPathGroup; }
public SingleOperandLookup(TOperand operand, ExecutionPathGroup executionPath, ExecutionPathGroup emptyGroup) { _operand = ConvertOperand(operand); _executionPath = executionPath; _emptyGroup = emptyGroup; }