Versions/VersionBuilder.cs

(开头部分) 6KB

这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Configuration;
using System.Data;
using System.IO;
using ComLib.Application;
using ComLib.Arguments;


namespace ComLib.VersionCheck
{
    public class VersionBuilder : App
    {
        #region Private data
        private bool _hasFilter;
        private Dictionary<string, string> _filteredTypes = new Dictionary<string, string>();
        private BoolMessageItem _checkResult;
        #endregion


        /// <summary>
        /// Create using arguments, version definition, config settings.
        /// </summary>
        /// <param name="args">Command line arguments.</param>
        /// <param name="ctx">Version Definition context</param>
        /// <param name="checkResultHandler">Callback</param>
        public VersionBuilder()
        {
        }


        /// <summary>
        /// Check the result.
        /// </summary>
        public BoolMessageItem Result { get { return _checkResult; } }


        /// <summary>
        /// Get the list of arguments that are supported.
        /// Type sojara.commodities.exe --help to display all the options.
        /// </summary>
        /// <returns></returns>
        public override List<ArgAttribute> OptionsSupported
        {
            get
            {
                List<ArgAttribute> options = new List<ArgAttribute>()
                {           
                    new ArgAttribute("name",    "Name representing this check", typeof(string), true, "", "ComJane_1.1.3, LimMds_1.3"),
                    new ArgAttribute("definition", "Path to xml definition file to generate", typeof(string), true, "", @"CommoditiesJane_1.1.3.xml"),
                    new ArgAttribute("directory",  "The directory to generate definition from.", typeof(string), true, @"",  @"C:\CS\RAD\ComJane\1.1.3.14\bin"),
                    new ArgAttribute("include",    "List of file extensions to include", typeof(string), false, "xml,dll", ".xml,.dll,.config,.exe"),
                    new ArgAttribute("useSize",    "Flag to include filesize in defintion", typeof(bool), false, false, "true | false"),
                    new ArgAttribute("pause",   false, "Pause sojara for debugging", typeof(bool), false, false, false, true, "true | false")                    
                };
                return options;
            }
        }
后面还有 106 行代码,解锁后查看完整代码

24 小时内免费解锁 3 个项目,之后 1 积分/个。 规则说明

AI 解读

登录后可用,每次 10 积分,解读结果公开显示在下面。

还没有人解读过这个文件。