• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

C# Globals类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C#中Globals的典型用法代码示例。如果您正苦于以下问题:C# Globals类的具体用法?C# Globals怎么用?C# Globals使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



Globals类属于命名空间,在下文中一共展示了Globals类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。

示例1: GitTfsRemote

 public GitTfsRemote(RemoteOptions remoteOptions, Globals globals, ITfsHelper tfsHelper, TextWriter stdout)
 {
     this.remoteOptions = remoteOptions;
     this.globals = globals;
     this.stdout = stdout;
     Tfs = tfsHelper;
 }
开发者ID:roend83,项目名称:git-tfs,代码行数:7,代码来源:GitTfsRemote.cs


示例2: InitBranch

 public InitBranch(TextWriter stdout, Globals globals, Help helper, AuthorsFile authors)
 {
     _stdout = stdout;
     _globals = globals;
     _helper = helper;
     _authors = authors;
 }
开发者ID:RomanKruglyakov,项目名称:git-tfs,代码行数:7,代码来源:InitBranch.cs


示例3: Subtree

 public Subtree(Fetch fetch, QuickFetch quickFetch, Globals globals, RemoteOptions remoteOptions)
 {
     _fetch = fetch;
     _quickFetch = quickFetch;
     _globals = globals;
     _remoteOptions = remoteOptions;
 }
开发者ID:pmiossec,项目名称:git-tfs,代码行数:7,代码来源:Subtree.cs


示例4: GetConvictionColor

    public static Color GetConvictionColor(Globals.Conviction conviction)
    {
        Color color = Color.white;
        switch(conviction){
        case Globals.Conviction.anger:
            color = GetMoodColor(Globals.Mood.lustful);
            break;
        case Globals.Conviction.envy:
            color = GetMoodColor(Globals.Mood.obsessed);
            break;
        case Globals.Conviction.gluttony:
            color = GetMoodColor(Globals.Mood.bitter);
            break;
        case Globals.Conviction.greed:
            color = GetMoodColor(Globals.Mood.idealistic);
            break;
        case Globals.Conviction.lust:
            color = Color.blue;
            break;
        case Globals.Conviction.pride:
            color = GetMoodColor(Globals.Mood.conservative);
            break;
        case Globals.Conviction.sloth:
            color = GetMoodColor(Globals.Mood.lovestruck);
        //			Debug.Log(color);
            break;
        }

        //		Debug.Log("getting color " + color + " for conviction " + conviction.ToString());
        return color;
    }
开发者ID:aimozs,项目名称:Scripts,代码行数:31,代码来源:GameModel.cs


示例5: ListRemoteBranches

 public ListRemoteBranches(Globals globals, TextWriter stdout, ITfsHelper tfsHelper, RemoteOptions remoteOptions)
 {
     this.globals = globals;
     this.stdout = stdout;
     this.tfsHelper = tfsHelper;
     this.remoteOptions = remoteOptions;
 }
开发者ID:patthoyts,项目名称:git-tfs,代码行数:7,代码来源:ListRemoteBranches.cs


示例6: Bootstrap

 public Bootstrap(RemoteOptions remoteOptions, Globals globals, TextWriter stdout, Bootstrapper bootstrapper)
 {
     _remoteOptions = remoteOptions;
     _globals = globals;
     _stdout = stdout;
     _bootstrapper = bootstrapper;
 }
开发者ID:XinChenBug,项目名称:git-tfs,代码行数:7,代码来源:Bootstrap.cs


示例7: Clone

 public Clone(Globals globals, Fetch fetch, Init init, InitBranch initBranch)
 {
     this.fetch = fetch;
     this.init = init;
     this.globals = globals;
     this.initBranch = initBranch;
 }
开发者ID:darthvid,项目名称:git-tfs,代码行数:7,代码来源:Clone.cs


示例8: Fetch

 public Fetch(Globals globals, RemoteOptions remoteOptions, AuthorsFile authors, Labels labels)
 {
     this.remoteOptions = remoteOptions;
     this.globals = globals;
     this.authors = authors;
     this.labels = labels;
 }
开发者ID:runt18,项目名称:git-tfs,代码行数:7,代码来源:Fetch.cs


示例9: Rcheckin

 public Rcheckin(TextWriter stdout, CheckinOptions checkinOptions, TfsWriter writer, Globals globals)
 {
     _stdout = stdout;
     _checkinOptions = checkinOptions;
     _checkinOptionsFactory = new CommitSpecificCheckinOptionsFactory(_stdout, globals);
     _writer = writer;
 }
开发者ID:nobitagamer,项目名称:git-tfs,代码行数:7,代码来源:Rcheckin.cs


示例10: Start

	void Start() {
		Globals[] globals = GameObject.FindObjectsOfType<Globals> ();
		for (int c = 1; c < globals.Length; c++) {
			Destroy(globals[c].gameObject);
		}
		global = globals [0];
	}
开发者ID:dka271,项目名称:Bazooka-Face,代码行数:7,代码来源:MainMenuEvent.cs


