2

SqlDataReader class is not marked sealed then what makes it uninheritable?

Marc Gravell
  • 1,026,079
  • 266
  • 2,566
  • 2,900
vatspoo
  • 391
  • 3
  • 8
  • 14

2 Answers2

4

The SqlDataReader type's constructor is marked as internal which means it can only be instantiated through types in the System.Data.dll assembly. This also prohibits you from inheriting from it, as the base type cannot be instantiated.

Matthew Abbott
  • 60,571
  • 9
  • 104
  • 129
0

Its only constructor is marked as internal, so it cannot be called by any non-framework code.

Quick Joe Smith
  • 8,074
  • 3
  • 29
  • 33