using System; using System.Collections.Generic; using System.Text; namespace ImageSorter { public class ImageInfo { public readonly string Filename; private Dictionary _tagSet = new Dictionary(); public ImageInfo(string filename) { Filename = filename; } public IEnumerable Tags { get { return _tagSet.Keys; } } public bool HasTag(string tag) { return _tagSet.ContainsKey(tag); } public void SetTag(string tag, bool has) { if (has) { _tagSet[tag] = true; } else { _tagSet.Remove(tag); } } } }