示例11: Parse

        protected void Parse(StringReader rdr, DepthScanner scanner, Globals globals)
        {
            int currentLine = 0;
            ParseNamespace(rdr, globals, scanner, ref currentLine, false);

            // Resolve incomplete names
            foreach (string key in globals.GetPropertyNames())
            {
                TypeInfo t = globals.GetProperty(key, true) as TypeInfo;
                if (t != null)
                {
                    if (!t.IsComplete)
                        globals.AddProperty(key, globals.GetTypeInfo(t.Name), -1, "");
                    if (t is TemplateInst)
                    {
                        TemplateInst ti = t as TemplateInst;
                        if (!ti.WrappedType.IsComplete)
                            ti.WrappedType = globals.GetTypeInfo(ti.WrappedType.Name);
                    }
                }
            }

            foreach (FunctionInfo f in globals.GetFunctions(null, true))
            {
                f.ResolveIncompletion(globals);
            }

            foreach (TypeInfo type in globals.TypeInfo)
            {
                type.ResolveIncompletion(globals);
            }
        }
开发者ID:nonconforme,项目名称:UrhoAngelscriptIDE,代码行数:32,代码来源:AngelscriptParser.cs


示例12: GameServer

        public GameServer(int port, Globals.LoggerDelegate logger)
        {
            m_IP = "0.0.0.0";
            m_port = port;
            m_logger = logger;
            m_Player = new Player[NPLAYER];
            m_Player[0] = new Player();
            m_Player[1] = new Player();
            reacive_t = new Thread[NPLAYER];
            connection_t = new Thread((limitConnection));
            connection_t.Start();
            //reacive_t[0] = new Thread(

            try
            {
                listener = new TcpListener(IPAddress.Parse(m_IP), m_port); //listner
            }
            catch (ArgumentNullException)
            {
                m_logger("caught ArgumentNullException");
            }
            catch (ArgumentOutOfRangeException)
            {
                m_logger("caught ArgumentOutOfRangeException");
            }
        }
开发者ID:TheProjecter,项目名称:submarine-academic-cs-proj,代码行数:26,代码来源:GameServer.cs


示例13: Awake

    void Awake()
    {
        globals = Globals.GetInstance();
        XPBarSlider = XPBarSliderGO.GetComponent<UISlider>();
        maxWidth = XPBarSlider.foreground.localScale.x;

        if(XPBarSlider == null)
        {
            Debug.LogError("Couldn't get the UISlider component in XPBar Script.");
        }

        XPMaximum = globals.XPMaximum;
        if(XPMaximum == 0)
        {
            globals.XPPoints = 0;
            PlayerPrefs.SetInt("XP", 0);
            XPMaximum = 100;
            globals.XPMaximum = 100;
            PlayerPrefs.SetInt("XPMaximum", 100);
            Debug.Log("This is the first time XP bar is used.");
        }

        //XPBar.pixelInset.width = globals.XPPoints / (globals.XPMaximum / 100);
        XPPoints = globals.XPPoints;
        UpdateDisplay((XPPoints / XPMaximum));
        player = GameObject.FindWithTag("Player");
    }
开发者ID:spyrosgames,项目名称:PyramidsValleyCode,代码行数:27,代码来源:XPBar.cs


示例14: GetGlobalVariable

 public static string GetGlobalVariable(Globals globals, string varName, string defaultValue)
 {
     string result;
     if (globals == null)
     {
         result = defaultValue;
     }
     else
     {
         object[] array = (object[])globals.VariableNames;
         if (globals.get_VariableExists(varName))
         {
             object[] array2 = array;
             for (int i = 0; i < array2.Length; i++)
             {
                 object obj = array2[i];
                 if (obj.ToString() == varName)
                 {
                     result = (string)globals[varName];
                     return result;
                 }
             }
         }
         result = defaultValue;
     }
     return result;
 }
开发者ID:postondemand,项目名称:BuildVersionIncrement,代码行数:27,代码来源:GlobalVariables.cs


示例15: load

 public void load(Globals globals)
 {
     int count = ParameterSerializer.loadParameter(globals, SERVER_COUNT, -1);
     if (count != -1)
     {
         try
         {
             for (int i = 1; i <= count; ++i)
             {
                 string guidStr = ParameterSerializer.loadParameter(globals, SERVER_GUID + i, null);
                 Guid guid = new Guid(guidStr);
                 string sName = ParameterSerializer.loadParameter(globals, SERVER_NAME + guidStr, null);
                 string url = ParameterSerializer.loadParameter(globals, SERVER_URL + guidStr, null);
                 JiraServer server = new JiraServer(guid, sName, url, null, null);
                 server.UserName = CredentialsVault.Instance.getUserName(server);
                 server.Password = CredentialsVault.Instance.getPassword(server);
                 addServer(server);
             }
             changedSinceLoading = false;
         }
         catch (Exception e)
         {
             Debug.WriteLine(e);
         }
     }
 }
