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


C# InfoType类代码示例

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


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

示例1: prettyPrintInfoType

		public static String prettyPrintInfoType(InfoType uglybuggly)
			{
				String res = "None";
				switch (uglybuggly)
				{
				case InfoType.DEFIBRELLATOR: 
					res = "Defibrellator";
					break;
				case InfoType.FIRE_EXTINGUISHER:
					res = "Fire Extinguisher";
					break;
				case InfoType.FIRST_AID_KIT:
					res = "First Aid Kit";
					break;
				case InfoType.OFFICE:
					res = "Office";
					break;
				case InfoType.TOILET:
					res = "Toilet";
					break;
				case InfoType.FOOD:
					res = "Food";
					break;
				case InfoType.LECTURE_ROOM:
					res = "Lecture Room";
					break;	
				default: 
					res = "None";
					break;
				}
				return res;
			}
开发者ID:jiangxianliang,项目名称:SmartCampusAAU,代码行数:32,代码来源:SymbolicLocation.cs

示例2: OnPlayerInfoChanged

	//当主角信息发生改变的时候,会触发这个方法
	void OnPlayerInfoChanged(InfoType type)
	{
		if(type == InfoType.All || type == InfoType.Name || type == InfoType.HeadPortrait || type == InfoType.Level || type == InfoType.Energy || type == InfoType.Toughen)
		{
			UpdateShow();
		}
	}
开发者ID:vin120,项目名称:TaiDou,代码行数:8,代码来源:PlayerBar.cs

示例3: OnPlayerInfoChanged

 void OnPlayerInfoChanged(InfoType type)
 {
     if (type == InfoType.All || type == InfoType.Hp || type == InfoType.Damage || type == InfoType.Exp||type==InfoType.Equip)
     {
         UpdateShow();
     }
 }
开发者ID:1510649869,项目名称:ARPG_project,代码行数:7,代码来源:KnapspackRole.cs

示例4: SignUpInfo

 public SignUpInfo(InfoType type, string subtitle)
 {
     Type = type;
     Subtitle = subtitle;
     Info = new List<int>();
     HidesKeyboard = true;
 }
开发者ID:prozum,项目名称:solitude,代码行数:7,代码来源:SignUpInfo.cs

示例5: GetNextLevelUp

        public static void GetNextLevelUp(ref InfoType infoType, ref int objectID)
        {
            switch (infoType)
            {
                case InfoType.Category:
                    infoType = InfoType.None;
                    break;

                case InfoType.CategoryCity:
                    objectID = InfoDL.FindID(infoType, objectID);
                    infoType = InfoType.Category;
                    break;

                case InfoType.CategoryArea:
                    objectID = InfoDL.FindID(infoType, objectID);
                    infoType = InfoType.CategoryCity;
                    break;

                case InfoType.ContractorCategory:
                    infoType = InfoType.None;
                    break;

                case InfoType.ContractorCategoryCity:
                    objectID = InfoDL.FindID(infoType, objectID);
                    infoType = InfoType.ContractorCategory;
                    break;

                case InfoType.ContractorCategoryArea:
                    objectID = InfoDL.FindID(infoType, objectID);
                    infoType = InfoType.ContractorCategoryCity;
                    break;
            }
        }
开发者ID:SStewart-Ebsco,项目名称:TFS-Merge,代码行数:33,代码来源:InfoTypeDL.cs

示例6: OnPlayerInfoChanged

	void OnPlayerInfoChanged(InfoType type)
	{
		if(type == InfoType.All || type ==InfoType.Coin || type == InfoType .Diamond)
		{
			UpdateShow();
		}
	}
开发者ID:vin120,项目名称:TaiDou,代码行数:7,代码来源:TopBar.cs

示例7: NodeInfo

 /// <param name="name">Element name</param>
 /// <param name="description">Description for current element</param>
 /// <param name="type">Element type</param>
 /// <param name="displaying">Displays element over the 'Name' property</param>
 public NodeInfo(string name, string description, InfoType type = InfoType.Unspecified, string displaying = null)
 {
     Name            = name;
     Description     = description;
     this.type       = type;
     this.displaying = displaying;
 }
开发者ID:hilbertdu,项目名称:vsSolutionBuildEvent,代码行数:11,代码来源:NodeInfo.cs

示例8: GetAddressInfoAsync

        public async Task<ServiceResponse<int>> GetAddressInfoAsync(DistanceMatrixParameters parameters, InfoType info)
        {
            var result = new ServiceResponse<int>()
            {
                Success = false,
                Message = "Failed to get Buration data from service"
            };

            var response = await GetResponseAsync(parameters);

            if (response.Success)
            {
                var json = JsonConvert.DeserializeObject<DistanceMatrixResponse>(response.Value);

                var elem = json.Rows[0].Elements[0];

                var propName = Enum.GetName(typeof(InfoType), (int)info);

                var item = elem.GetType().GetProperty(propName).GetValue(elem);

                var value = item.GetType().GetProperty("Value").GetValue(item);

                result.Value = (int)value;
                result.Success = true;
                result.Message = "";
            }
            else
            {
                throw new Exception(response.Message, new Exception(response.Value));
            }

            return result;
        }
开发者ID:ChenKKaminsky,项目名称:Route-Planner,代码行数:33,代码来源:DistanceMatrixApi.cs

示例9: OnPlayerInfoChanged

	void OnPlayerInfoChanged(InfoType type)
	{
		if(type == InfoType.All)
		{
			UpdateShow();
		}
	}
开发者ID:xiaopan1991,项目名称:TaidouARPGProject,代码行数:7,代码来源:PlayerStatus.cs

