Ejemplo n.º 1
0
 /// <summary>
 /// Adds the specified sense to this SenseManager.
 /// </summary>
 /// <param name="sense">The sense to add.</param>
 public void AddSense(Sense sense)
 {
     lock (this.lockObject)
     {
         this.senses.Add(sense.SensoryType, sense);
     }
 }
Ejemplo n.º 2
0
 /// <summary>
 /// Determines if the collection of senses contain the specified sense.
 /// </summary>
 /// <param name="sense">The sense to search for.</param>
 /// <returns>True if the collection of senses contains this sense, else false.</returns>
 public bool Contains(Sense sense)
 {
     return this.senses.ContainsKey(sense.SensoryType);
 }
Ejemplo n.º 3
0
 /// <summary>
 /// Removes the specified sense from this SenseManager.
 /// </summary>
 /// <param name="sense">The sense to remove.</param>
 public void RemoveSense(Sense sense)
 {
     lock (this.lockObject)
     {
         this.senses.Remove(sense.SensoryType);
     }
 }
Ejemplo n.º 4
0
 /// <summary>Determines if the collection of senses contain the specified sense.</summary>
 /// <param name="sense">The sense to search for.</param>
 /// <returns>True if the collection of senses contains this sense, else false.</returns>
 public bool Contains(Sense sense)
 {
     return(SenseDictionary.ContainsKey(sense.SensoryType));
 }