当前位置: 首页>>代码示例>>C#>>正文


C# Globals类代码示例

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


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


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