示例10: GetInfo

 public String GetInfo(InfoType type)
 {
     return _stream.MediaInfo.GetParameterInfo(_stream.Type,
         _stream.Number,
         _index,
         type);
 }
开发者ID:anelson,项目名称:panoply,代码行数:7,代码来源:Parameter.cs

示例11: infoParsing

        private string infoParsing(string str, InfoType infoType)
        {
            try
            {
                StringBuilder sb = new StringBuilder();

                if (infoType == InfoType.Header)
                {
                    string[] split = str.Split(';');

                    foreach (var item in split)
                    {
                        int equalCount = item.IndexOf('=');

                        if (item != "")
                        {
                            sb.Append(item.Substring(0, equalCount) + ";");
                        }

                    }

                }
                else if (infoType == InfoType.Value)
                {
                    string[] split = str.Split(';');

                    foreach (var item in split)
                    {
                        int equalCount = item.IndexOf('=');

                        if (item != "")
                        {

                            sb.Append(item.Substring(equalCount + 1, item.Length - (equalCount + 1)) + ";");
                        }

                    }
                }
                else if (infoType == InfoType.Header_Value)
                {
                    sb.Append(str);
                }
                else
                {

                }

                return sb.ToString();

            }
            catch (Exception e)
            {
                return "add fail : " + e.Message;
            }
        }
开发者ID:minikie,项目名称:OTCDerivativesCalculatorModule,代码行数:55,代码来源:Result.cs

示例12: FindID

        public static int FindID(InfoType infoType, int objectID)
        {
            int newID = 0;

            SqlConnection conn = new SqlConnection(BWConfig.ConnectionString);

            string strSQL = "";
            switch (infoType)
            {
                case InfoType.CategoryCity:
                    strSQL = @"SELECT C.CategoryID FROM CategoryCity CC JOIN Category C ON (C.CategoryID = CC.CategoryID) WHERE CC.CategoryCityID = @ID";
                    break;
                case InfoType.CategoryArea:
                    strSQL = @"SELECT CC.CategoryCityID
                                FROM CategoryArea CA
                                    JOIN CategoryCity CC ON (CA.CategoryID = CC.CategoryID)
                                    JOIN Area A ON (CA.AreaID = A.AreaID AND CC.CityID = A.CityID)
                                WHERE CA.CategoryAreaID = @ID";
                    break;
                case InfoType.ContractorCategoryCity:
                    strSQL = @"SELECT CC.ContractorCategoryID
                                FROM ContractorCategoryCity CCC
                                    JOIN ContractorCategory CC ON (CCC.ContractorCategoryID = CC.ContractorCategoryID)
                                WHERE CCC.ContractorCategoryCityID = @ID";
                    break;
                case InfoType.ContractorCategoryArea:
                    strSQL = @"SELECT CCC.contractorCategoryCityID
                                FROM ContractorCategoryArea CCA
                                    JOIN ContractorCategoryCity CCC ON  (CCA.ContractorCategoryID = CCC.ContractorCategoryID)
                                    JOIN Area A ON (CCA.AreaID = A.AreaID AND (CCC.CityID = A.CityID) )
                                WHERE (CCA.ContractorCategoryAreaID = @ID)";
                    break;
            }

            try
            {
                conn.Open();

                SqlCommand sqlCommand = new SqlCommand(strSQL, conn);
                sqlCommand.CommandType = CommandType.Text;
                sqlCommand.Parameters.Add("ID", SqlDbType.Int).Value = objectID;
                newID = Convert.ToInt32(sqlCommand.ExecuteScalar());
            }
            finally
            {
                if (conn != null)
                {
                    if (conn.State == ConnectionState.Open)
                        conn.Close();
                    conn.Dispose();
                }
            }

            return newID;
        }
开发者ID:SStewart-Ebsco,项目名称:TFS-Merge,代码行数:55,代码来源:InfoDL.cs

示例13: GetColumnName

 public static string GetColumnName(InfoType t)
 {
     switch (t)
     {
         case InfoType.Category: return "CategoryID";
         case InfoType.CategoryCity: return "CategoryCityID";
         case InfoType.CategoryArea: return "CategoryAreaID";
         case InfoType.ContractorCategory: return "ContractorCategoryID";
         case InfoType.ContractorCategoryCity: return "ContractorCategoryCityID";
         case InfoType.ContractorCategoryArea: return "ContractorCategoryAreaID";
         default: return "";
     }
 }
开发者ID:SStewart-Ebsco,项目名称:TFS-Merge,代码行数:13,代码来源:InfoTypeDL.cs

示例14: Get

 public async Task<IHttpActionResult> Get(InfoType id)
 {
     switch (id)
     {
         case InfoType.LANGUAGE:
             return Ok(await DB.GetUserLanguage(UserId));
         case InfoType.INTEREST:
             return Ok(await DB.GetUserInterest(UserId));
         case InfoType.FOODHABIT:
             return Ok(await DB.GetUserFoodHabit(UserId));
         default:
             return BadRequest("Invalid information type.");
     }
 }
开发者ID:prozum,项目名称:solitude,代码行数:14,代码来源:InfoController.cs

示例15: InfoWindow

 public InfoWindow(string msg, InfoType type = InfoType.Loading)
 {
     InitializeComponent();
     this.infoLabel.Text = msg;
     switch (type)
     {
         case InfoType.Loading:
             infoIcon.Size = new Size(24, 24);
             infoIcon.Image = DTWrapper.GUI.Properties.Resources.loading;
             ImageAnimator.Animate(infoIcon.Image, new EventHandler(this.OnFrameChanged));
             break;
         default:
             infoIcon.Size = new Size(0, 0);
             break;
     }
 }
开发者ID:cyrosy,项目名称:DTWrapper,代码行数:16,代码来源:InfoWindow.cs


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