public override string ToString() { int[] strides = new int[2]; strides[0] = Length1; strides[1] = 1; int[] lowerBounds = new int[2]; return(StringUtil.ArrayToString(array, strides, lowerBounds)); }
protected override void UpdateItemFields(Item item) { base.UpdateItemFields(item); item.Fields["Is Tracking Enabled"]?.SetValue(IsTrackingEnabled ? "1" : string.Empty, true); item.Fields["Required"]?.SetValue(Required ? "1" : string.Empty, true); item.Fields["Allow Save"]?.SetValue(AllowSave ? "1" : string.Empty, true); item.Fields["Validations"]?.SetValue(StringUtil.ArrayToString(ValidationDataModels.Select(v => v.ItemId).ToArray(), '|'), true); }
static void Main(string[] args) { using (new MPI.Environment(ref args)) { Thread.CurrentThread.CurrentCulture = new CultureInfo("en-US"); var result = new GeneticWorldMPI(100, 16, 500).Run(); Console.WriteLine($"Fitness: {result.Item1}"); Console.WriteLine($"Best individuo: {result.Item2.fitness}"); Console.WriteLine(StringUtil.ArrayToString(result.Item2.genes)); } }
/// <summary> /// Overrides ToString method /// </summary> /// <returns>String representation of instance</returns> public override string ToString() { return(StringUtil.ArrayToString(this, count, new int[Rank])); #if false StringBuilder s = new StringBuilder(); int index = 0; int[] indexList = new int[Rank]; foreach (DistributionType d in this) { LinearIndexToMultidimensionalIndex(index++, indexList); string lhs = "[" + Util.CollectionToString <int>(indexList, ",") + "] "; s.Append(Util.JoinColumns("", lhs, d.ToString())); s.Append(Environment.NewLine); } return(s.ToString()); #endif }
public string Describe(Session session) { StringBuilder builder1 = new StringBuilder(); builder1.Append(base.ToString()).Append("[\n"); builder1.Append("escapeChar=").Append(this._escapeChar).Append('\n'); builder1.Append("isNull=").Append(this._isNull).Append('\n'); builder1.Append("isIgnoreCase=").Append(this._isIgnoreCase).Append('\n'); builder1.Append("iLen=").Append(this._iLen).Append('\n'); builder1.Append("iFirstWildCard=").Append(this._iFirstWildCard).Append('\n'); builder1.Append("cLike="); builder1.Append(StringUtil.ArrayToString(this._cLike)); builder1.Append('\n'); builder1.Append("wildCardType="); builder1.Append(StringUtil.ArrayToString(this._wildCardType)); builder1.Append(']'); return(builder1.ToString()); }
static void Main(string[] args) { if (args.Length == 0) { Log.WriteLine("Invalid usage! Need arguments to proceed!", Palette.Error); return; } TaskData taskData = new TaskData(args[0]); Log.WriteLine($"Loading Assembly {taskData.AssemblyName}"); Assembly assembly = Assembly.Load(taskData.AssemblyName); Log.WriteLine($"Loading Type {taskData.TypeName}"); Type t = assembly.GetType(taskData.TypeName); Log.WriteLine($"Loading Function {taskData.FunctionName}"); MethodInfo mInfo = t.GetMethod(taskData.FunctionName); Log.WriteLine($"Invoking Function {taskData.FunctionName}x({StringUtil.ArrayToString(taskData.Parameters)})"); mInfo.Invoke(null, taskData.Parameters); }
public override string ToString() { return(StringUtil.ArrayToString(array)); }
/// <summary> /// Overrides ToString method /// </summary> /// <returns>String representation of instance</returns> public override string ToString() { return(StringUtil.ArrayToString(this, count, new int[Rank])); }