/// <summary> /// Builds the vertical table with all data /// </summary> /// <param name="tableName">Name of the table.</param> /// <returns></returns> public DataTable buildDataTableSummaryTable(string tableName) { reCalculate(preCalculateTasks.all); PropertyCollectionExtended pce = this.buildPCE(false, null); return(pce.buildDataTableVertical("Counter summary results", "Descriptive statistics")); }
public override PropertyCollectionExtended AppendDataFields(PropertyCollectionExtended data = null) { PropertyCollectionExtended dataextended = new PropertyCollectionExtended(); return(dataextended); }
/// <summary> /// Gets the right column value /// </summary> /// <param name="column">The column.</param> /// <param name="pce">The pce.</param> /// <param name="c">Row count - required if <see cref="imbSCI.Core.collection.PropertyEntryColumn.autocount_idcolumn"/> is the <c>column</c>.</param> /// <param name="autocount_format">The autocount format.</param> /// <returns></returns> public static object getColumnValue(this PropertyEntry column, PropertyCollectionExtended pce, int c, string autocount_format) { object vl = getColumnValue_Default; object key = column[PropertyEntryColumn.entry_key]; if (key is PropertyEntryColumn) { PropertyEntryColumn pec = (PropertyEntryColumn)key; switch (pec) { case PropertyEntryColumn.entry_name: vl = pce.name; break; case PropertyEntryColumn.entry_description: vl = pce.description; break; case PropertyEntryColumn.autocount_idcolumn: vl = c.ToString(autocount_format); break; default: vl = column.getColumn(pec, pce[key]); break; } } else { vl = pce[key]; } return(vl); }
/// <summary> /// Appends its data points into new or existing property collection /// </summary> /// <param name="data">Property collection to add data into</param> /// <returns>Updated or newly created property collection</returns> public PropertyCollectionExtended AppendDataFields(PropertyCollectionExtended data = null) { if (data == null) { data = new PropertyCollectionExtended(); } try { // data.Add("", sufix, "Call in code", ""); data.Add("devnote_callertype", callerType.Name, "Caller", "Caller type"); data.Add("", methodName, "Method", "").relevance(dataPointImportance.important); //data.Add("", className, "Class name", ""); data.Add("", methodBody.InitLocals, "Local init", "Local variables were initialized"); data.Add("", methodBody.MaxStackSize, "Stack size", "Maximum number of items on the operant stack"); if (methodInfo != null) { if (methodInfo.ReturnType != null) { data.Add("", methodInfo.ReturnType.Name, "Return", "Type of method return value"); } } foreach (LocalVariableInfo lvar in localVariables) { String varname_sufix = lvar.LocalIndex.ToString("D3"); data.Add(varname_sufix, "Local var: " + varname_sufix, lvar.toStringSafe("[unknown]"), lvar.LocalType.FullName); // data.Add("", lvar.toStringSafe(), "Value "+ varname_sufix, ""); } Int32 c = 0; foreach (ParameterInfo lvar in parameters) { String varname_sufix = lvar.Position.ToString("D3"); String desc = lvar.Attributes.ToStringEnumSmart(); //lvar.Attributes.getEnumListFromFlags<PropertyAttributes>().ToStringEnumSmart() String vl = ""; if (lvar.Position < sourceCodeParameterCalls.Count) { vl = sourceCodeParameterCalls[lvar.Position]; } data.Add(varname_sufix + " " + lvar.Name, vl, lvar.GetType().Name, "Value: " + lvar.toStringSafe("[null]") + " : " + desc); // ToString()); // data.Add("var" + varname_sufix, lvar.toStringSafe("[null]"), lvar.toStringSafe("[unknown]"), lvar.LocalType.Name); // data.Add("", lvar.toStringSafe(), "Value "+ varname_sufix, ""); } } catch (Exception ex) { throw new aceGeneralException("callerInfo.AppendDataFields() exception: " + ex.Message, ex, this, "Caller info exception"); } return(data); }
/// <summary> /// Appends its data points into new or existing property collection: log statistics /// </summary> /// <param name="data">Property collection to add data into</param> /// <returns>Updated or newly created property collection</returns> public PropertyCollectionExtended AppendDataFields(PropertyCollectionExtended data = null) { if (data == null) { data = new PropertyCollectionExtended(); } String log = ContentToString(); Int32 logEntries = contentElements.Count; var logLines = imbSciStringExtensions.SplitOnce(log, Environment.NewLine); Int32 logLinesCount = logLines.Count; String logMemSize = logContent.getStringMemByteSize(); List <logContentExceptionsFlags> logExceptions = logContent.getEnumsDetectedInString <logContentExceptionsFlags>(); data.Add("log_entries", logEntries, "Calls", "Count of log calls"); data.Add("log_lines", logLinesCount, "Lines", "String line breaks count"); data.Add("log_mem", logMemSize, "Memory", "Allocated memory by log string encoded as UTF8"); data.Add("log_exc", logExceptions.toStringSafe(), "Exceptions", "Detected exceptions in log content"); data.Add("log_out", outputPath, "File", "Output path associated with this log builder instance"); data.Add("log_auto", immediateSaveOn, "Autosave", "If live autosave mode is enabled for this log builder)"); return(data); }
/// <summary> /// Appends its data points into new or existing property collection /// </summary> /// <param name="data">Property collection to add data into</param> /// <returns>Updated or newly created property collection</returns> public override PropertyCollectionExtended AppendDataFields(PropertyCollection data = null) { PropertyCollectionExtended dataExtended = new PropertyCollectionExtended(); dataExtended.Add("name", name, "Name", "Spider algorithm name"); dataExtended.Add("description", description, "Description", "Short description"); dataExtended.Add("linkrules", linkActiveRules.Count(), "Link rules", "Number of evaluation rules for links"); dataExtended.Add("pagerules", pageScoreRules.Count(), "Page rules", "Number of evaluation rules for pages"); dataExtended.Add("controlrules", controlRules.Count(), "Control rules", "Execution flow control rules"); dataExtended.Add("controlpagerules", controlPageRules.Count(), "Control page rules", "Number of control page rules"); dataExtended.Add("controllinkrules", controlLinkRules.Count(), "Control link rules", "Number of control link rules"); dataExtended.Add("dotokenization", settings.flags.HasFlag(spiderEvaluatorExecutionFlags.doTokenization), "Tokenization", "If content tokenization is performed for each page loaded"); dataExtended.Add("iterationlimit", settings.limitIterations, "Iteration limit", "Maximum number of iterations allowed"); dataExtended.Add("iterationnewlinks", settings.limitIterationNewLinks, "New links limit", "Maximum number of new links allowed per iteration"); dataExtended.Add("iterationtotallinks", settings.limitTotalLinks, "Total links limit", "Maximum number of links allowed for consideration"); dataExtended.Add("pageloadlimit", settings.limitTotalPageLoad, "Total pages load limit", "Maximum number of links allowed for consideration"); dataExtended.Add("language_native", language.languageNativeName, "Language native name", "Native name of the language used by the spider"); dataExtended.Add("language_english", language.languageEnglishName, "Language english name", "English name of the language used by the spider"); dataExtended.Add("language_iso", language.iso2code, "Language code", "Language ISO 2-letter code"); return(dataExtended); }
/// <summary> /// Appends its data points into new or existing property collection /// </summary> /// <param name="data">Property collection to add data into</param> /// <returns>Updated or newly created property collection</returns> public virtual PropertyCollectionExtended AppendDataFields(PropertyCollectionExtended data = null) { if (data == null) { data = new PropertyCollectionExtended(); } String path = cacheSystem.getCacheFilepath("", directory, customSubdirectory); List <String> files = Directory.GetFiles(path).ToList(); data.Add("cmng_directory", directory, "Directory", "Reporistory of cache system associated with the cache manager"); data.Add("cmng_subdirectory", customSubdirectory, "Subdirectory", "Subdirectory within cache system repository"); data.Add("cmng_path", path, "Path", "Cache repository file system path"); data.Add("cmng_files", files.Count, "Files", "Number of cache files detected in the cache directory"); data.Add("cmng_cachesize", path.getDirectorySize().getMByteCountFormated(), "Size", "Memory allocated for all cache files within the path, in megabytes", "bytes"); data.Add("cmng_cacheLoadDisabled", cacheLoadDisabled, "Load disabled", "If cache load disabled the cache manager will ignore cache files on cacheLoad() calls."); data.Add("cmng_cacheSaveDisabled", cacheSaveDisabled, "Save disabled", "If cache save disabled the cache manager will ignore cacheSave() calls."); data.Add("cmng_subdirectory", customSubdirectory, "Subdirectory", "Subdirectory within cache system repository"); data.Add("cmng_hours", hourslimit, "Age limit", "Age limit for cache file to be accepted, in hours", "h"); return(data); }
public settingsPropertyEntryWithContext(Object __i, IList __host, PropertyCollectionExtended pce = null) : base(__host.IndexOf(__i)) { host = __host; value = __i; // index = __index; if (__host is IList) { IList l = __host as IList; Object i = __i; String iname = "[" + index.ToString() + "]"; type = i.GetType(); displayName = iname; description = imbSciStringExtensions.add(iname, "member [" + type.Name + "] of the collection [" + __host.GetType().Name + "]"); categoryName = "items"; //pis.Add(iname, null); //settingsPropertyEntryWithContext spe = new settingsPropertyEntryWithContext(pro, target); // spes.Add(pro.Name, spe); } }
/// <summary> /// Initializes a new instance of the <see cref="exeAppendTemplatedBundle"/> class. /// </summary> /// <param name="targetpath">The targetpath.</param> /// <param name="pce">The pce.</param> public exeAppendTemplatedBundle(string targetpath, PropertyCollectionExtended pce) { if (targetpath.Contains("{{{")) { targetpath = targetpath.applyToContent(false, pce).getCleanFilepath(); } staticData.Add(STATIC_DATA_MAIN, pce); if (Path.GetFileName(targetpath).isNullOrEmpty()) { // it is directory target = Directory.CreateDirectory(targetpath); operation = targetOperaton.deployInFolder; } else { targetExtension = Path.GetExtension(targetpath).Trim('.'); switch (targetExtension) { case "zip": operation = targetOperaton.deployInArchive; break; case "odt": operation = targetOperaton.deployInDocument; break; } target = Directory.CreateDirectory(Path.GetDirectoryName(targetpath)); FileInfo fi = targetpath.getWritableFile(getWritableFileMode.overwrite); targetFilename = fi.FullName.removeStartsWith(target.FullName); } }
/// <summary> /// Gets the data table summary. /// </summary> /// <returns></returns> public DataTable getDataTableSummary() { PropertyCollectionExtended dataExtended = AppendDataFields(null) as PropertyCollectionExtended; DataTable output = dataExtended.getDataTable(PropertyEntryColumn.entry_name, PropertyEntryColumn.entry_value, PropertyEntryColumn.entry_description); return(output); }
public override PropertyCollectionExtended AppendDataFields(PropertyCollectionExtended data = null) { if (data == null) { data = new PropertyCollectionExtended(); } return(data); }
/// <summary> /// Builds the parent score table. /// </summary> /// <param name="node">The node.</param> /// <returns></returns> public static DataTable buildParentScoreTable(this linknodeElement node) { PropertyCollectionExtended pce = node.buildParentScoreCollection(); DataTable dataTable = pce.buildDataTable("Score table"); return(dataTable); }
public static PropertyCollectionExtended AdditionalInfo(this DataTable dc, PropertyCollectionExtended default_data_additional) { if (!dc.ExtendedProperties.ContainsKey(templateFieldDataTable.data_additional)) { dc.ExtendedProperties.add(templateFieldDataTable.data_additional, default_data_additional); } return(dc.ExtendedProperties[templateFieldDataTable.data_additional] as PropertyCollectionExtended); }
public override PropertyCollectionExtended AppendDataFields(PropertyCollectionExtended data = null) { if (data == null) { data = new PropertyCollectionExtended(); } // ubaciti svoje podatke return(data); }
/// <summary> /// Deklarise jedan property entry i podesava njegove parametre prikaza /// </summary> /// <param name="__pi"></param> public settingsPropertyEntry(MemberInfo __pi, PropertyCollectionExtended pce = null) { pi = __pi as PropertyInfo; type = pi.PropertyType; process(__pi, pce); setAcceptableValues(); }
/// <summary> /// Learns the about related instance/key object /// </summary> /// <param name="instanceOrKey">The instance or key.</param> internal void learnAboutInstance(object instanceOrKey) { instanceTypeInfo = new settingsMemberInfoEntry(instanceOrKey); PropertyEntry pe = new PropertyEntry(instanceTypeInfo.displayName, instanceOrKey); instanceOrKeyData = new PropertyCollectionExtended(); instanceOrKeyData.AppendVertically(pe); }
/// <summary> /// Appends its data points into new or existing property collection /// </summary> /// <param name="data">Property collection to add data into</param> /// <returns> /// Updated or newly created property collection /// </returns> public override PropertyCollectionExtended AppendDataFields(PropertyCollectionExtended data = null) { if (data == null) { data = new PropertyCollectionExtended(); } data.Add("maxinboundlinks", maxInboundLinks, "Top inbound score", "The highest number of inbound links to a page in the set"); return(data); }
/// <summary> /// Appends its data points into new or existing property collection /// </summary> /// <param name="data">Property collection to add data into</param> /// <returns> /// Updated or newly created property collection /// </returns> public override PropertyCollectionExtended AppendDataFields(PropertyCollectionExtended data = null) { if (data == null) { data = new PropertyCollectionExtended(); } data.Add("titleuniquewords", titleWords.Keys.Count, "Title unique words", "Count of unique title words detected in the page set"); return(data); }
/// <summary> /// Appends its data points into new or existing property collection /// </summary> /// <param name="data">Property collection to add data into</param> /// <returns> /// Updated or newly created property collection /// </returns> public override PropertyCollectionExtended AppendDataFields(PropertyCollectionExtended data = null) { if (data == null) { data = new PropertyCollectionExtended(); } data.Add("maxcrosslinks", maxCrosslinkScore, "Top crosslink score", "The highest number of crosslinks in the set of pages"); return(data); }
/// <summary> /// Appends its data points into new or existing property collection /// </summary> /// <param name="data">Property collection to add data into</param> /// <returns> /// Updated or newly created property collection /// </returns> public override PropertyCollectionExtended AppendDataFields(PropertyCollectionExtended data = null) { if (data == null) { data = new PropertyCollectionExtended(); } data.Add("nodelevel_min", min, "Min. depth", "min. depth level in active nodes"); data.Add("nodelevel_max", max, "Max. depth", "max. depth level in active nodes"); return(data); }
/// <summary> /// Appends its data points into new or existing property collection /// </summary> /// <param name="data">Property collection to add data into</param> /// <returns> /// Updated or newly created property collection /// </returns> public override PropertyCollectionExtended AppendDataFields(PropertyCollectionExtended data = null) { if (data == null) { data = new PropertyCollectionExtended(); } data.Add("linkscoremax", linkScoreMax, "Top link score", "The highest score abong detected links"); return(data); }
/// <summary> /// Appends its data points into new or existing property collection /// </summary> /// <param name="data">Property collection to add data into</param> /// <returns> /// Updated or newly created property collection /// </returns> public override PropertyCollectionExtended AppendDataFields(PropertyCollectionExtended data = null) { if (data == null) { data = new PropertyCollectionExtended(); } data.Add("titleavgfrequency", pageTitleCount.avgFreq, "Title avg. frequency", "Arithmetic average frequency of page titles in the page set"); data.Add("titleuniquecount", pageTitleCount.Keys.Count, "Title unique count", "Count of unique page titles in the page set"); return(data); }
/// <summary> /// Appends its data points into new or existing property collection /// </summary> /// <param name="data">Property collection to add data into</param> /// <returns>Updated or newly created property collection</returns> public PropertyCollectionExtended AppendDataFields(PropertyCollectionExtended data = null) { if (data == null) { data = new PropertyCollectionExtended(); } data.Add("quartile_q1", q1, "Score Q1", "The first score quartile of active links"); data.Add("quartile_q3", q3, "Score Q3", "The first score quartile of active links"); return(data); }
/// <summary> /// Gets entries for checked items /// </summary> /// <param name="targetValue">if set to <c>true</c> [target value].</param> /// <returns></returns> public PropertyCollectionExtended getCheckedItems(Boolean targetValue = true) { PropertyCollectionExtended output = new PropertyCollectionExtended(); foreach (KeyValuePair <object, PropertyEntry> pe in items.entries) { if (pe.Value.getProperBoolean(false, PropertyEntryColumn.entry_value) == targetValue) { output.Add(pe.Value); } } return(output); }
/// <summary> /// Appends its data points into new or existing property collection /// </summary> /// <param name="data">Property collection to add data into</param> /// <returns>Updated or newly created property collection</returns> public PropertyCollection AppendDataFields(PropertyCollection data = null) { PropertyCollectionExtended dataExtended = new PropertyCollectionExtended(); dataExtended.Add("seed", seedLink.link.url, "Start url", "URL the spider started from"); dataExtended.Add("links", webActiveLinks.Count(), "Links", "Number of links discovered during the spider operation"); dataExtended.Add("pages", webPages.items.Count(), "Pages", "Number of pages discovered during the spider operation"); dataExtended.Add("pages_result", webPages.items.Count(), "Page set", "Pages accepted for further analysis"); dataExtended.Add("flags", flags, "Flags", "Flags about the spider operation"); return(dataExtended); }
public PropertyCollectionExtended GetPCE() { PropertyCollectionExtended output = new PropertyCollectionExtended(); output.Add(nameof(DocumentSetsUniqueForA), DocumentSetsUniqueForA.Count, "Unique for A", "Number of document sets that are unique for dataset A"); output.Add(nameof(DocumentSetsUniqueForB), DocumentSetsUniqueForB.Count, "Unique for B", "Number of document sets that are unique for dataset B"); output.Add(nameof(DocumentSetsInCommonByName), DocumentSetsInCommonByName.Count, "In common", "Number of document sets that in common for datasets"); output.Add(nameof(TermsUniqueForA), TermsUniqueForA.Count, "Terms unique for A", "Number of terms that are unique for dataset A"); output.Add(nameof(TermsUniqueForB), TermsUniqueForB.Count, "Terms unique for B", "Number of terms that are unique for dataset B"); output.Add(nameof(TermsInCommon), TermsInCommon.Count, "In common", "Number of terms that in common for datasets"); return(output); }
/// <summary> /// Appends its data points into new or existing property collection /// </summary> /// <param name="data">Property collection to add data into</param> /// <returns>Updated or newly created property collection</returns> public PropertyCollectionExtended AppendDataFields(PropertyCollectionExtended data = null) { if (data == null) { data = new PropertyCollectionExtended(); } data.Add("pageCross_q1", q1, "Crosslinks Q1", "The first crosslink count quartile of pages loaded"); data.Add("pageCross_q3", q3, "Crosslinks Q3", "The third crosslink count quartile of pages loaded"); data.Add("pageCross_min", min, "Crosslinks Min.", "The lowest count of crosslinks in pages loaded"); data.Add("pageCross_max", max, "Crosslinks Max.", "The highest count of crosslink in pages loaded"); return(data); }
/// <summary> /// Appends the data fields. /// </summary> /// <param name="data">The data.</param> /// <param name="whatToAppend">The what to append.</param> /// <returns></returns> public virtual PropertyCollectionExtended AppendDataFields(PropertyCollectionExtended data, modelRecordFieldToAppendFlags whatToAppend) { if (data == null) { data = new PropertyCollectionExtended(); } if (whatToAppend.HasFlag(modelRecordFieldToAppendFlags.identification)) { data.Add(modelRecordColumnEnum.iid, instanceID, "Instance ID", "Human readable identification of instance covered by the record"); if (instanceTypeInfo != null) { data.Add(modelRecordColumnEnum.instance, instanceTypeInfo.displayName, "Instance type", "Type name of the instance followed by this record"); data.Add(modelRecordColumnEnum.instancedesc, instanceTypeInfo.description, "Instance info", "Notes on the instance type"); } data.Add(modelRecordColumnEnum.uid, UID, "UID", "Universal code-ID of the record instance"); data.Add(modelRecordColumnEnum.recordstate, state, "Record state", "State flag for this record instance"); data.Add(modelRecordColumnEnum.runstamp, testRunStamp, "Run stamp", "Identification code of the experiment test run instance"); data.Add(modelRecordColumnEnum.recordtype, iTI.displayName, "Record type", "Name of the record class"); data.Add(modelRecordColumnEnum.recorddesc, iTI.description, "Record info", "Notes about applied record class"); } if (whatToAppend.HasFlag(modelRecordFieldToAppendFlags.modelRecordCommonData)) { string duration_str = timeFinish.Subtract(timeStart).TotalMilliseconds.getTimeSecString(); if (VAR_RecordModeFlags.HasFlag(modelRecordMode.singleStarter)) { data.Add(modelRecordColumnEnum.start, timeStart.ToShortTimeString(), "Start", "Start of the record / the instance run"); data.Add(modelRecordColumnEnum.finish, timeFinish.ToShortTimeString(), "Finish", "Time of the instance execution finished"); } else if (VAR_RecordModeFlags.HasFlag(modelRecordMode.multiStarter)) { data.Add(modelRecordColumnEnum.sessions, timeFinish.ToShortTimeString(), "Sessions", "Number of the record start-finish sessions"); } if (VAR_RecordModeFlags.HasFlag(modelRecordMode.starter)) { data.Add(modelRecordColumnEnum.duration, duration_str, "Duration", "Time span of the instance run, in seconds."); } data.Add(modelRecordColumnEnum.remarks, remarkFlags.ToStringEnumSmart(), "Remarks", "Remark flags about the instance execution"); } if (whatToAppend.HasFlag(modelRecordFieldToAppendFlags.modelRecordInstanceData)) { data.AddRange(instanceOrKeyData, false, false, false); } //if (whatToAppend.HasFlag(modelRecordFieldToAppendFlags.modelRecordLogData)) //{ // logBuilder.AppendDataFields(data); //} return(data); }
/// <summary> /// Appends its data points into new or existing property collection /// </summary> /// <param name="data">Property collection to add data into</param> /// <returns>Updated or newly created property collection</returns> public PropertyCollectionExtended AppendDataFields(PropertyCollectionExtended data = null) { if (data == null) { data = new PropertyCollectionExtended(); } data.Add(templateFieldBasic.sample_group, groupTag, "Database tag", "Tag string to mark sample item row in the database table"); data.Add("groupweight", weight, "Weight factor", "Relative weight number used for automatic population-to-group assigment"); data.Add(templateFieldBasic.sample_limit, groupSizeLimit, "Size limit", "Optional limit for total count of population within this group"); data.Add(templateFieldBasic.sample_totalcount, count, "Sample count", "Sample item entries count attached to this group"); data.Add("isclosed", isClosed, "Group closed", "TRUE if the group will not accept any new item"); return(data); }
/// <summary> /// Appends its data points into new or existing property collection /// </summary> /// <param name="data">Property collection to add data into</param> /// <returns>Updated or newly created property collection</returns> public override PropertyCollectionExtended AppendDataFields(PropertyCollectionExtended data = null) { if (data == null) { data = new PropertyCollectionExtended(); } /* * data.Add("grouptag", groupTag, "Database tag", "Tag string to mark sample item row in the database table"); * data.Add("groupweight", weight, "Weight factor", "Relative weight number used for automatic population-to-group assigment"); * data.Add("grouplimit", groupSizeLimit, "Size limit", "Optional limit for total count of population within this group"); * data.Add("groupcount", count, "Sample count", "Sample item entries count attached to this group"); */ return(data); }