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


C# Tags类代码示例

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


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

示例1: Definitions

		/// <summary>
		/// Convert a halo 1 sound tag to the halo 2 version
		/// </summary>
		/// <param name="halo1"></param>
		/// <param name="halo2"></param>
		/// <returns></returns>
		public bool Definitions(
			Blam.Halo1.Tags.sound_group halo1,
			Tags.sound_group halo2
			)
		{
			return true;
		}
开发者ID:CodeAsm,项目名称:open-sauce,代码行数:13,代码来源:Convert.cs

示例2: SortBooksByTag

 public void SortBooksByTag(Tags tag)
 {
     books = storageAdapter.Load();
     Comparison<Book> comparison;
     switch (tag)
     {
         case Tags.Title:
             comparison = Book.CompareByTitle;
             break;
         case Tags.Author:
             comparison = Book.CompareByAuthor;
             break;
         case Tags.Year:
             comparison = Book.CompareByYear;
             break;
         case Tags.Languadge:
             comparison = Book.CompareByLanguadge;
             break;
         default:
             comparison = Book.CompareByTitle;
             break;
     }
     books.Sort(comparison);
     Commit();
 }
开发者ID:sokoloWladislav,项目名称:BSU.ASP1501.DAY5,代码行数:25,代码来源:BookListService.cs

示例3: PutTags

        public async Task<IHttpActionResult> PutTags(Guid id, Tags tags)
        {
            if (!ModelState.IsValid)
            {
                return BadRequest(ModelState);
            }

            if (id != tags.id)
            {
                return BadRequest();
            }

            db.Entry(tags).State = EntityState.Modified;

            try
            {
                await db.SaveChangesAsync();
            }
            catch (DbUpdateConcurrencyException)
            {
                if (!TagsExists(id))
                {
                    return NotFound();
                }
                else
                {
                    throw;
                }
            }

            return StatusCode(HttpStatusCode.NoContent);
        }
开发者ID:minh0409,项目名称:unavsa2015Web,代码行数:32,代码来源:TagsController.cs

示例4: AdvancedSolverSettings

        /// <summary>
        /// Creates new AdvancesSolverSettings.
        /// </summary>
        /// <param name="baseSettings">Base settings to copy.</param>
        /// <param name="totalPoints">Maximum for points spent in the result tree. (>= 0)</param>
        /// <param name="initialAttributes">Starting attributes of stats that calculations are based on.</param>
        /// <param name="attributeConstraints">The attribute constraints the solver should try to fullfill.</param>
        /// <param name="pseudoAttributeConstraints">The pseudo attribute constraints the solver should try to fullfill.</param>
        /// <param name="weaponClass">WeaponClass used for pseudo attribute calculation.</param>
        /// <param name="tags">Tags used for pseudo attribute calculation.</param>
        /// <param name="offHand">OffHand used for pseudo attribute calculation.</param>
        public AdvancedSolverSettings(SolverSettings baseSettings,
            int totalPoints,
            Dictionary<string, float> initialAttributes,
            Dictionary<string, Tuple<float, double>> attributeConstraints,
            Dictionary<PseudoAttribute, Tuple<float, double>> pseudoAttributeConstraints,
            WeaponClass weaponClass, Tags tags, OffHand offHand)
            : base(baseSettings)
        {
            if (totalPoints < 0) throw new ArgumentOutOfRangeException(nameof(totalPoints), totalPoints, "must be >= 0");

            TotalPoints = totalPoints;
            WeaponClass = weaponClass;
            Tags = tags;
            OffHand = offHand;
            AttributeConstraints = attributeConstraints ?? new Dictionary<string, Tuple<float, double>>();
            PseudoAttributeConstraints = pseudoAttributeConstraints ?? new Dictionary<PseudoAttribute, Tuple<float, double>>();
            InitialAttributes = initialAttributes ?? new Dictionary<string, float>();

            if (AttributeConstraints.Values.Any(tuple => tuple.Item2 < 0 || tuple.Item2 > 1))
                throw new ArgumentException("Weights need to be between 0 and 1", "attributeConstraints");
            if (AttributeConstraints.Values.Any(t => t.Item1 <= 0))
                throw new ArgumentException("Target values need to be greater zero", "attributeConstraints");
            if (PseudoAttributeConstraints.Values.Any(tuple => tuple.Item2 < 0 || tuple.Item2 > 1))
                throw new ArgumentException("Weights need to be between 0 and 1", "pseudoAttributeConstraints");
            if (PseudoAttributeConstraints.Values.Any(t => t.Item1 <= 0))
                throw new ArgumentException("Target values need to be greater zero", "pseudoAttributeConstraints");
        }
开发者ID:mihailim,项目名称:PoESkillTree,代码行数:38,代码来源:AdvancedSolverSettings.cs

示例5: ScenarioBuilder

 public ScenarioBuilder(string name, string description, Tags tags, FilePosition position)
 {
     this.title = name;
     this.description = description;
     this.position = position;
     this.tags = tags;
 }
开发者ID:nandrew,项目名称:SpecFlow,代码行数:7,代码来源:ScenarioBuilder.cs

