/// <summary> /// Sets test for regex replacement of the matched test /// </summary> /// <param name="regexTest">The regex test.</param> /// <param name="__replacement">The replacement.</param> public pipelineRegexTestNode(String regexTest, String __replacement = "") { test = new Regex(regexTest); if (!__replacement.isNullOrEmpty()) { replacement = __replacement; testType |= pipelineRegexTestTypeEnum.replacer; _nodeType |= pipelineNodeTypeEnum.transformer; } }
/// <summary> /// Sets test for distribution <see cref="pipelineRegexTestNode"/> and optionaly for group replacer /// </summary> /// <param name="regexTest">The regex test.</param> /// <param name="groupToCurrent">The group from regex matches to replace <c>currentForm</c> with</param> public pipelineRegexTestNode(String regexTest, Int32 _current = -1, Object[] __tagsToApply = null) { test = new Regex(regexTest); groupToCurrent = _current; if (_current > -1) { testType |= pipelineRegexTestTypeEnum.groupreplacer | pipelineRegexTestTypeEnum.makeMatches; _nodeType |= pipelineNodeTypeEnum.transformer; } if (__tagsToApply != null) { tagsToApply = __tagsToApply; testType |= pipelineRegexTestTypeEnum.tagger; _nodeType |= pipelineNodeTypeEnum.transformer; } SetLabel(); }