Exemplo n.º 1
0
        public ExecutionGroupParameter(IExecutionGroup executionGroup, PropertyInfo propertyInfo, ParameterAttribute attrib)
        {
            this.PropertyInfo   = propertyInfo;
            this.ExecutionGroup = executionGroup;
            this.Attribute      = attrib;

            this.Parameters = this.PropertyInfo.PropertyType == typeof(bool) ?
                              this.Attribute.Parameters.Select(x => string.IsNullOrEmpty(x) ? "" : $"{ParameterParser.ParameterKey}{ParameterParser.ParameterKey}{x}").ToArray() :
                              this.Attribute.Parameters.Select(x => string.IsNullOrEmpty(x) ? "" : ParameterParser.ParameterKey + x).ToArray();
        }
Exemplo n.º 2
0
 /// <summary>
 /// Returns the property names of all active parameters
 /// </summary>
 /// <param name="executionGroup">The execution group</param>
 /// <returns>A list of property names of all active parameters</returns>
 public IList <string> GetActiveParameters(IExecutionGroup executionGroup) => this.activatedParameters[executionGroup].Select(x => x.Name).ToList();