public FakeHttpFileCollection() { // It would be desirable for this class to use the behavior it inherits from NameObjectCollectionBase // through HttpFileCollectionBase, however that won't work because HttpFileCollectionBase overrides // most of the desired behavior by throwing NotImplementedExceptions instead. // HttpFileCollectionBase also fails to initialize the NameObjectCollectionBase with a case- // insensitive key-comparer the way the real HttpFileCollection does. // Therefore we are aggregating a custom NameObjectCollectionBase implementation instead of using the one we inherit. collection = new CaseInsensitiveNameObjectCollection(); }
public FakeHttpFileCollection() { // It would be desirable for this class to use the behavior it inherits from NameObjectCollectionBase // through HttpFileCollectionBase, however that won't work because HttpFileCollectionBase overrides // most of the desired behavior by throwing NotImplementedExceptions instead. // HttpFileCollectionBase also fails to initialize the NameObjectCollectionBase with a case- // insensitive key-comparer the way the real HttpFileCollection does. // Therefore we are aggregating a custom NameObjectCollectionBase implementation instead of using the one we inherit. collection = new CaseInsensitiveNameObjectCollection(); }