开发者ID:spncrgr,项目名称:connector-idea,代码行数:26,代码来源:JiraServerModel.cs


示例16: Clone

        public static CheckinOptions Clone(this CheckinOptions source, Globals globals)
        {
            CheckinOptions clone = new CheckinOptions();

            clone.CheckinComment = source.CheckinComment;
            clone.NoGenerateCheckinComment = source.NoGenerateCheckinComment;
            clone.NoMerge = source.NoMerge;
            clone.OverrideReason = source.OverrideReason;
            clone.Force = source.Force;
            clone.OverrideGatedCheckIn = source.OverrideGatedCheckIn;
            clone.WorkItemsToAssociate.AddRange(source.WorkItemsToAssociate);
            clone.WorkItemsToResolve.AddRange(source.WorkItemsToResolve);
            clone.AuthorTfsUserId = source.AuthorTfsUserId;
            try
            {
                string re = globals.Repository.GetConfig(GitTfsConstants.WorkItemAssociateRegexConfigKey);
                if (String.IsNullOrEmpty(re))
                    clone.WorkItemAssociateRegex = GitTfsConstants.TfsWorkItemAssociateRegex;
                else
                    clone.WorkItemAssociateRegex = new Regex(re);
            }
            catch (Exception)
            {
                clone.WorkItemAssociateRegex = null;
            }
            foreach (var note in source.CheckinNotes)
            {
                clone.CheckinNotes[note.Key] = note.Value;
            }

            return clone;
        }
开发者ID:XinChenBug,项目名称:git-tfs,代码行数:32,代码来源:CheckinOptionsExtensions.cs


示例17: load

        public void load(Globals globals, string solutionName)
        {
            lock (this)
            {
                issues.Clear();

                solutionName = ParameterSerializer.getKeyFromSolutionName(solutionName);

                int count = ParameterSerializer.loadParameter(globals, RECENTLY_VIEWED_COUNT + solutionName, -1);
                if (count != -1)
                {
                    try
                    {
                        if (count > MAX_ITEMS)
                            count = MAX_ITEMS;

                        for (int i = 1; i <= count; ++i)
                        {
                            string guidStr = ParameterSerializer.loadParameter(globals, RECENTLY_VIEWED_ISSUE_SERVER_GUID + solutionName + "_" + i, null);
                            Guid guid = new Guid(guidStr);
                            string key = ParameterSerializer.loadParameter(globals, RECENTLY_VIEWED_ISSUE_KEY + solutionName + "_" + i, null);
                            RecentlyViewedIssue issue = new RecentlyViewedIssue(guid, key);
                            issues.Add(issue);
                        }
                    }
                    catch (Exception e)
                    {
                        Debug.WriteLine(e);
                    }
                }
                changedSinceLoading = false;
            }
        }
开发者ID:spncrgr,项目名称:connector-idea,代码行数:33,代码来源:RecentlyViewedIssuesModel.cs


示例18: Verify

 public Verify(Globals globals, TreeVerifier verifier, TextWriter stdout, Help helper)
 {
     _globals = globals;
     _verifier = verifier;
     _stdout = stdout;
     _helper = helper;
 }
开发者ID:XinChenBug,项目名称:git-tfs,代码行数:7,代码来源:Verify.cs


示例19: Shelve

 public Shelve(CheckinOptions checkinOptions, TfsWriter writer, Globals globals)
 {
     _globals = globals;
     _checkinOptions = checkinOptions;
     _checkinOptionsFactory = new CheckinOptionsFactory(_globals);
     _writer = writer;
 }
开发者ID:pmiossec,项目名称:git-tfs,代码行数:7,代码来源:Shelve.cs


示例20: TerrainType

 /// <summary>
 /// Creates a TerrainType of the type specified in t.
 /// </summary>
 /// <param name="t">A type of Globals.TerrainTypes.</param>
 public TerrainType(Globals.TerrainTypes t)
 {
     this.type = t;
     switch (t)
     {
         case (Globals.TerrainTypes.Membrane):
             {
                 this.dmgMod = 0;
                 this.spdMod = 10;
                 this.rscMod = 0;
                 break;
             }
         case (Globals.TerrainTypes.Mucus):
             {
                 this.dmgMod = 0;
                 this.spdMod = 8;
                 this.rscMod = 4;
                 break;
             }
         case (Globals.TerrainTypes.Slow):
             {
                 this.dmgMod = 0;
                 this.spdMod = 5;
                 this.rscMod = 0;
                 break;
             }
         case (Globals.TerrainTypes.Infected):
             {
                 this.dmgMod = 5;
                 this.spdMod = 10;
                 this.rscMod = 0;
                 break;
             }
     }
 }
开发者ID:squid-box,项目名称:Breensoft-ReCellection,代码行数:39,代码来源:TerrainType.cs



注:本文中的Globals类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C# GlobusHttpHelper类代码示例发布时间:2022-05-24
下一篇:
C# GlobalState类代码示例发布时间:2022-05-24
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap