/// <summary> /// See also https://msdn.microsoft.com/en-us/library/bb360913(v=vs.110).aspx /// </summary> /// <typeparam name="T"></typeparam> /// <param name="input"></param> /// <returns></returns> public static Bag <T> OfType <T>(this Bag input) => input.Accept(new OfTypeVisitor <T>());