示例6: Windows8TouchHandler

 /// <inheritdoc />
 public Windows8TouchHandler(Tags touchTags, Tags mouseTags, Tags penTags, Func<Vector2, Tags, bool, TouchPoint> beginTouch, Action<int, Vector2> moveTouch, Action<int> endTouch, Action<int> cancelTouch) : base(touchTags, beginTouch, moveTouch, endTouch, cancelTouch)
 {
     this.mouseTags = mouseTags;
     this.touchTags = touchTags;
     this.penTags = penTags;
     registerWindowProc(wndProcWin8);
 }
开发者ID:oafkad,项目名称:TouchScript,代码行数:8,代码来源:WindowsTouchHandlers.cs

示例7: FromJson

        internal static Tags FromJson(VkResponse response)
        {
            var tags = new Tags();

            tags.Count = response["count"];

            return tags;
        }
开发者ID:G-IT-ED,项目名称:vk,代码行数:8,代码来源:Tags.cs

示例8: TouchHandler

 /// <summary>
 /// Initializes a new instance of the <see cref="TouchHandler" /> class.
 /// </summary>
 /// <param name="tags">Tags to add to touches.</param>
 /// <param name="beginTouch">A function called when a new touch is detected. As <see cref="InputSource.beginTouch" /> this function must accept a Vector2 position of the new touch and return an instance of <see cref="TouchPoint" />.</param>
 /// <param name="moveTouch">A function called when a touch is moved. As <see cref="InputSource.moveTouch" /> this function must accept an int id and a Vector2 position.</param>
 /// <param name="endTouch">A function called when a touch is lifted off. As <see cref="InputSource.endTouch" /> this function must accept an int id.</param>
 /// <param name="cancelTouch">A function called when a touch is cancelled. As <see cref="InputSource.cancelTouch" /> this function must accept an int id.</param>
 public TouchHandler(Tags tags, Func<Vector2, Tags, bool, TouchPoint> beginTouch, Action<int, Vector2> moveTouch, Action<int> endTouch, Action<int> cancelTouch)
 {
     this.tags = tags;
     this.beginTouch = beginTouch;
     this.moveTouch = moveTouch;
     this.endTouch = endTouch;
     this.cancelTouch = cancelTouch;
 }
开发者ID:oafkad,项目名称:TouchScript,代码行数:16,代码来源:TouchHandler.cs

示例9: ExampleSet

 public ExampleSet(string keyword, string title, string description, Tags tags, GherkinTable table)
 {
     Keyword = keyword;
     Title = title ?? string.Empty;
     Description = description ?? "";
     Tags = tags;
     Table = table;
 }
开发者ID:ethanmoffat,项目名称:SpecFlow,代码行数:8,代码来源:Examples.cs

示例10: SetHeader

 public void SetHeader(string keyword, string title, string description, Tags tags, FilePosition position)
 {
     this.keyword = keyword;
     this.title = title;
     this.description = description;
     this.tags = tags;
     this.position = position;
 }
开发者ID:BEllis,项目名称:SpecFlow,代码行数:8,代码来源:FeatureBuilder.cs

示例11: ExampleBuilder

 public ExampleBuilder(string keyword, string name, string description, Tags tags, FilePosition position)
 {
     this.keyword = keyword;
     this.name = name;
     this.description = description;
     this.tags = tags;
     this.position = position;
 }
开发者ID:Galad,项目名称:SpecFlow,代码行数:8,代码来源:ExampleBuilder.cs

示例12: ConditionSettings

 public ConditionSettings(Tags tags, OffHand offHand, string[] keystones, WeaponClass weaponClass)
 {
     if (keystones == null) throw new ArgumentNullException("keystones");
     Tags = tags;
     OffHand = offHand;
     Keystones = keystones;
     WeaponClass = weaponClass;
 }
开发者ID:Daendaralus,项目名称:PoESkillTree,代码行数:8,代码来源:ConditionSettings.cs

示例13: Feature

 public Feature(Text title, Tags tags, DescriptionLine[] description, Background background, params Scenario[] scenarios)
 {
     Tags = tags;
     Description = description == null ? string.Empty : string.Join(Environment.NewLine, description.Select(d => d.LineText.Trim()).ToArray());
     Background = background;
     Scenarios = scenarios;
     Title = title.Value;
 }
开发者ID:x97mdr,项目名称:SpecFlow,代码行数:8,代码来源:Feature.cs

示例14: Create

        public TagDTO Create(Tags tag)
        {
            return new TagDTO(){

                 Url = urlbuilder.Link("GamingStoreRoute", new { id = tag.ID }),
                 Name = tag.Name
              };
        }
开发者ID:camotts,项目名称:383-Api,代码行数:8,代码来源:DTOFactory.cs

示例15: Awake

 void Awake()
 {
     _tags = FindObjectOfType<Tags>();
     _currencyManager = FindObjectOfType<CurrencyManager>();
     _scoreManager = FindObjectOfType<ScoreManager>();
     _enemyMovement = FindObjectOfType<EnemyMovement>();
     _anim = GetComponent<Animator>();
 }
开发者ID:buijldert,项目名称:Going_Bananas_TD,代码行数:8,代码来源:EnemyUnit.cs


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