void AddURL(ShellURL url) { if (dataGridView1.InvokeRequired) { StringParam sp = new StringParam(AddURL); dataGridView1.Invoke(sp, new object[1] { url }); } else { URLs.Add(url); } }
/// <summary> /// Fires when one of the paramters value has beend changed, usually when a user changes a input or output Parameter value, this can be used to populate input2 Parameter default values. /// </summary> public override void ParameterChanged(Parameter sender) { // This will Diplay NoDataValue(Already exisit) in the Optional input box; if (sender != _inputParam[0]) { return; } IRaster inputTemp = _inputParam[0].Value as IRaster; StringParam string1 = _inputParam[1] as StringParam; if (string1 != null && inputTemp != null) { string1.Value = inputTemp.NoDataValue.ToString(); } }
public override void Initialize() { _inputParam = new Parameter[5]; _inputParam[0] = new LineFeatureSetParam(TextStrings.InputFeatureSet); _inputParam[1] = new DoubleParam(TextStrings.LiCirclePara1, 60.0); _inputParam[2] = new DoubleParam(TextStrings.LiCirclePara2, 3.0); _inputParam[3] = new DoubleParam(TextStrings.LiCirclePara3, 5.0); _inputParam[4] = new StringParam(TextStrings.LiCirclePara4, string.Empty); #if DEBUG _outputParam = new Parameter[2]; _outputParam[0] = new PointFeatureSetParam(TextStrings.OutputFeatureSet); _outputParam[1] = new PolygonFeatureSetParam("DEBUG MODE OUTPUT"); #else _outputParam = new Parameter[1]; _outputParam[0] = new PointFeatureSetParam(TextStrings.OutputFeatureSet); #endif }
/// <summary> /// 文件上传完毕时执行保存方法 /// </summary> /// <param name="fileName"></param> /// <param name="parameters"></param> protected string FinishedFileUpload(string filePath, string parameters) { // Thread.Sleep(5000); string fileFullID = String.Empty; if (parameters.Trim().Length > 0) { StringParam sp = new StringParam(parameters, ";", ":"); string folderKey = sp.Get("FolderKey"); if (!String.IsNullOrEmpty(folderKey)) { fileFullID = FileService.MoveFile(filePath, folderKey); } } return(fileFullID); }
protected PriceConstants ParsePriceConstants(StringParam param) { switch (param.Value) { case "Open": return(PriceConstants.OPEN); case "High": return(PriceConstants.HIGH); case "Low": return(PriceConstants.LOW); case "Close": return(PriceConstants.CLOSE); case "Median": return(PriceConstants.MEDIAN); case "Typical": return(PriceConstants.TYPICAL); case "Weighed": return(PriceConstants.WEIGHTED); default: throw new System.ArgumentException("Failed to parse '" + param.Value + "' price type"); } }
/// <summary> /// The Parameter array should be populated with default values here /// </summary> public override void Initialize() { _inputParam = new Parameter[3]; _inputParam[0] = new RasterParam(TextStrings.inputRaster) { HelpText = TextStrings.InputRasternoValue }; _inputParam[1] = new StringParam(TextStrings.Optional) { HelpText = TextStrings.Optionaltochange }; _inputParam[2] = new StringParam(TextStrings.UserNewValues) { HelpText = TextStrings.UserinputNewValue }; _outputParam = new Parameter[1]; _outputParam[0] = new RasterParam(TextStrings.OutputRaster) { HelpText = TextStrings.newrastername }; }
/// <summary> /// The Parameter array should be populated with default values here /// </summary> public override void Initialize() { _inputParam = new Parameter[7]; _inputParam[0] = new RasterParam(TextStrings.input1altitudeRaster) { HelpText = TextStrings.InputRasterforaverageslopecalculation }; _inputParam[1] = new DoubleParam(TextStrings.inputZfactor, 1.0) { HelpText = TextStrings.InputZfactorforslopedisplay }; _inputParam[2] = new BooleanParam(TextStrings.slopeinpercentage, TextStrings.boxSlopeInPercentage, false) { HelpText = TextStrings.slopeinpercentage }; _inputParam[3] = new FeatureSetParam(TextStrings.input1polygonfeatureset) { HelpText = TextStrings.averageslopeinarribute }; _inputParam[4] = new FeatureSetParam(TextStrings.inputtheareaofinterest) { HelpText = TextStrings.featuresetcontainareainterest }; _inputParam[5] = new IntParam(TextStrings.Indexofareaofinterestfeature, 0) { HelpText = TextStrings.indexspecificarea }; _inputParam[6] = new StringParam(TextStrings.Fieldnameforavrageslope, TextStrings.AveSlope) { HelpText = TextStrings.Fieldnamecolomavrageslope }; _outputParam = new Parameter[2]; _outputParam[0] = new FeatureSetParam(TextStrings.Outputwithaverageslope) { HelpText = TextStrings.SelecttheResultofOutput }; _outputParam[2] = new BooleanParam(TextStrings.OutputParameter_AddToMap, TextStrings.OutputParameter_AddToMap_CheckboxText, true); }
/// <summary> /// The Parameter array should be populated with default values here /// </summary> public override void Initialize() { _inputParam = new Parameter[3]; _inputParam[0] = new RasterParam(TextStrings.inputRaster) { HelpText = TextStrings.InputRasternoValue }; _inputParam[1] = new StringParam(TextStrings.Optional) { HelpText = TextStrings.Optionaltochange }; _inputParam[2] = new StringParam(TextStrings.UserNewValues) { HelpText = TextStrings.UserinputNewValue }; _outputParam = new Parameter[2]; _outputParam[0] = new RasterParam(TextStrings.OutputRaster) { HelpText = TextStrings.newrastername }; _outputParam[1] = new BooleanParam(TextStrings.OutputParameter_AddToMap, TextStrings.OutputParameter_AddToMap_CheckboxText, true); }
private void btnContClear_Click(object sender, EventArgs e) { //MtPrDataSourceLoad(); foreach (DataGridViewColumn column in dataGridViewCont.Columns) { column.DefaultCellStyle.BackColor = Color.White; } contCurCont = null; coordTypeCont = null; coilCont = null; SearchContByParams(null); foreach (Control ctr in gbxFilterCont.Controls) { if (ctr.GetType() == typeof(ComboBox)) { ctr.ResetText(); } } }
/* [ Очистить все ] */ private void btnMtPrClear_Click(object sender, EventArgs e) { MtPrDataSourceLoad(); foreach (DataGridViewColumn column in dataGridViewMtPr.Columns) { column.DefaultCellStyle.BackColor = Color.White; } motorPowerMtPr = null; hasRelayMtPr = null; coordTypeMtPr = null; coilMtPr = null; SearchContByParams(null); foreach (Control ctr in gbxFilterMtPr.Controls) { if (ctr.GetType() == typeof(ComboBox)) { ctr.ResetText(); } } }
public static PageResult <ProductModel> Get( GiaSinhVienEntities db, PageArg <ProductModel.Select, ProductModel.Sort> pageArg, long[] id = null, StringParam str_Name = null, NumericParam num_CategoryId = null, NumericParam num_SubCategoryId = null, NumericParam num_Price = null, NumericParam num_Status = null, DateTimeParam date_CreateDate = null, NumericParam num_PostUserId = null, NumericParam num_DictrictId = null, NumericParam num_ProviceId = null) { return(DAOCore.DoPage <ProductModel, ProductModel.Select, ProductModel.Sort>(pageArg, (c, p) => { var total = new ObjectParameter("Total", typeof(int)); var query = new ObjectParameter("Query", typeof(string)); var data = db.usp_Product_Get( pageArg.SelectQuery(), pageArg.SortQuery(), p.PageIndex, p.PageSize, pageArg.DebugQuery, id == null ? null : string.Join(",", id), str_Name == null ? null : str_Name.ToString(), num_CategoryId == null ? null : num_CategoryId.ToString(), num_SubCategoryId == null ? null : num_SubCategoryId.ToString(), num_Price == null ? null : num_Price.ToString(), num_Status == null ? null : num_Status.ToString(), date_CreateDate == null ? null : date_CreateDate.ToString(), num_PostUserId == null ? null : num_PostUserId.ToString(), num_DictrictId == null ? null : num_DictrictId.ToString(), num_ProviceId == null ? null : num_ProviceId.ToString(), total, query).FirstOrDefault(); c.SetResult(p, c.ConvertFromXml(data), (int)total.Value, query.Value == DBNull.Value ? null : (string)query.Value); })); }
public static PageResult <UserInfoModel> Get( GiaSinhVienEntities db, PageArg <UserInfoModel.Select, UserInfoModel.Sort> pageArg, long[] id = null, StringParam str_Name = null, NumericParam num_Status = null) { return(DAOCore.DoPage <UserInfoModel, UserInfoModel.Select, UserInfoModel.Sort>(pageArg, (c, p) => { var total = new ObjectParameter("Total", typeof(int)); var query = new ObjectParameter("Query", typeof(string)); string data = null; //db.usp_Badwords_Get( // pageArg.SelectQuery(), pageArg.SortQuery(), p.PageIndex, p.PageSize, pageArg.DebugQuery, // id == null ? null : string.Join(",", id), // str_Value == null ? null : str_Value.ToString(), // num_Status == null ? null : num_Status.ToString(), // total, query).FirstOrDefault(); c.SetResult(p, c.ConvertFromXml(data), (int)total.Value, query.Value == DBNull.Value ? null : (string)query.Value); })); }
public void TestStringParam() { var sparam = new StringParam("myname", "myvalue"); var sparam2 = (StringParam) sparam.ToXmlAndBack(); Assert.AreEqual(sparam.Value, sparam2.Value); Assert.AreEqual(sparam.Name, sparam2.Name); }
public StringCreator AddParameter(StringParam param, object value) { var paramStr = Enum.GetName(typeof(StringParam), param); return(AddParameter(paramStr, value)); }
private void AddMzParameters(IList<Parameter> list, IList<ParameterDescription> help, Metadata mtd) { string name = string.Format("{0}{1}{2}", MetadataElement.MZTAB, MZTabConstants.MINUS, MetadataProperty.MZTAB_VERSION); string desc = null; name = CheckIfDescriptionExists(help, name, ref desc, mtd); StringParam version = new StringParam(name, Constants.versions.Last()){ Help = desc }; list.Add(version); IList<string> values = Enum.GetNames(typeof (MzTabMode)); name = string.Format("{0}{1}{2}", MetadataElement.MZTAB, MZTabConstants.MINUS, MetadataProperty.MZTAB_MODE); desc = null; name = CheckIfDescriptionExists(help, name, ref desc, mtd); SingleChoiceParam mode = new SingleChoiceParam(name){ Values = values, Value = values.IndexOf(mtd.TabDescription.MzTabMode.ToString()), Help = desc }; list.Add(mode); values = Enum.GetNames(typeof (MzTabType)); name = string.Format("{0}{1}{2}", MetadataElement.MZTAB, MZTabConstants.MINUS, MetadataProperty.MZTAB_TYPE); desc = null; name = CheckIfDescriptionExists(help, name, ref desc, mtd); SingleChoiceParam type = new SingleChoiceParam(name){ Values = values, Value = values.IndexOf(mtd.TabDescription.MzTabType.ToString()), Help = desc }; list.Add(type); name = string.Format("{0}{1}{2}", MetadataElement.MZTAB, MZTabConstants.MINUS, MetadataProperty.MZTAB_ID); desc = null; name = CheckIfDescriptionExists(help, name, ref desc, mtd); StringParam id = new StringParam(name){Value = mtd.TabDescription.Id, Help = desc}; list.Add(id); }
private void buttonPrepareExport_Click(object sender, EventArgs e) { if (cbProcNames.Items.Count > 0) { List <ReportParamV2> paramList = new List <ReportParamV2>(); Dictionary <string, string> parameters = ServicesProvider.GetInstance().GetAccountingServices().SelectExportAccountingProcParams("ExportAccounting_" + cbProcNames.Text); if (parameters != null && parameters.Count > 0) { foreach (var parameter in parameters) { ReportParamV2 reportParam; string paramName = parameter.Key.TrimStart('@'); if (paramName.Equals("branch_id", StringComparison.CurrentCultureIgnoreCase)) { reportParam = new BranchParam(string.Empty); } else { string paramType = parameter.Value; switch (paramType) { case "bit": reportParam = new BoolParam(false); break; case "datetime": reportParam = new DateParam(DateTime.Today); break; case "char": reportParam = new CharParam(' '); break; case "nvarchar": case "varchar": case "text": reportParam = new StringParam(string.Empty); break; case "int": reportParam = new IntParam(1); break; case "float": reportParam = new DoubleParam(1d); break; case "money": reportParam = new DecimalParam(1m); break; default: throw new NotImplementedException(string.Format("Sql type:{0} is not handled.", paramName)); } } reportParam.Label = paramName; reportParam.Name = paramName; paramList.Add(reportParam); } ReportParamsForm frm = new ReportParamsForm(paramList, cbProcNames.Text); frm.ShowDialog(); } _dataTable = ServicesProvider.GetInstance().GetAccountingServices().FindElementaryMvtsToExport( "ExportAccounting_" + cbProcNames.Text, paramList, out _idTable); _total = _dataTable.Rows.Count; _bwSelect = new BackgroundWorker { WorkerSupportsCancellation = true }; _bwSelect.DoWork += BwSelect_DoWork; ExportBookings_Load(this, null); } }
public static void IsNullOrEmpty(this StringParam param) { param.ToParam().Satisfies(s => string.IsNullOrEmpty(s)); }
public static void Contains(this StringParam param, string substring) { // TODO: Can move the 'context' into an argument to avoid newing up Funcs, but not sure if that'd help with expressions. Delaying modifications until in 'hard core performance' mode' param.ToParam().Satisfies(s => s.Contains(substring)); }
public static void StartsWith(this StringParam param, string prefix) { param.ToParam().Satisfies(s => s.StartsWith(prefix)); }
public CellCountChecker(IUiTestContext context, StringParam cell, int cellIndex, int count) { _context = context; _count = count; _cellGo = context.Inventory.GetCells(cell.Item).GetCell(cellIndex); }
public static string GetString(IntPtr device, StringParam name) { return Marshal.PtrToStringAnsi(Private.GetString(device, name)); }
public ClickCellCommand(IUiTestContext context, StringParam cellId, int cell) { _context = context; _cellId = cellId; _cell = cell; }
public WaitDialogCommand(IUiTestContext context, StringParam dialog, bool active) { _active = active; _context = context; _dialog = dialog; }
public static string GetString(StringParam name) { return Marshal.PtrToStringAnsi(Private.GetString(name)); }
public Configuration(string[] supportedAvailability, string publicAvailabilityFlag, string[] supportedLanguages, bool runningGUI) { ParamsManager = new ParamsManager(); var groupDescBoth = new ParamsDescriptionGroup(() => Language.Message("ParamGroupDescBoth")); var groupDescDir = new ParamsDescriptionGroup(() => Language.Message("ParamGroupDescDir")); var groupDescFile = new ParamsDescriptionGroup(() => Language.Message("ParamGroupDescFile")); // looking for localization param, before any text display LocParam = new EnumParam <LocalizationLanguage>( "loc", "Localization language", () => Language.Message("ParamDescLoc", string.Join(", ", Language.AvailableLangIDs)), LocalizationLanguage.INT, groupDescBoth, arg => { // need to update it right after parsing to allow proper messages Language.LangID = arg; }); PublishFlagsParam = new MultipleChoiceParam( "publish", "Publish flags", supportedAvailability, Enumerable.Range(0, supportedAvailability.Length), () => Language.Message("ParamDescPublish", publicAvailabilityFlag, string.Join(", ", supportedAvailability)), groupDescBoth); OutputFormatParam = new EnumParam <OutputFormat>( "outputFormat", "Output format", () => Language.Message("ParamDescOutputFormat"), OutputFormat.HTML, groupDescBoth); LangParam = new MultipleChoiceParam( "lang", "Languages", supportedLanguages, Enumerable.Range(0, supportedLanguages.Length), () => Language.Message("ParamDescLang", string.Join(", ", supportedLanguages)), groupDescDir); LinksToAllLangs = new Flag( "linksToAllLangs", "Links to all langs", () => Language.Message("ParamDescLinksToAllLangs"), groupDescDir); if (runningGUI) { PublishFlagsParam.Parse(User.Default.SupportedAvailability); OutputFormatParam.Parse(User.Default.OutputFormat); LangParam.Parse(User.Default.SupportedLanguages); } TemplateParam = new StringParam( "t", "Default template", () => Language.Message("ParamDescT"), runningGUI ? User.Default.DefaultTemplate : Settings.Default.DefaultTemplate, groupDescBoth); OutputParam = new StringParam( "o", "Output directory", () => Language.Message("ParamDescO"), runningGUI ? User.Default.OutputDirectory : Settings.Default.OutputDirectory, groupDescBoth); SourceParam = new StringParam( "s", "Source directory", () => Language.Message("ParamDescS"), runningGUI ? User.Default.SourceDirectory : Settings.Default.SourceDirectory, groupDescBoth); LogVerbosityParam = new EnumParam <LogVerbosity>( "v", "Logging verbosity", () => Language.Message("ParamDescV"), LogVerbosity.Info, groupDescBoth); DoxygenCacheParam = new StringParam( "doxygenCache", "Doxygen cache location", () => Language.Message("ParamDescDoxygenCache"), "", groupDescBoth); RebuildDoxygenCacheParam = new StringParam( "rebuildDoxygenCache", "If you want to rebuild Doxygen cache put here doxygen exec path", () => Language.Message("ParamDescRebuildDoxygenCache"), "", groupDescBoth); var absoluteSourceDir = new DirectoryInfo(Settings.Default.SourceDirectory).FullName; PathPrefixParam = new PathParam( "pathPrefix", "Path prefix", () => Language.Message("ParamDescPathPrefix"), runningGUI ? User.Default.PathPrefix : absoluteSourceDir, runningGUI ? User.Default.SourceDirectory : absoluteSourceDir, null, groupDescBoth); if (runningGUI) { HelpFlag = new Flag("h", "", () => Language.Message("ParamDescH"), User.Default.HelpFlag); LogOnlyFlag = new Flag("log", "Log Only", () => Language.Message("ParamDescLog"), User.Default.LogOnlyFlag, groupDescBoth); PreviewFlag = new Flag("p", "Preview", () => Language.Message("ParamDescP"), User.Default.PreviewFlag, groupDescFile); CleanFlag = new Flag("clean", "Clean", () => Language.Message("ParamDescClean"), User.Default.CleanFlag, groupDescBoth); LogVerbosityParam.Parse(User.Default.LogVerbosityParam); } else { HelpFlag = new Flag("h", "", () => Language.Message("ParamDescH")); LogOnlyFlag = new Flag("log", "Log Only", () => Language.Message("ParamDescLog"), groupDescBoth); PreviewFlag = new Flag("p", "Preview", () => Language.Message("ParamDescP"), groupDescFile); CleanFlag = new Flag("clean", "Clean", () => Language.Message("ParamDescClean"), groupDescBoth); } ParamsManager.Add( new List <Param> { LocParam, PathPrefixParam, PublishFlagsParam, OutputFormatParam, LangParam, LinksToAllLangs, TemplateParam, OutputParam, SourceParam, LogVerbosityParam, RebuildDoxygenCacheParam, DoxygenCacheParam, HelpFlag, LogOnlyFlag, PreviewFlag, CleanFlag }); PathsSpec = new StringParam( "PathsSpecifier", "Semicolon separated documentation source file or directory paths.", () => Language.Message("PathSpecParamDesc"), runningGUI ? Path.GetFileName(User.Default.PathsSpec) : "", null); ParamsManager.SetMainParam(PathsSpec); }
public IconEmptyChecker(IUiTestContext context, StringParam cell, int cellIndex) { _context = context; _cellGo = _context.Inventory.GetCells(cell.Item).GetCell(cellIndex); }
/// <summary> /// Convert <see cref="BaseLib.Param"/> to <see cref="BaseLibS.Param"/> /// </summary> /// <param name="p"></param> /// <returns></returns> public static Parameter Convert(Parameter p) { if (p.Type == ParamType.Server) { return(p); } if (p is RegexReplaceParamWf) { RegexReplaceParamWf q = (RegexReplaceParamWf)p; RegexReplaceParam b = new RegexReplaceParam(q.Name, q.Value.Item1, q.Value.Item2, q.Previews) { Help = q.Help, Visible = q.Visible, Default = q.Default, Url = q.Url }; foreach (ValueChangedHandler act in q.GetPropertyChangedHandlers()) { b.ValueChanged += act; } return(b); } if (p is RegexMatchParamWf) { RegexMatchParamWf q = (RegexMatchParamWf)p; RegexMatchParam b = new RegexMatchParam(q.Name, q.Value, q.Previews) { Help = q.Help, Visible = q.Visible, Default = q.Default, Url = q.Url }; foreach (ValueChangedHandler act in q.GetPropertyChangedHandlers()) { b.ValueChanged += act; } return(b); } if (p is BoolParamWf) { BoolParamWf q = (BoolParamWf)p; BoolParam b = new BoolParam(q.Name, q.Value) { Help = q.Help, Visible = q.Visible, Default = q.Default, Url = q.Url }; foreach (ValueChangedHandler act in q.GetPropertyChangedHandlers()) { b.ValueChanged += act; } return(b); } if (p is BoolWithSubParamsWf) { BoolWithSubParamsWf q = (BoolWithSubParamsWf)p; q.SubParamsFalse?.Convert(Convert); q.SubParamsTrue?.Convert(Convert); BoolWithSubParams b = new BoolWithSubParams(q.Name, q.Value) { Help = q.Help, Visible = q.Visible, SubParamsFalse = q.SubParamsFalse, SubParamsTrue = q.SubParamsTrue, Default = q.Default, ParamNameWidth = q.ParamNameWidth, TotalWidth = q.TotalWidth, Url = q.Url }; foreach (ValueChangedHandler act in q.GetPropertyChangedHandlers()) { b.ValueChanged += act; } return(b); } if (p is DictionaryIntValueParamWf) { DictionaryIntValueParamWf q = (DictionaryIntValueParamWf)p; DictionaryIntValueParam b = new DictionaryIntValueParam(q.Name, q.Value, q.Keys) { Help = q.Help, Visible = q.Visible, Default = q.Default, Url = q.Url }; foreach (ValueChangedHandler act in q.GetPropertyChangedHandlers()) { b.ValueChanged += act; } return(b); } if (p is DoubleParamWf) { DoubleParamWf q = (DoubleParamWf)p; DoubleParam b = new DoubleParam(q.Name, q.Value) { Help = q.Help, Visible = q.Visible, Default = q.Default, Url = q.Url }; foreach (ValueChangedHandler act in q.GetPropertyChangedHandlers()) { b.ValueChanged += act; } return(b); } if (p is FileParamWf) { FileParamWf q = (FileParamWf)p; FileParam b = new FileParam(q.Name, q.Value) { Help = q.Help, Visible = q.Visible, Default = q.Default, Filter = q.Filter, ProcessFileName = q.ProcessFileName, Save = q.Save, Url = q.Url }; foreach (ValueChangedHandler act in q.GetPropertyChangedHandlers()) { b.ValueChanged += act; } return(b); } if (p is FolderParamWf) { FolderParamWf q = (FolderParamWf)p; FolderParam b = new FolderParam(q.Name, q.Value) { Help = q.Help, Visible = q.Visible, Default = q.Default, Url = q.Url }; foreach (ValueChangedHandler act in q.GetPropertyChangedHandlers()) { b.ValueChanged += act; } return(b); } if (p is IntParamWf) { IntParamWf q = (IntParamWf)p; IntParam b = new IntParam(q.Name, q.Value) { Help = q.Help, Visible = q.Visible, Default = q.Default, Url = q.Url }; foreach (ValueChangedHandler act in q.GetPropertyChangedHandlers()) { b.ValueChanged += act; } return(b); } if (p is LabelParamWf) { LabelParamWf q = (LabelParamWf)p; LabelParam b = new LabelParam(q.Name, q.Value) { Help = q.Help, Visible = q.Visible, Default = q.Default, Url = q.Url }; foreach (ValueChangedHandler act in q.GetPropertyChangedHandlers()) { b.ValueChanged += act; } return(b); } if (p is MultiChoiceMultiBinParamWf) { MultiChoiceMultiBinParamWf q = (MultiChoiceMultiBinParamWf)p; MultiChoiceMultiBinParam b = new MultiChoiceMultiBinParam(q.Name, q.Value) { Help = q.Help, Visible = q.Visible, Values = q.Values, Bins = q.Bins, Default = q.Default, Url = q.Url }; foreach (ValueChangedHandler act in q.GetPropertyChangedHandlers()) { b.ValueChanged += act; } return(b); } if (p is MultiChoiceParamWf) { MultiChoiceParamWf q = (MultiChoiceParamWf)p; MultiChoiceParam b = new MultiChoiceParam(q.Name, q.Value) { Help = q.Help, Visible = q.Visible, Repeats = q.Repeats, Values = q.Values, Default = q.Default, DefaultSelections = q.DefaultSelections, DefaultSelectionNames = q.DefaultSelectionNames, Url = q.Url }; foreach (ValueChangedHandler act in q.GetPropertyChangedHandlers()) { b.ValueChanged += act; } return(b); } if (p is MultiFileParamWf) { MultiFileParamWf q = (MultiFileParamWf)p; MultiFileParam b = new MultiFileParam(q.Name, q.Value) { Help = q.Help, Visible = q.Visible, Filter = q.Filter, Default = q.Default, Url = q.Url }; foreach (ValueChangedHandler act in q.GetPropertyChangedHandlers()) { b.ValueChanged += act; } return(b); } if (p is MultiStringParamWf) { MultiStringParamWf q = (MultiStringParamWf)p; MultiStringParam b = new MultiStringParam(q.Name, q.Value) { Help = q.Help, Visible = q.Visible, Default = q.Default, Url = q.Url }; foreach (ValueChangedHandler act in q.GetPropertyChangedHandlers()) { b.ValueChanged += act; } return(b); } if (p is SingleChoiceParamWf) { SingleChoiceParamWf q = (SingleChoiceParamWf)p; SingleChoiceParam b = new SingleChoiceParam(q.Name, q.Value) { Help = q.Help, Visible = q.Visible, Values = q.Values, Default = q.Default, Url = q.Url }; foreach (ValueChangedHandler act in q.GetPropertyChangedHandlers()) { b.ValueChanged += act; } return(b); } if (p is SingleChoiceWithSubParamsWf) { SingleChoiceWithSubParamsWf q = (SingleChoiceWithSubParamsWf)p; foreach (Parameters param in q.SubParams) { param?.Convert(Convert); } SingleChoiceWithSubParams b = new SingleChoiceWithSubParams(q.Name, q.Value) { Help = q.Help, Visible = q.Visible, Values = q.Values, Default = q.Default, SubParams = new Parameters[q.SubParams.Count], ParamNameWidth = q.ParamNameWidth, TotalWidth = q.TotalWidth, Url = q.Url }; for (int i = 0; i < q.SubParams.Count; i++) { b.SubParams[i] = q.SubParams[i]; } foreach (ValueChangedHandler act in q.GetPropertyChangedHandlers()) { b.ValueChanged += act; } return(b); } if (p is StringParamWf) { StringParamWf q = (StringParamWf)p; StringParam b = new StringParam(q.Name, q.Value) { Help = q.Help, Visible = q.Visible, Default = q.Default, Url = q.Url }; foreach (ValueChangedHandler act in q.GetPropertyChangedHandlers()) { b.ValueChanged += act; } return(b); } if (p is Ms1LabelParamWf) { Ms1LabelParamWf q = (Ms1LabelParamWf)p; Ms1LabelParam b = new Ms1LabelParam(q.Name, q.Value) { Values = q.Values, Multiplicity = q.Multiplicity, Help = q.Help, Visible = q.Visible, Default = q.Default, Url = q.Url }; foreach (ValueChangedHandler act in q.GetPropertyChangedHandlers()) { b.ValueChanged += act; } return(b); } throw new Exception("Could not convert ParamWfeter"); }
private void AddTitleParameter(IList<Parameter> list, IList<ParameterDescription> help, Metadata mtd) { string name = MetadataElement.TITLE.Name; string desc = null; name = CheckIfDescriptionExists(help, name, ref desc, mtd); StringParam id = new StringParam(name){Value = mtd.Title, Help = desc}; list.Add(id); }
public static void EndsWith(this StringParam param, string suffix) { param.ToParam().Satisfies(s => s.EndsWith(suffix)); }
public DragAndDropCommand(IUiTestContext context, StringParam inventoryIdStart, int cellNumberStart, StringParam inventoryIdEnd, int cellNumberEnd) { _context = context; _inventoryIdStart = inventoryIdStart; _cellNumberStart = cellNumberStart; _inventoryIdEnd = inventoryIdEnd; _cellNumberEnd = cellNumberEnd; }
public static void IsNullOrWhitespace(this StringParam param) { param.ToParam().Satisfies(s => string.IsNullOrWhiteSpace(s)); }
public FindAndGoToSingleObjectCommand(IUiTestContext context, StringParam objectId) { _context = context; _objectId = objectId; }
public static void IsEmpty(this StringParam param) { param.ToParam().Satisfies(s => string.Equals(s, string.Empty)); }
protected override Parameter[] SpecificParameters(IMatrixData data, ref string errString) { if (data.StringColumnCount == 0) { errString = "Please add at least one string column"; return(null); } if (data.CategoryColumnCount == 0) { errString = "Please add at least one categorical column"; return(null); } var NumberOfCoresParam = new StringParam("CPUcores", "8") { Help = "Number of CPU cores to be used by the plugin in certain steps, set to 1 for lowest CPU usage." }; var ConditionColumnParam = new SingleChoiceParam("Condition column, eg R.FileName") { Values = data.CategoryColumnNames, Value = Math.Max(0, data.CategoryColumnNames.FindIndex(col => col.ToLower().Equals("r.filename"))), Help = "Chose experimental condition column, such as R.FileName. Has to be a categorical column." }; var ConditionOldParam = new StringParam("Rename condition old", "20171125_QE7_nLC14_DBJ_SA_DIAphos_RPE1_pilot2_") { Help = "Write parsing rule of condition column to be changed from. Leave blank if no change wanted." }; var ConditionNewParam = new StringParam("Rename condition new", "DIA_") { Help = "Write parsing rule of condition column to be changed into. Leave blank if no change wanted." }; var PerlParam = new SingleChoiceParam("Parsing type") { Values = new[] { "fixed", "perl" }, Help = "Chose if perl compatibility should be enabled for parsing." }; var ProbParam = new SingleChoiceWithSubParams("Prob param") // Hierarchical parameter with sub parameters { Values = new [] { "Local", "Global" }, // Name the different sub-parameter groups SubParams = new Parameters[] { // Define the different sub-parameter groups new Parameters(ConditionColumnParam, ConditionOldParam, ConditionNewParam, PerlParam), // Local new Parameters(PTMProbParam) // Global } }; var PTMProbParam = new SingleChoiceParam("EG.PTMLocalizationProbabilities") { Values = data.StringColumnNames, Value = Math.Max(0, data.StringColumnNames.FindIndex(col => col.ToLower().Equals("eg.ptmlocalizationprobabilities"))), Help = "Chose localization probability column, such as EG.PTMLocalizationProbabilities. Has to be a string column." }; var PTMSeqParam = new SingleChoiceParam("EG.PrecursorId") { Values = data.StringColumnNames, Value = Math.Max(0, data.StringColumnNames.FindIndex(col => col.ToLower().Equals("eg.precursorid"))), Help = "Chose sequence column, such as EG.PrecursorId. Has to be a string column." }; var GenesParam = new SingleChoiceParam("PG.Genes or PG.ProteinGroups") { Values = data.StringColumnNames, Value = Math.Max(0, data.StringColumnNames.FindIndex(col => col.ToLower().Equals("pg.genes"))), Help = "Chose gene or protein group column. Has to be a string column." }; var PeptidePosParam = new SingleChoiceParam("PEP.PeptidePosition") { Values = data.StringColumnNames, Value = Math.Max(0, data.StringColumnNames.FindIndex(col => col.ToLower().Equals("pep.peptideposition"))), Help = "Chose peptide position column, such as PEP.PeptidePosition. Has to be a string column." }; var AggParam = new SingleChoiceParam("Aggregation type") { Values = new[] { "Linear modeling based", "Summing" }, Help = "Chose if peptide intensities should be aggregated based on a linear model or simply summed." }; var CutoffParam = new StringParam("Localization cutoff", "0") { Help = "Localization cutoff to be used to filter PTM localization. Can be between 0 and 1. Setting to 0 will not filter anything." }; return(new Parameter[] { NumberOfCoresParam, ProbParam, // Use ProbParam instead of other parameters. PTMSeqParam, GenesParam, PeptidePosParam, AggParam, CutoffParam, }); }
protected override Parameter[] SpecificParameters(IMatrixData data, ref string errString) { if (data.StringColumnCount == 0) { errString = "Please add at least one string column"; return(null); } var ConditionColumn1Param = new SingleChoiceParam("Condition column, eg R.FileName") { Values = data.StringColumnNames, Value = Math.Max(0, data.StringColumnNames.FindIndex(col => col.ToLower().Equals("r.filename"))), Help = "Chose experimental condition column, such as R.FileName, which will be used to create wide-format intensity columns. Has to be a text column." }; var PerlParam = new SingleChoiceWithSubParams("Condition grouping") { Values = new[] { "Group by condition column", "Skip" }, Value = 0, Help = "Chose if input should be grouped from long-format (e.g. Spectronaut report or MaxQuant LFQ evidence) or mixed-format " + "(e.g. MaxQuant TMT evidence with conditions) into wide-format required for this plugin. Chose skip if data is already in wide-format " + "(e.g. MaxQuant TMT evidence without conditions).", SubParams = new Parameters[] { // Define the different sub-parameter groups new Parameters(ConditionColumn1Param), // condition grouping new Parameters() // Skip } }; var Cutoff1aParam = new DoubleParam("Localization cutoff", 0.75) { Help = "Localization cutoff to be used to filter PTM localization. Can be between 0 and 1. Setting to 0 will not filter anything." }; var Cutoff1bParam = new DoubleParam("Localization cutoff", 0.75) { Help = "Localization cutoff to be used to filter PTM localization. Can be between 0 and 1. Setting to 0 will not filter anything." }; var Cutoff2aParam = new DoubleParam("Localization cutoff", 0.75) { Help = "Localization cutoff to be used to filter PTM localization. Can be between 0 and 1. Setting to 0 will not filter anything." }; var Cutoff2bParam = new DoubleParam("Localization cutoff", 0.75) { Help = "Localization cutoff to be used to filter PTM localization. Can be between 0 and 1. Setting to 0 will not filter anything." }; var Cutoff2cParam = new DoubleParam("Localization cutoff", 0.75) { Help = "Localization cutoff to be used to filter PTM localization. Can be between 0 and 1. Setting to 0 will not filter anything." }; var Cutoff3aParam = new DoubleParam("Localization cutoff", 0.75) { Help = "Localization cutoff to be used to filter PTM localization. Can be between 0 and 1. Setting to 0 will not filter anything." }; var Cutoff3bParam = new DoubleParam("Localization cutoff", 0.75) { Help = "Localization cutoff to be used to filter PTM localization. Can be between 0 and 1. Setting to 0 will not filter anything." }; var PTMPosCol1Param = new SingleChoiceParam("PTM position column type") { Values = new[] { "EG.PTMLocalizationProbabilities (SN)", "EG.PrecursorId (SN)" }, Help = "Chose which column PTM positions should be extracted from. Requires respective columns." }; var PTMPosCol2Param = new SingleChoiceParam("PTM position column type") { Values = new[] { "EG.PTMLocalizationProbabilities (SN)", "EG.PrecursorId (SN)", "Modified sequence (MQ)" }, Help = "Chose which column PTM positions should be extracted from. Requires respective columns." }; var PTMPosCol3Param = new SingleChoiceParam("PTM position column type") { Values = new[] { "EG.PTMLocalizationProbabilities (SN)", "EG.PrecursorId (SN)" }, Help = "Chose which column PTM positions should be extracted from. Requires respective columns." }; var PTMPosCol2cParam = new SingleChoiceParam("Target PTM Probabilities column") { Values = data.StringColumnNames, Value = Math.Max(0, data.StringColumnNames.FindIndex(col => col.ToLower().Equals("phospho (sty) probabilities"))), Help = "Chose which column PTM target probabilities should be extracted from. Requires respective columns." }; var ProbType1Param = new SingleChoiceWithSubParams("Probability column type") { Values = new[] { "EG.PTMLocalizationProbabilities (SN)", "EG.PTMAssayProbability (SN)", "No probability column" }, Help = "Chose which column probabilities and PTM positions should be extracted from. Requires resepctive columns. " + "EG.PTMAssayProbability will extract PTM positions from EG.PrecursorId.", SubParams = new Parameters[] { // Define the different sub-parameter groups new Parameters(Cutoff1aParam), // EG.PTMLocalizationProbabilities new Parameters(Cutoff1bParam), // EG.PTMAssayProbability new Parameters(PTMPosCol1Param) // Ignored } }; var ProbType2Param = new SingleChoiceWithSubParams("Probability column type") { Values = new[] { "EG.PTMLocalizationProbabilities (SN)", "EG.PTMAssayProbability (SN)", "No probability column", "Modified sequence (MQ)" }, Help = "Chose which column probabilities and PTM positions should be extracted from. Requires resepctive columns. " + "EG.PTMAssayProbability will extract PTM positions from EG.PrecursorId. Modified sequence will extract probabilities from provided PTM Probabilities columns.", SubParams = new Parameters[] { // Define the different sub-parameter groups new Parameters(Cutoff2aParam), // EG.PTMLocalizationProbabilities new Parameters(Cutoff2bParam), // EG.PTMAssayProbability new Parameters(PTMPosCol2Param), // Ignored new Parameters(Cutoff2cParam, PTMPosCol2cParam) // Modified sequence } }; var ProbType3Param = new SingleChoiceWithSubParams("Probability column type") { Values = new[] { "EG.PTMLocalizationProbabilities (SN)", "EG.PTMAssayProbability (SN)", "No probability column" }, Help = "Chose which column probabilities and PTM positions should be extracted from. Requires resepctive columns. " + "EG.PTMAssayProbability will extract PTM positions from EG.PrecursorId.", SubParams = new Parameters[] { // Define the different sub-parameter groups new Parameters(Cutoff3aParam), // EG.PTMLocalizationProbabilities new Parameters(Cutoff3bParam), // EG.PTMAssayProbability new Parameters(PTMPosCol3Param) // Ignored } }; var GenesParam = new SingleChoiceParam("Genes or protein groups") { Values = new[] { "PG.Genes", "PG.ProteinGroups" }, Help = "Chose if sites should be collapsed on gene or protein level." }; var FastaFileParam = new FileParam("FASTA file (optional)") { Help = "Define file location of FASTA file for PTM motif sequence annotation. Leaving blank will skip annotation." }; var FastaStringParam = new StringParam("FASTA identifier rule", ".*GN=([^ ]*) .*") { Help = "If FASTA file is provided, define identifier parsing rule. This is crucial to allow gene or protein name matching as defined above. Set e.g." + ".*GN=([^ ]*) .* for gene readout, or .*\\|(.*)\\|.* for protein readout" }; var StoichParam = new SingleChoiceParam("Stoichiometry calculation") { Values = new[] { "Calculate stoichiometries", "Skip" }, Help = "Chose if target PTM stoichiometries should be calculated." }; var CollapseParam = new SingleChoiceWithSubParams("Collapse level") { Values = new[] { "Target PTM site-level, e.g. ABC1_S15_M1", "Target PTM peptide-level, e.g. FS[ph]EAMST[ph]R (stoichiometry possible)", "ModSpec peptide-level, e.g. FSEAMSTR_2[ph];1[ox]" }, Value = 0, Help = "Chose if precursors should be collapsed on peptide- or site-level. Site-level requires PEP.PeptidePosition column.", SubParams = new Parameters[] { // Define the different sub-parameter groups new Parameters(ProbType1Param, GenesParam, FastaFileParam, FastaStringParam), // Localized Site new Parameters(ProbType2Param, StoichParam), // Localized Peptide new Parameters(ProbType3Param) // ModSpec Peptide } }; var PTMTypesParam = new StringParam("Variable PTMs, target PTM first", "[Phospho (STY)];[Deamidation (NQ)];[Oxidation (M)];[Carbamidomethyl (C)]") { Help = "List PTMs as listed in EG.PrecursorId, separated by semicolon. If target site- or target peptide-level collapse is performed, " + "target PTM needs to be listed first." }; var AggParam = new SingleChoiceParam("Aggregation type") { Values = new[] { "Linear modeling based", "Summing" }, Help = "Chose if peptide intensities should be aggregated based on a linear model or simply summed." }; var NumberOfCoresParam = new IntParam("CPUcores", 8) { Help = "Number of CPU threads to be created by the plugin where possible. Set to 1 for lowest CPU usage. Do not set higher than actual number of available CPU threads." }; return(new Parameter[] { PerlParam, CollapseParam, PTMTypesParam, AggParam, NumberOfCoresParam, }); }
private static Parameter GetRelationsParameter() { const int maxCols = 5; string[] values = new string[maxCols]; Parameters[] subParams = new Parameters[maxCols]; for (int i = 1; i <= maxCols; i++){ values[i - 1] = "" + i; Parameter[] px = new Parameter[i]; for (int j = 0; j < i; j++){ px[j] = new StringParam("Relation " + (j + 1)); } Parameters p = new Parameters(px); subParams[i - 1] = p; } return new SingleChoiceWithSubParams("Number of relations", 0){ Values = values, SubParams = subParams, ParamNameWidth = 120, TotalWidth = 800 }; }
/// <summary> /// Convert <see cref="BaseLib.Param"/> to <see cref="BaseLibS.Param"/> /// </summary> /// <param name="p"></param> /// <returns></returns> public static Parameter Convert(Parameter p) { if (p.Type == ParamType.Server){ return p; } if (p is RegexReplaceParamWf){ RegexReplaceParamWf q = (RegexReplaceParamWf) p; RegexReplaceParam b = new RegexReplaceParam(q.Name, q.Value.Item1, q.Value.Item2, q.Previews){ Help = q.Help, Visible = q.Visible, Default = q.Default, Url = q.Url }; foreach (ValueChangedHandler act in q.GetPropertyChangedHandlers()){ b.ValueChanged += act; } return b; } if (p is RegexMatchParamWf){ RegexMatchParamWf q = (RegexMatchParamWf) p; RegexMatchParam b = new RegexMatchParam(q.Name, q.Value, q.Previews){ Help = q.Help, Visible = q.Visible, Default = q.Default, Url = q.Url }; foreach (ValueChangedHandler act in q.GetPropertyChangedHandlers()){ b.ValueChanged += act; } return b; } if (p is BoolParamWf){ BoolParamWf q = (BoolParamWf) p; BoolParam b = new BoolParam(q.Name, q.Value){ Help = q.Help, Visible = q.Visible, Default = q.Default, Url = q.Url }; foreach (ValueChangedHandler act in q.GetPropertyChangedHandlers()){ b.ValueChanged += act; } return b; } if (p is BoolWithSubParamsWf){ BoolWithSubParamsWf q = (BoolWithSubParamsWf) p; q.SubParamsFalse?.Convert(Convert); q.SubParamsTrue?.Convert(Convert); BoolWithSubParams b = new BoolWithSubParams(q.Name, q.Value){ Help = q.Help, Visible = q.Visible, SubParamsFalse = q.SubParamsFalse, SubParamsTrue = q.SubParamsTrue, Default = q.Default, ParamNameWidth = q.ParamNameWidth, TotalWidth = q.TotalWidth, Url = q.Url }; foreach (ValueChangedHandler act in q.GetPropertyChangedHandlers()){ b.ValueChanged += act; } return b; } if (p is DictionaryIntValueParamWf){ DictionaryIntValueParamWf q = (DictionaryIntValueParamWf) p; DictionaryIntValueParam b = new DictionaryIntValueParam(q.Name, q.Value, q.Keys){ Help = q.Help, Visible = q.Visible, Default = q.Default, Url = q.Url }; foreach (ValueChangedHandler act in q.GetPropertyChangedHandlers()){ b.ValueChanged += act; } return b; } if (p is DoubleParamWf){ DoubleParamWf q = (DoubleParamWf) p; DoubleParam b = new DoubleParam(q.Name, q.Value){ Help = q.Help, Visible = q.Visible, Default = q.Default, Url = q.Url }; foreach (ValueChangedHandler act in q.GetPropertyChangedHandlers()){ b.ValueChanged += act; } return b; } if (p is FileParamWf){ FileParamWf q = (FileParamWf) p; FileParam b = new FileParam(q.Name, q.Value){ Help = q.Help, Visible = q.Visible, Default = q.Default, Filter = q.Filter, ProcessFileName = q.ProcessFileName, Save = q.Save, Url = q.Url }; foreach (ValueChangedHandler act in q.GetPropertyChangedHandlers()){ b.ValueChanged += act; } return b; } if (p is FolderParamWf){ FolderParamWf q = (FolderParamWf) p; FolderParam b = new FolderParam(q.Name, q.Value){ Help = q.Help, Visible = q.Visible, Default = q.Default, Url = q.Url }; foreach (ValueChangedHandler act in q.GetPropertyChangedHandlers()){ b.ValueChanged += act; } return b; } if (p is IntParamWf){ IntParamWf q = (IntParamWf) p; IntParam b = new IntParam(q.Name, q.Value){ Help = q.Help, Visible = q.Visible, Default = q.Default, Url = q.Url }; foreach (ValueChangedHandler act in q.GetPropertyChangedHandlers()){ b.ValueChanged += act; } return b; } if (p is LabelParamWf){ LabelParamWf q = (LabelParamWf) p; LabelParam b = new LabelParam(q.Name, q.Value){ Help = q.Help, Visible = q.Visible, Default = q.Default, Url = q.Url }; foreach (ValueChangedHandler act in q.GetPropertyChangedHandlers()){ b.ValueChanged += act; } return b; } if (p is MultiChoiceMultiBinParamWf){ MultiChoiceMultiBinParamWf q = (MultiChoiceMultiBinParamWf) p; MultiChoiceMultiBinParam b = new MultiChoiceMultiBinParam(q.Name, q.Value){ Help = q.Help, Visible = q.Visible, Values = q.Values, Bins = q.Bins, Default = q.Default, Url = q.Url }; foreach (ValueChangedHandler act in q.GetPropertyChangedHandlers()){ b.ValueChanged += act; } return b; } if (p is MultiChoiceParamWf){ MultiChoiceParamWf q = (MultiChoiceParamWf) p; MultiChoiceParam b = new MultiChoiceParam(q.Name, q.Value){ Help = q.Help, Visible = q.Visible, Repeats = q.Repeats, Values = q.Values, Default = q.Default, DefaultSelections = q.DefaultSelections, DefaultSelectionNames = q.DefaultSelectionNames, Url = q.Url }; foreach (ValueChangedHandler act in q.GetPropertyChangedHandlers()){ b.ValueChanged += act; } return b; } if (p is MultiFileParamWf){ MultiFileParamWf q = (MultiFileParamWf) p; MultiFileParam b = new MultiFileParam(q.Name, q.Value){ Help = q.Help, Visible = q.Visible, Filter = q.Filter, Default = q.Default, Url = q.Url }; foreach (ValueChangedHandler act in q.GetPropertyChangedHandlers()){ b.ValueChanged += act; } return b; } if (p is MultiStringParamWf){ MultiStringParamWf q = (MultiStringParamWf) p; MultiStringParam b = new MultiStringParam(q.Name, q.Value){ Help = q.Help, Visible = q.Visible, Default = q.Default, Url = q.Url }; foreach (ValueChangedHandler act in q.GetPropertyChangedHandlers()){ b.ValueChanged += act; } return b; } if (p is SingleChoiceParamWf){ SingleChoiceParamWf q = (SingleChoiceParamWf) p; SingleChoiceParam b = new SingleChoiceParam(q.Name, q.Value){ Help = q.Help, Visible = q.Visible, Values = q.Values, Default = q.Default, Url = q.Url }; foreach (ValueChangedHandler act in q.GetPropertyChangedHandlers()){ b.ValueChanged += act; } return b; } if (p is SingleChoiceWithSubParamsWf){ SingleChoiceWithSubParamsWf q = (SingleChoiceWithSubParamsWf) p; foreach (Parameters param in q.SubParams){ param?.Convert(Convert); } SingleChoiceWithSubParams b = new SingleChoiceWithSubParams(q.Name, q.Value){ Help = q.Help, Visible = q.Visible, Values = q.Values, Default = q.Default, SubParams = new Parameters[q.SubParams.Count], ParamNameWidth = q.ParamNameWidth, TotalWidth = q.TotalWidth, Url = q.Url }; for (int i = 0; i < q.SubParams.Count; i++){ b.SubParams[i] = q.SubParams[i]; } foreach (ValueChangedHandler act in q.GetPropertyChangedHandlers()){ b.ValueChanged += act; } return b; } if (p is StringParamWf){ StringParamWf q = (StringParamWf) p; StringParam b = new StringParam(q.Name, q.Value){ Help = q.Help, Visible = q.Visible, Default = q.Default, Url = q.Url }; foreach (ValueChangedHandler act in q.GetPropertyChangedHandlers()){ b.ValueChanged += act; } return b; } if (p is Ms1LabelParamWf){ Ms1LabelParamWf q = (Ms1LabelParamWf) p; Ms1LabelParam b = new Ms1LabelParam(q.Name, q.Value){ Values = q.Values, Multiplicity = q.Multiplicity, Help = q.Help, Visible = q.Visible, Default = q.Default, Url = q.Url }; foreach (ValueChangedHandler act in q.GetPropertyChangedHandlers()){ b.ValueChanged += act; } return b; } throw new Exception("Could not convert ParamWfeter"); }
public CheckAndUseCommand(IUiTestContext context, Tuple <string, IUiTestChecker> checker, bool waitCheck, StringParam button) { _context = context; _checker = checker; _waitCheck = waitCheck; _button = button; }